mirror of https://github.com/OpenTTD/OpenTTD.git
(svn r11268) -Fix[FS#1336]: Call IsSlopeRefused whenever it is required. Looks like there was one spot missing. Thanks frosch
This commit is contained in:
parent
4a7e446d35
commit
a1e1d85361
|
@ -1185,6 +1185,7 @@ static const Town *CheckMultipleIndustryInTown(TileIndex tile, int type)
|
||||||
|
|
||||||
bool IsSlopeRefused(Slope current, Slope refused)
|
bool IsSlopeRefused(Slope current, Slope refused)
|
||||||
{
|
{
|
||||||
|
if (IsSteepSlope(current)) return true;
|
||||||
if (current != SLOPE_FLAT) {
|
if (current != SLOPE_FLAT) {
|
||||||
if (refused & SLOPE_STEEP) return true;
|
if (refused & SLOPE_STEEP) return true;
|
||||||
|
|
||||||
|
@ -1242,7 +1243,6 @@ static bool CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTileTable
|
||||||
if (IsClearWaterTile(cur_tile)) return false;
|
if (IsClearWaterTile(cur_tile)) return false;
|
||||||
|
|
||||||
tileh = GetTileSlope(cur_tile, NULL);
|
tileh = GetTileSlope(cur_tile, NULL);
|
||||||
if (IsSteepSlope(tileh)) return false;
|
|
||||||
|
|
||||||
refused_slope |= IsSlopeRefused(tileh, its->slopes_refused);
|
refused_slope |= IsSlopeRefused(tileh, its->slopes_refused);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue