D
Den
Guest
So in the game i'm making the player can possess an enemy which I have manged to do.
The only issue is how can I make the player possess just one enemy at a time?
Here's the code, it's just if I take control of one it controls all of them. Is there a way to make each enemy react differently to the player??
The only issue is how can I make the player possess just one enemy at a time?
Here's the code, it's just if I take control of one it controls all of them. Is there a way to make each enemy react differently to the player??
Code:
//Step
///Check if player is over enemy
if(place_meeting(x, y, obj_player)) {
image_index = 2;
with (obj_player)
{
if(obj_player.interact_key) instance_destroy();
}
}else if(!place_meeting(x,y, obj_player)) image_index = 0;
if(instance_exists(obj_player)) {
//AI script goes here
}else if(!instance_exists(obj_player)) {
enemy_input_scr();
image_index = 1;
}