Hi, so I am trying to extend the duration of the day&night cycle with weathersync but I cant seem to get it perfectly right. I was able to extend the time somewhat but it is kinda unpredictable, because I edited the baseTime formula in server.lua to be divided by 9.6 instead of 2 for roughly 2.5 irl hours for one ingame day night cycle. However the sun still jitters when moving in the sky it just does so less frequently. Thanks in advance!
#Change day night cycle duration with qb-weathersync
1 messages · Page 1 of 1 (latest)
Sharing the code you edited would be helpful in supporting you.
When asking for support help; help us help you!
Provide full context.
- Expected Result
- Current Result
- Method to Replicate Error
Provide Error
- Screenshots of both Client and Server sided Errors
Provide Source Code
- ** Screenshot of corresponding source code related to the error**
Hi this is the change in question that I've made. Config is untouched.\
Also changing the BaseTime and TimeOffset did't seem to do much for me. From my own testing this is the only change that affects te overall duration.
Okay, revert the change you made in the server. That's not going to work.
Try changing client/client.lua:80 to local timeIncrement = Config.RealTimeSync and 0.05 or 0.5
then same file, line 88: replace with if tick - (Config.RealTimeSync and 5000 or 100) > tick then
So the first change should reduce the cycle, making day/night twice as long.
The second change makes updates happen less frequently.
Thank you will try this asap and will inform you of the result!
This is the result. The night sky seems to be jittering a lot more and I can't confirm if the day&night cycle has been extended. My target is roughly 2.5 real life hours for one day/night cyce ingame.
From here it'd just be a matter of playing around with those values to achieve the result you're after.
Alright. Thanks. So if I understand right lowwer values means longer days?
For the 'jittering', that'd be the tick value.
Yeah, so the default timeIncrement of 1 means the game time progresses by 1 minute every tick.
So 0.5 would half that.
If my maths is right 😉
Amazing thank you so much!