(svn r25832) -Codechange: Reduce variety of object type test functions.

This commit is contained in:
frosch
2013-10-12 16:30:22 +00:00
parent b1131671d4
commit 2080a8c16f
4 changed files with 34 additions and 77 deletions

View File

@@ -1444,7 +1444,7 @@ bool AfterLoadGame()
if (IsSavegameVersionBefore(52)) {
for (TileIndex t = 0; t < map_size; t++) {
if (IsStatueTile(t)) {
if (IsTileType(t, MP_OBJECT) && GetObjectType(t) == OBJECT_STATUE) {
_m[t].m2 = CalcClosestTownFromTile(t)->index;
}
}