(svn r16938) -Codechange: introduce helper function to tell whether a tile is either a rail station or rail waypoint tile
This commit is contained in:
@@ -291,7 +291,7 @@ TileIndex GetNearbyTile(byte parameter, TileIndex tile)
|
||||
if (y >= 8) y -= 16;
|
||||
|
||||
/* Swap width and height depending on axis for railway stations */
|
||||
if (IsRailwayStationTile(tile) && GetRailStationAxis(tile) == AXIS_Y) Swap(x, y);
|
||||
if (HasStationTileRail(tile) && GetRailStationAxis(tile) == AXIS_Y) Swap(x, y);
|
||||
|
||||
/* Make sure we never roam outside of the map, better wrap in that case */
|
||||
return TILE_MASK(tile + TileDiffXY(x, y));
|
||||
|
Reference in New Issue
Block a user