How to make enemies chase player in a maze gamePut the Move Towards or whatever its called, its the 3rd move action in the moves section, put it in the Step event and type obj_player.x and obj_player.y
A MenuIf u cant do it the GML way, do it this way
Create five instances
one named New Game and the other named Continue
the other two is the two buttons' highlighted version
and the control object
put the highlighted New Game and the non-highlighted Continue in the room
when pressing the down button, put this in the New Game object
Change instance continue to highlighted_continue and highlighted_new_game to new_game
put this in the control object when the space key is pressed, just use the check instance action, if highlighted_new_game is equal to 1, go to the first level and vice versa, if highlighted_continue is equal to 1, load the game
simple? this is for those who doesnt want to type gml
and will be harder for more than two options
Pausedeactivate all instances and set notme to true
- Code: Select all
{
instance_deactivate_all(true);
instance_create(pausebutton1,x,y)
instance_create(pausebutton2,x,y)
instance_activate_object(pausebutton1);
instance_activate_object(pausebutton2);
}
that will deactivate all instances except for the buttons in the pause menu
when the resume key is pressed, or the resume button is clicked
- Code: Select all
instance_activate_all;
i hope this helps. The pause code is not tested, so im not sure it will work