Setting a wait time

Hey guys,

So i haven't been able to find out exactly how to do this so far.. And I'm kind of confused.. From what i've been reading its possible to call a script from with an event (i need this because i require an event across multiple blocks, but i need these events to be instanced. so each event is unique..(i tested a version before without scripts and it didnt work out..) But the main problem i have is.. How can i get an event to simple do one thing.. Wait X minutes then go to the next event? To explain what i mean by these.. I'm trying to get an event change the sprite on the screen every 5 minutes.. At the begining I have a choice option yes or no, When its yes, its switches, how ever once i get to the part where it needs to start automating the procress it doesnt switch i have.. but this wont change the event from the current one..

Code:
Wait: 60 Frame(s)Control Switches:[0002:Block Stage 2] = ONControl Switches:[0001:Block Start] = OFF
60 frames could very well be just 1 second for you.
Everything is default, I'm just doing this as a test, so yeah it should be one second.. However after one second the graphic isnt changing.. I guess you could call it an animation.. Or put more simply for example a plants growth stage after x minutes (in this case 1 second) the plant would go from a seed to a sapling) the seed is there.. But the sapling wont appear 1 second later.
You will probably need to be clearer about what you want.  But if I'm understanding it correctly, here's what you might be doing wrong:

1) The event needs to be a Parallel Process.  If it's set to something like Action Button, it will not run automatically.

2) The event needs to be a Common Event, OR needs to be an ordinary event on the map that the player is currently standing on.

3) You will need a "Show Picture" or similar command to actually change the sprite displayed on the screen.  If your script judges the value of the Switch and displays a picture accordingly then you're fine, but without a script to specifically do that, what you have won't do anything but change a Switch.
Please post a full screenshot of your event if you want us to check it for you.


As Wavelength said, an event is more than just the content area - and we need to know the other settings and selections you did to check where the problem is in your event.
If you have something set up as a parallel process, it's going to keep running over and over until you turn it off. Things with Waits in them, that are then meant to take other actions, could have problems with this.

The other issue is, if you are using an event on the map to control this, if you leave the map it stops running. When you return to the map it'll start again, but won't pick up from where you left off. It'll start the 5 minute count again.

Here's how I would (and actually have) handled things like this ... note, this acts as though it keeps changing when you're on another map, so when you return to the same map again it might not have the same sprite, and it might not have the next one in line.

A common event set to Parallel Process (conditioned by a switch that you turn on the moment you want the image changing to start). It has commands like this:

Code:
Wait 60 Frames (1 second)Control Variables [0001: Image Changer] += 1Conditional Branch: Variable [0001: Image Changer] == <max value> (if you only want to show 4 images, put 4 here)  Control Variables [0001: Image Changer] = 0Branch End
Then on your event, have 4 pages. The first will have no conditions, the second will be conditioned by the variable == 1, the third by the variable == 2 and the last by variable == 3. Put the appropriate sprites on each of those.
Hey guys here are the screenshots of what I'm trying to do..

[IMG]http://i.imgur.com/CjacYtU.png[/IMG]

[IMG]http://i.imgur.com/ePaYFFb.png[/IMG]

[IMG]http://i.imgur.com/BrtsESn.png[/IMG]

[IMG]http://i.imgur.com/hVX3bzj.png[/IMG][IMG]http://i.imgur.com/290uBl6.png[/IMG][IMG]http://i.imgur.com/xG3Z28I.png[/IMG]

I was wondering if someone was able to tell me how it would be possible to have an event like this go across multiple tiles (see game screen) would i need to write a script for this to be possible?
Here is a good thread on setting up a farming system.
I have a "large event collision" script that would allow you to place the event in the lower left corner of that block, then interact with it from ANY tile in that block. However, the image only takes up the space of the sprite in the file - it would not repeat over the whole area. You would need to create a new character sheet that has as many plants/seeds/whatever as you require over the whole block.


Unless you want to be able to till/plant/water each tile individually - then you'd need to copy the event and paste it, and probably use different switches (self switches would be better here).


Note - you don't need all those switches and to turn them off/on on each page. You can either use a variable, and increment the variable at each step then set it back to 0 when you want to start over (then your conditions won't be switches, but will be the variable with increasing values), or you could use self switches. Again, that depends on whether you want to interact with the whole plot in one hit, or each tile individually.


But yes, there are a few tutorials on making farming systems using events. It would be good for you to chase some of them up and take a peek at them 🙂
Good advice from Shaz - definitely use either variables or self-switches for this kind of thing.

I also notice that Page 4 is turning its own Requirement switch off before it sets the new one.  I think RPG Maker still gives you one more event command before it stops running the page, but if your event seems to stop running on Page 4, this probably explains why.

Original thread: https://forums.rpgmakerweb.com/threads/setting-a-wait-time.34758/