How do you reset a room during testing?

I'm pretty new to RPGmaker Ace and looking through other peoples work to get an idea how I want to do my own work when it comes down to the game making part. While I been making additions and changes to what I'm testing, I discovered an issue and not sure how to get around it. Because the character has already done what was already needed in a room, I can't fully test what I have done because it saves the data showing that room/event was completed. How do I reset that room without having to start the entire game all over? For example, in this room there are npc's, a puzzle, and game, and all have been triggered. Now that I made some changes, I need to be able to get this room to reset so I can test it as if nothing was done in it.
This is a good place to start... I am fairly new myself, so can't really help you with your issue, but these tuts are the best place to start...  also, most of the info will also work in MV except the ones you need to do script calls for... 
Well, first of all these tutorials are really useful and well made. That said the answer to your problem lies in the question itself. Your NPC, Puzzle and Game have to be reset. Now the question is: "how did you trigger them?"


I assume you did tht using switches, self switches and variables. Reset switches and variables while testing is easy: press F9 (it opens the switches and variables list and only works while testing), find your variables/switches and reset them. If you used self switches as well you have to reset them manually.


How to reset self switches:


Create an event that you can activate and place it wherever you want. If it is visible then even better so you won't miss it (I do it sometimes or I forget to delete them). In the event window add a script call (3rd page, last entry on the right: Script) and once there write this:


$game_self_switches[[@map_id, your_event_id, 'switch']] = false


where your_event_id is the id of the event you want to access and switch is the self switch you want to reset. Don't forget the ' before and after your switch name! Self switch A is 'A', self switch B is 'B' and so on. The last value is false but it could even be true, that depends on what condition you used in your event. If it is no longer active when the switch is ON Then set it to false, if not then set it to true. I just assume you have to set it to false because self switches are initialized to false.


Here is an example. My event id here is 14 and my switch is C.


$game_self_switches[[@map_id, 14, 'C']] = false


If you changed your event name and you don't know where to find its ID you can look at the event window title (the very upper part) and you will find it.


I hope this helps you.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-you-reset-a-room-during-testing.70628/