mirror of https://github.com/OpenTTD/OpenTTD
Codechange: use TileDiffXY(0, 0) over magic 0
parent
3b0fcf442f
commit
a6b7593a52
|
@ -44,7 +44,7 @@ void RebuildTownCaches()
|
||||||
if (IsHouseCompleted(t)) town->cache.population += HouseSpec::Get(house_id)->population;
|
if (IsHouseCompleted(t)) town->cache.population += HouseSpec::Get(house_id)->population;
|
||||||
|
|
||||||
/* Increase the number of houses for every house, but only once. */
|
/* 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 */
|
/* Update the population and num_house dependent values */
|
||||||
|
|
|
@ -2934,7 +2934,7 @@ TileIndexDiff GetHouseNorthPart(HouseID &house)
|
||||||
return TileDiffXY(-1, -1);
|
return TileDiffXY(-1, -1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 0;
|
return TileDiffXY(0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue