Hundreds of features to explore
Games made in Construct
Your questions answered
Popular & trusted by schools and Universities world-wide
Construct 3 runs in the browser & works offline
Students do not need accounts with us
World class complete documentation
Official and community submitted guides
Learn and share with other game developers
Game development stories & opinions
I have multiple slimes that crawl around and I want them to follow the player when they get in a certain range of him. I want them also to have minds of there own so they all don't do the same thing.
Develop games in your browser. Powerful, performant & highly capable.
Well AI is a tough thing. The follow the player, you will want to use the Distance expression to check if the player is within a certain distance of slime, if so change the slime's actions.
Give them a variable called state
Every x seconds change the state to random (walk left/right whatever)
if enemy is in x distance set state to follow / attack and so on :)
Thanks, but I still need help xD. I dont know how to do the state thing. When I name a variable it wont let me add a left and a right state.
You might want to start out going through the platformer beginner tutorial on the tutorials page. It's basics will really help out.
If you're going to have delays on actions, also set it as instance variable instead of the "Wait 1 seconds" condition. Guarantees each instance has their own timing.
Add 1*dt to Sprite.Time
Subtract 1 from sprite time
would be awesome if someone posted an e.g of an enemy AI for a platformer