How do I make enemies attack the player character

Started by seraphimdreamer777, Thu 17/04/2008 04:46:17

Previous topic - Next topic

seraphimdreamer777

How am I supposed to get a enemy character to attack the player character I've looked it up in both the help files and FAQ pages and on top of that I can't get enemies to move on their own free will either they only move if I interact with them such as look,speak,touch,use item,etc. So basically what I'm asking is how I give enemies A.I.
Victory is my destiny

Mehrdad

not easy .but possible.you better choose another software.like MULTIMEDIA FUSION or GAME MAKER.
My official site: http://www.pershaland.com/

EnterTheStory (aka tolworthy)

Quote from: seraphimdreamer777 on Thu 17/04/2008 04:46:17So basically what I'm asking is how I give enemies A.I.
My game has a lot of characters who have very simple AI. You just need to use 'repeatedly_execute_always()'. In my game I typically have 30 characters on screen, and they decide to walk or talk on their own.

The only problem I had was speed, since it can slow the game down f you change so many things every frame. But I solved that by checking just one character every frame, and using "WalkStraight" instead of "Walk" whenever possible.

Khris

Yep, rep_ex, Character.x/.y and a functioning brain is pretty much all you need.

seraphimdreamer777

Thanks but I tried what you told me but its not working and mainly I wanted to get the enemies to follow the player character without me having to click on them first sorry if I wasn't as specific
Victory is my destiny

Mazoliin

There's the FollowCharacter command, I believe it's what you're looking for. Read the manual to get more information about it.

SMF spam blocked by CleanTalk