Events day / night

Nantas

- Game developer -
Veteran
Joined
Jan 7, 2017
Messages
209
Reaction score
138
First Language
French
Primarily Uses
RMMV
Hello everyone !

I've decided recently to add a time system with a plugin ( I tried with events but I decided to do it
differently, but this question is not about plugins).

I've done some mapping and I've created a town. But when I finished it all, something came to my mind :
How do I make events stay at a place outside when it's daytime, and disappear (to make it simple) when it's nightime ?
Because it feels unnatural to have NPC's outside like in the morning, waiting there all day and even all night ^^
It doesn't feel real.

So I searched in the event's pages, but I remembered then that an event cannot return on page 1 (in the event's database) when it has already gone to page 2 or 3....

If someone has an idea on how to make it, I will be very thankfull !!

PS : My english is quite bad (not native english) so don't be afraid to ask me to precise again some things !
 
Last edited:

Jeremiah Eastman

Gladiator
Veteran
Joined
Apr 24, 2017
Messages
510
Reaction score
315
First Language
English
Primarily Uses
RMMV
You can go back to page one in an event by turning off whatever conditions turned the other pages on. For Day night events the way I do it is every map has a parallel process for dimming the screen when it gets nighttime or light in the day. If I have events that are going to be day night in the map I will add, to the parallel process,

Condition Branch, If Hours >= 16 Turn switch on, Else turn switch off.

Then in the events you use just make a 2nd page turned on by the switch for >=16 which is night time. With this when it hits day time the switch will be turned off resetting the events to page 1.
 

gstv87

Veteran
Veteran
Joined
Oct 20, 2015
Messages
2,248
Reaction score
1,250
First Language
Spanish
Primarily Uses
RMVXA
events are checked for spawning at map load time.
if you have a page 1 set to trigger at day time, and it's night, it'll ignore page 1 and go to page 2.
if you have a day cycle that changes the time of day while the same map is loaded, you'll have to force a reload, so that all the events get checked again, and those that appear during the day will trigger page 1.
 

Nantas

- Game developer -
Veteran
Joined
Jan 7, 2017
Messages
209
Reaction score
138
First Language
French
Primarily Uses
RMMV
I have tested what you proposed Jeremiah and it worked perfectly well !
In fact, I have forgotten that a switch can also be switched off, making the event's page return back to the previous pages ^^

Thank you you two ! You are really nice to answer me so fast !
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,860
Messages
1,017,038
Members
137,568
Latest member
invidious
Top