Re: Timing system?
Reply #10 –
Ahh, I see: you mean this code:
if(ticks>next_month_ticks) {
ticks %= karte_t::ticks_per_tag;
ticks += karte_t::ticks_per_tag;
next_month_ticks = ticks+karte_t::ticks_per_tag;
last_step_ticks %= karte_t::ticks_per_tag;
}
That (sensibly) only resets the ticks if there appears to be an overflow immanent; but, with an unsigned 32-bit integer (max. value: 4,294,967,295), that is unlikely to happen (if 50 game years produced approx. 132 million ticks, then a player would have to be playing for over one and a half game millennia at the default time setting for the ticks to overflow)!