L
lachlantopcat games
Guest
so I'm making a game that has keys in it and when thay follow you thay can get stuck and thay randomly move
the key will move randomly when the player is standing still.
the code:
the key will move randomly when the player is standing still.
the code:
Code:
//move to the player
if (instance_exists(obj_player)){
mp_potential_step(obj_player.x, obj_player.y, 10, false);
}
//player attacking follow
if (instance_exists(obj_atackr)){
mp_potential_step(obj_atackr.x, obj_atackr.y, 10, false);
}