diff options
author | zuu <zuu@openttd.org> | 2013-10-12 22:03:13 +0000 |
---|---|---|
committer | zuu <zuu@openttd.org> | 2013-10-12 22:03:13 +0000 |
commit | b35b8aa5bb38f9e47ca04ccd9302dd82546de0cd (patch) | |
tree | 071b2d96066a605c5bf65ede95945ea8738a2171 /src/tile_map.cpp | |
parent | d90889791826633d9f18301ead41a5d4bc77e215 (diff) | |
download | openttd-b35b8aa5bb38f9e47ca04ccd9302dd82546de0cd.tar.xz |
(svn r25848) -Codechange: Refactor check for if a tile is not an edge tile to new IsInnerTile method (cirdan, LordAro)
Diffstat (limited to 'src/tile_map.cpp')
-rw-r--r-- | src/tile_map.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/tile_map.cpp b/src/tile_map.cpp index 017bb5c56..86670c88a 100644 --- a/src/tile_map.cpp +++ b/src/tile_map.cpp @@ -22,11 +22,7 @@ Slope GetTileSlope(TileIndex tile, int *h) { assert(tile < MapSize()); - uint x = TileX(tile); - uint y = TileY(tile); - - if (x == MapMaxX() || y == MapMaxY() || - ((x == 0 || y == 0) && _settings_game.construction.freeform_edges)) { + if (!IsInnerTile(tile)) { if (h != NULL) *h = TileHeight(tile); return SLOPE_FLAT; } |