Want to Make Events Respawn Upon Player Death

mkelly527

Veteran
Veteran
Joined
May 17, 2021
Messages
37
Reaction score
3
First Language
English
Primarily Uses
RMMV
Hey guys, I'm making a game in which the player must advance through a series of increasingly more challenging maps. The player must survive in a map for a certain amount of time, then they are transferred to a "break map" for 10 seconds, then transferred to the next map. When they are in the break map they have the option to purchase an ability (skill). Once they purchase that ability, a new one becomes available for purchase.

When the player dies, they are sent back to the first map to restart the game and lose all the skills they purchased in their prior run(this is all functioning correctly). However, when they are transferred to the break map and have purchased a skill in the prior playthrough, it is not available to be purchased again. I understand what my problem is, clearly I need to run some sort of check that upon player death, the event that allows the players to buy the skills is reset. However, I've been having a lot of trouble doing this, so if anyone can help me out that would be much appreciated! I'll include screenshots of the current event below. Again, the event works fine when the player starts a new game and purchases it for the first time, the problem is that it isn't being reset to be purchased again upon death. I understand that this explanation may sound confusing, so let me know if anything needs clarification!

(The first picture is the first skill the player can buy. The second picture is the second skill the player can buy. The third picture is just a blank event page because once the player has purchased all the skills, I don't want any image to be shown)
 

Attachments

  • Untitled.png
    Untitled.png
    268 KB · Views: 2
  • Untitled2.png
    Untitled2.png
    271.7 KB · Views: 2
  • Untitled3.png
    Untitled3.png
    226.2 KB · Views: 2

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,713
Reaction score
2,830
First Language
English
Primarily Uses
RMMZ
When the player dies, you need to turn off self switches A and B in that event. Otherwise, when they return to it, those self switches are still on and the event will be running page 3.
 

mkelly527

Veteran
Veteran
Joined
May 17, 2021
Messages
37
Reaction score
3
First Language
English
Primarily Uses
RMMV
When the player dies, you need to turn off self switches A and B in that event. Otherwise, when they return to it, those self switches are still on and the event will be running page 3.
Great that worked! Thanks for the quick response!
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
3,713
Reaction score
2,830
First Language
English
Primarily Uses
RMMZ
Any time! Glad to be of assistance.
 

Latest Threads

Latest Profile Posts

how does everybody even finish anything

i have like 5 projects in the backburner and it's just so sad that i probably won't get to finish all or maybe even any of them
Did you know that 90% of people in the world use the number in their sentence as they see fit?
It's been a long time since I was here but I have a lot of updates... btw I am teaching again about game programming and game design in some schools here in Brazil hahahaha It's good to see kids and teens learning this kind of thing!
welp, I literally can't continue working on ALEX now that my MZ trial is up (unless I somehow place in the jam which I don't remotely deserve to for my unfinished crap) so I am back on my bullshit

Forum statistics

Threads
113,891
Messages
1,078,235
Members
147,983
Latest member
H3ctorGH
Top