I want to have an object that will function as an enemy. When the players object comes within an x number of pixel radius, the object will chase the player. When the player escapes that radius, the object will cease following until the player reenters.
So basically, an enemy has a personal space, and when you invade that personal space, it chases you until you manage to leave it.
How exactly do I do this?
Thanks in advance.
-Sil