I need help on a simple enemy AI for this beat'em up game. Here is the capx.
Still no help? Anyone?
Develop games in your browser. Powerful, performant & highly capable.
cristixxx Thanks for providing the capx, but could you also include a written summary of what you're looking for? It is difficult to discern what an appropriate AI workup would be without understanding what you want the AI to DO.
Well, if the distance between the enemy and the player is smaller than,let's say 300, i would like to move towards the player until it reaches a collision distance; when it's on that position i would like the enemy to attack every x seconds; also, if at that position already is an other enemy then with a random chance to move to the back of the player or wait untill the other enemy clears the position; i tried to make something with finite states and with little randomness between them not to be too repetitive but i haven't done any AI so far and any help would be enough for me.
This doesn't do everything you want but might help.
Thank you!
Will this help you?
https://www.scirra.com/tutorials/1320/p ... enemies-ai
also this may help for your less than 300 range thingy:
System compare two values :
1.distance(player.X,player.Y,enemy.X,enemy.Y)
< is less than
2. 300