How can I make the weather random with the Mog Time System?

I have tried but it wasn't random.
if you want it random per hour or per day, create a common event with
a variable x (x being the hours or day) or use a random 1-4 weather

than use a conditional

if variable x = 0
nothing happend
end
if variable x = 1
rain
end
if variable x = 2
snow
end

etc, you can also make it different per hour in the same way, use x as hours,
or as day or whatever you want it to be.
You need to give more of an explanation of how you want to set it up, and show what you attempted to do. We need at least a little bit of information to help you.
You need to give more of an explanation of how you want to set it up, and show what you attempted to do. We need at least a little bit of information to help you.
This is what I tried.
Alright, for starters, all of your event pages are set to Action Button trigger, so NONE of them are going to do anything based on any kind of time system - unless the player interacts with them, and that's highly unlikely.

Then there are flaws in the design. Let's look at the first one - page 2 is active if switch 21 is on and self switch A is on. But in the event commands you have a test to see if switch 21 is on. Of course it will be on, as this page won't be active if it isn't.

Again on page 1, you've got the page conditioned by switch 26 being on, and then you do a conditional branch to do something if switch 26 is on. It HAS to be on for that condition to even be checked, because if it's NOT on, that page won't even be active.

Changing them to parallel process trigger won't solve the problem either, because that'll make the commands run every frame, which you also don't want.

I suggest you visit some basic tutorials that explain how to use switches, self switches, multiple event pages, and different event triggers.

And then tell us what you're trying to accomplish. Don't just say "random weather" - say when you want it to rain, or snow, or be sunny or dark. However, saying "I want it to rain between 9am and 14pm (?)" isn't really random either.
Alright, for starters, all of your event pages are set to Action Button trigger, so NONE of them are going to do anything based on any kind of time system - unless the player interacts with them, and that's highly unlikely.

Then there are flaws in the design. Let's look at the first one - page 2 is active if switch 21 is on and self switch A is on. But in the event commands you have a test to see if switch 21 is on. Of course it will be on, as this page won't be active if it isn't.

Again on page 1, you've got the page conditioned by switch 26 being on, and then you do a conditional branch to do something if switch 26 is on. It HAS to be on for that condition to even be checked, because if it's NOT on, that page won't even be active.

Changing them to parallel process trigger won't solve the problem either, because that'll make the commands run every frame, which you also don't want.

I suggest you visit some basic tutorials that explain how to use switches, self switches, multiple event pages, and different event triggers.

And then tell us what you're trying to accomplish. Don't just say "random weather" - say when you want it to rain, or snow, or be sunny or dark. However, saying "I want it to rain between 9am and 14pm (?)" isn't really random either.
Those events were just a test and they did work with the parallel process on, but I don't know how to make them appear on random times of the day.
Pseudocode of a very basic test setup could look like this:

If Variable Total Game hours is equal or more than Variable2
- If yes: Set Var 2 to random 1 to 6(Hours) ; Control Variables2 add Variable total Game hours. (This is somehow like a Timestamp)
- Control Variable3 to Random 1 to 3
-- If Var3 = 1
-- Set Weather Rain
-- If Var3 = 2
-- Set Weather Snow
-- If Var3 = 3
-- Set Weather Sun

Edit:
The Weather will not change until the random amount of 1 to 6 hours has passed.
Pseudocode of a very basic test setup could look like this:

If Variable Total Game hours is equal or more than Variable2
- If yes: Set Var 2 to random 1 to 6(Hours) ; Control Variables2 add Variable total Game hours. (This is somehow like a Timestamp)
- Control Variable3 to Random 1 to 3
-- If Var3 = 1
-- Set Weather Rain
-- If Var3 = 2
-- Set Weather Snow
-- If Var3 = 3
-- Set Weather Sun

Edit:
The Weather will not change until the random amount of 1 to 6 hours has passed.
Can you show a screenshot please, cos I'm stupid and confused?
I made a simple example, every 5 to 10 Seconds the Weather changes randomly.
In this basic setup Rain could happen 10 Times in a Row, but i hope it helps to get started with this.
rpgmakerharpweathermanipulation01.PNG
I made a simple example, every 5 to 10 Seconds the Weather changes randomly.
In this basic setup Rain could happen 10 Times in a Row, but i hope it helps to get started with this.
View attachment 153163
How do I change it from seconds to hours and have you tried this with the mog time system plugin?
1 Minute got 60 Seconds, 1 Hour got 3600 Seconds.
So instead of Random 5 to 10 you would do for 1 to 2 hours of weather: Random 3600 to 7200
or 36 to 72 and than multiply with 1000.
1 to 2 Hours of Realtime and Game running is a very long amount of Time.

I never used Mog Time System, but i guess it somewhere contains a Variable that has the total game time stored in it. I assume 1 hour in mog time system around 2 Minutes of real life Time? so i see the benefit of conecting that variable with the weather change system. For example if an Inn Event is skipping time forward, than the weather would also change,but not in the current code build, yet.
1 Minute got 60 Seconds, 1 Hour got 3600 Seconds.
So instead of Random 5 to 10 you would do for 1 to 2 hours of weather: Random 3600 to 7200
or 36 to 72 and than multiply with 1000.
1 to 2 Hours of Realtime and Game running is a very long amount of Time.

I never used Mog Time System, but i guess it somewhere contains a Variable that has the total game time stored in it. I assume 1 hour in mog time system around 2 Minutes of real life Time? so i see the benefit of conecting that variable with the weather change system. For example if an Inn Event is skipping time forward, than the weather would also change,but not in the current code build, yet.
I guess this problem will never get solved cos I'm too stupid and need everything to be done for me.
I looked at the Link for the Plugin.
It looks like it doesnt have a Variable for "total Time" explained in the Info, without that i cant do anything.

Maybe someone else knows that Plugin and maybe found that Variable if it exists in that Time System.
I looked at the Link for the Plugin.
It looks like it doesnt have a Variable for "total Time" explained in the Info, without that i cant do anything.

Maybe someone else knows that Plugin and maybe found that Variable if it exists in that Time System.
It has both an hour and a day of month variable.
Iam not sure, i believe those are the Clock hours which reach from 0 to 23 o clock and than start from 0 again. Those are not realy helping in this case and easily lead to Bugs.

Did you test the System i showed in the picture?
Maybe i can advance the system a little bit to make it fit.
How much Real Time passes in 1 hour of Ingame Time?

Edit:

I changed the Code, it still uses standard total game time value(in seconds), but i included a switch.
If you turn thatone on, a new time stamp is created and the roll of the random weather dice happens before the timer ran out of time. That is perfect for inns where you sleep a whole night or for other stuff.

Would that be close enough to what you want? Else: please explain in detail.
weatherharpinnswitch14651.PNG
Iam not sure, i believe those are the Clock hours which reach from 0 to 23 o clock and than start from 0 again. Those are not realy helping in this case and easily lead to Bugs.

Did you test the System i showed in the picture?
Maybe i can advance the system a little bit to make it fit.
How much Real Time passes in 1 hour of Ingame Time?

Edit:

I changed the Code, it still uses standard total game time value(in seconds), but i included a switch.
If you turn thatone on, a new time stamp is created and the roll of the random weather dice happens before the timer ran out of time. That is perfect for inns where you sleep a whole night or for other stuff.

Would that be close enough to what you want? Else: please explain in detail.
View attachment 153282
This event doesn't work also 10 mins in IRL equal 1 hour in-game.
This event doesn't work also 10 mins IRL equal 1 hour in-game.
Edit: Please post a Picture of your Eventpage like i did above, than we can maybe pinpoint the Error.

Windows Snipping Tool is useful to do make Pictures of that.

Edit2: To make sure if the System is working i would recomment changing the Time the Weather lasts back to 5 to 10 Seconds, no need to wait 2 to 5 mins for every random change while early Testplay.
Edit: Please post a Picture of your Eventpage like i did above, than we can maybe pinpoint the Error.

Windows Snipping Tool is useful to do make Pictures of that.

Edit2: To make sure if the System is working i would recomment changing the Time the Weather lasts back to 5 to 10 Seconds, no need to wait 2 to 5 mins for every random change while early Testplay.
This works quite well with the action button trigger but not the parallel.
My English aint the best and i dont want to force you to use one particular out of many solutions.
But iam not sure how to explain and help to reach you better.

If i compare the 2 Pictures, they look very differently.
Maybe first it would be best, try to rebuild the one i have shown you and if it works (It works =)), than try to change it or build one from Scratch later on if you got the motivation for experimenting further with it.

If you have trouble finding the correct Eventcommand Names for the Commands in the Picture, let us know.

Original thread: https://forums.rpgmakerweb.com/threads/how-can-i-make-the-weather-random-with-the-mog-time-system.124623/