PC How does the game's time work?

Arez

Well-known member
I have my 24 hour periods set to 60 mins. I streamed the other day and judging by the timer on the Youtube video, it took more than 73 minutes to complete a 24 hour cycle.

I suspect that frame drops, due both to performance and also from going in and out of menus, helps push the time a little, but over 10 minutes seems like a lot. Also I don't know how accurate the Youtube time display is, but again, over 10 minutes seems like a lot. 

So what would be causing such a discrepancy?  

Here's what I got from the YouTube video:

Day 1 - 23:44 (1:00:00)
Day 2 - 19:29 (2:00:00)
Day 2 - 23:44 (over 2:13:00) I paused the game twice starting at 2:12:24 / 23:32 for approx. 20 collective seconds.

 
Back when I was modding I needed to create timers that would award a skillpoint after a full day of surviving. If the player died the timer would start over. After one day of survival you earned one skillpoint, after two days you earned two skillpoints, and after three days you earned three skillpoints and then three each day after that. If you died then you started over at one again and had to build it up.

Anyway, the timers always had to be set longer for them to coincide with the full game day. I had to play around with them quite a bit as I wanted timers for the different day length settings and in every case the timers were longer than the day lengths. But it was consistently the same amount of time longer in each case so I don't think it was due to random lag or menu use as those things would vary from 24-hour period to 24-hour period.  Once I had my timers tuned correctly they matched up perfectly every day.

 
Supposedly 50 min days are the closest to one real life hour. Ultimately this is just a programming issue of how they chose to calculate the passage of time based on the settings.
 

To make this clearer, they are probably using decimals to keep track of time and those values are being truncated or rounded. Alternatively, there is some weirdness in Unity (or how they have chosen to code timekeeping) that leads to this. 

 
Last edited by a moderator:
While not going into any menu and remaining as stationary as possible while recording a full 24 hour period, a 60 min day is 72 mins 40 secs and 14 frames (at 60 fps video). 

From the Youtube footage, while playing normally, and also subtracting the time in which I was paused (which isn't frame accurate) the full 24 hour period was 72 mins and 57 seconds. I imagine the margin of error, from counting the seconds that I was paused based on the Youtube time display, could only be a few seconds at most. So that extra 10+ seconds could either be from frame dips or video recording / encoding discrepancies, or a combination of both. 

 
Last edited by a moderator:
Back
Top