mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 22:28:56 +00:00
Codechange: use TileDiffXY(0, 0) over magic 0
This commit is contained in:
parent
3b0fcf442f
commit
a6b7593a52
@ -44,7 +44,7 @@ void RebuildTownCaches()
|
||||
if (IsHouseCompleted(t)) town->cache.population += HouseSpec::Get(house_id)->population;
|
||||
|
||||
/* Increase the number of houses for every house, but only once. */
|
||||
if (GetHouseNorthPart(house_id) == 0) town->cache.num_houses++;
|
||||
if (GetHouseNorthPart(house_id) == TileDiffXY(0, 0)) town->cache.num_houses++;
|
||||
}
|
||||
|
||||
/* Update the population and num_house dependent values */
|
||||
|
@ -2934,7 +2934,7 @@ TileIndexDiff GetHouseNorthPart(HouseID &house)
|
||||
return TileDiffXY(-1, -1);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
return TileDiffXY(0, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user