summaryrefslogtreecommitdiff
path: root/src/saveload/afterload.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/saveload/afterload.cpp')
-rw-r--r--src/saveload/afterload.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/saveload/afterload.cpp b/src/saveload/afterload.cpp
index 329152ab2..c3aef307b 100644
--- a/src/saveload/afterload.cpp
+++ b/src/saveload/afterload.cpp
@@ -599,8 +599,8 @@ bool AfterLoadGame()
int dx = TileX(t) - TileX(st->train_station.tile);
int dy = TileY(t) - TileY(st->train_station.tile);
assert(dx >= 0 && dy >= 0);
- st->train_station.w = max<uint>(st->train_station.w, dx + 1);
- st->train_station.h = max<uint>(st->train_station.h, dy + 1);
+ st->train_station.w = std::max<uint>(st->train_station.w, dx + 1);
+ st->train_station.h = std::max<uint>(st->train_station.h, dy + 1);
}
}
@@ -2457,7 +2457,7 @@ bool AfterLoadGame()
uint per_proc = _me[t].m7;
_me[t].m7 = GB(_me[t].m6, 2, 6) | (GB(_m[t].m3, 5, 1) << 6);
SB(_m[t].m3, 5, 1, 0);
- SB(_me[t].m6, 2, 6, min(per_proc, 63));
+ SB(_me[t].m6, 2, 6, std::min(per_proc, 63U));
}
break;
@@ -2713,7 +2713,7 @@ bool AfterLoadGame()
_settings_game.pf.reverse_at_signals = IsSavegameVersionBefore(SLV_100) || (_settings_game.pf.wait_oneway_signal != 255 && _settings_game.pf.wait_twoway_signal != 255 && _settings_game.pf.wait_for_pbs_path != 255);
for (Train *t : Train::Iterate()) {
- _settings_game.vehicle.max_train_length = max<uint8>(_settings_game.vehicle.max_train_length, CeilDiv(t->gcache.cached_total_length, TILE_SIZE));
+ _settings_game.vehicle.max_train_length = std::max<uint8>(_settings_game.vehicle.max_train_length, CeilDiv(t->gcache.cached_total_length, TILE_SIZE));
}
}