Hello everybody, How are you ? well, i have a problem with my procedural map generation code, and i would like to know about something.
Explaining previously about how the game is: you are created on a map, which is almost a totally random maze, and every time you find the exit, the room is restarted.
(images as an example)
The problem: when I put obj_player as persistent so that its code is not lost (like life, points, weapons etc.), when the room restarts, obj_creater ends up creating several players a lot at once, making everything turn into a full chaos of player. The game itself works well, a problem that every time "move to the next room" ends up losing all information and so everything is restarted.
is there any way to just keep a part of the code as persistent? or, how can I get the other instances of the player to be destroyed? thanks for your attention and thanks for all the help
Explaining previously about how the game is: you are created on a map, which is almost a totally random maze, and every time you find the exit, the room is restarted.
(images as an example)
The problem: when I put obj_player as persistent so that its code is not lost (like life, points, weapons etc.), when the room restarts, obj_creater ends up creating several players a lot at once, making everything turn into a full chaos of player. The game itself works well, a problem that every time "move to the next room" ends up losing all information and so everything is restarted.
is there any way to just keep a part of the code as persistent? or, how can I get the other instances of the player to be destroyed? thanks for your attention and thanks for all the help