(svn r23096) -Codechange: remove useless divisions and multiplications by TILE_HEIGHT for the snow line code

This commit is contained in:
rubidium
2011-11-04 10:25:58 +00:00
parent b167c0a396
commit 69162621d8
11 changed files with 33 additions and 32 deletions

View File

@@ -380,8 +380,8 @@ public:
uint cargo_needed_for_growth = 0;
switch (_settings_game.game_creation.landscape) {
case LT_ARCTIC:
if (TilePixelHeight(this->town->xy) >= LowestSnowLine()) cargo_needed_for_growth = 1;
if (TilePixelHeight(this->town->xy) < GetSnowLine()) required_text = STR_TOWN_VIEW_CARGO_FOR_TOWNGROWTH_REQUIRED_WINTER;
if (TileHeight(this->town->xy) >= LowestSnowLine()) cargo_needed_for_growth = 1;
if (TileHeight(this->town->xy) < GetSnowLine()) required_text = STR_TOWN_VIEW_CARGO_FOR_TOWNGROWTH_REQUIRED_WINTER;
break;
case LT_TROPIC:
@@ -493,7 +493,7 @@ public:
switch (_settings_game.game_creation.landscape) {
case LT_ARCTIC:
if (TilePixelHeight(this->town->xy) >= LowestSnowLine()) aimed_height += 2 * FONT_HEIGHT_NORMAL;
if (TileHeight(this->town->xy) >= LowestSnowLine()) aimed_height += 2 * FONT_HEIGHT_NORMAL;
break;
case LT_TROPIC: