How do I make a event for a sprite that randomly changes direction? It uses the 8 directional behavior. I'm trying to pretty much make an AI that goes against the player.
Develop games in your browser. Powerful, performant & highly capable.
You can use choose("A", "B", "C", "D") which picks one at random and then you relate the choices to direction, possibly an instance variable on the AI that makes them move in one of 4 directions.
Is there like an image that you can show me?
Hi Nightwatch!
This file has one way of doing it.
I have an interval (which here is global, but could be different for each unit) and after that interval the unit chooses one of eight directions.
Hope this helps...
Cheers!
This is perfect, thank you!