Codechange: Use proper date types in various places (#11177)

This commit is contained in:
Tyler Trahan
2023-08-11 09:32:42 -04:00
committed by GitHub
parent c9c9cfa4fd
commit c7b51a8c3a
7 changed files with 12 additions and 11 deletions

View File

@@ -761,7 +761,7 @@ uint32_t Vehicle::GetGRFID() const
*/
void Vehicle::ShiftDates(int interval)
{
this->date_of_last_service = std::max(this->date_of_last_service + interval, 0);
this->date_of_last_service = std::max(this->date_of_last_service + interval, TimerGameCalendar::Date(0));
/* date_of_last_service_newgrf is not updated here as it must stay stable
* for vehicles outside of a depot. */
}