Eventing Question: Map re-entering takes precidence over wait commands?

I've been reading around and noticed that events that have already run will 'refresh' so to speak once you return to a map...

How can I get around an event refreshing without Exiting event processing or erasing the event?... Say, maybe making it wait a certain amount of time before running itself over again?

So the event would be activated by the player, it would run, it would wait according to wait commands and then re start again if the player were to interact with it... but the catch is, I wouldn't want the player to just be able to just re enter the map in order for the event to restart more quickly... I read through the differences between Exiting Event Processing and Erasing Events, but I don't think those are what I need. I also read through Self Switches but the problem with that is that the event wouldn't run again after the wait commands... it would just be a dead event.

An example in gameplay would be as follows:

1- Player interacts with a fruit tree on Map A

2- After x amount of time, the fruit tree bears more fruit (even with the player exiting/re-entering Map A).

I know there are Wait commands and I'm familiar with them, but wouldn't the event just refresh if a player simply re-entered the map? I'm probably sounding pretty repetitive... too much coffee, you know? lol

I work with Ace, by the way.
You need to use variables for this and a way to keep track of time.


When you first pick a fruit, set a variable to the current frame count, and self-switch itself into a second page.


This second page is a parallel process that does all the time checking: it first determines how much time you need to wait by getting the difference between the current frame count with the stored frame count. If the amount of time is 0 or less, then you turn off the self-switch and go back to the first page. If the time is greater than 0, that's how much time the event will wait.
Thank you for the quick reply!

I get the basic idea of what I need to do, based on what you said. So I would use conditional branching to specify the time I would like the event to wait?
You could skip the conditional branch altogether, as "wait 0 seconds" isn't really going to cause a problem once you get the actual amount of time you need to wait.


However you'll need to figure out how to actually "wait x seconds"
If you don't mind adding scripts to your game, I wrote one that does exactly this (and I use it exactly for the purpose you describe in my game).


It lets you set a timer for an event that does not require you to leave or re-enter the map, and does not need variables or parallel processing event pages. If you only have a few trees, doing it entirely with events is fine. But if you have a lot, that's a lot of variables to create just to keep track of time.


http://forums.rpgmakerweb.com/index.php?/topic/1516-extended-game-timers/
That script is a lifesaver and definitely more realistic considering I would have quite a few trees! Thank you, Shaz.

And thanks Tsukihime, I understand eventing a little better now =]
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/eventing-question-map-re-entering-takes-precidence-over-wait-commands.21360/