diff options
author | tron <tron@openttd.org> | 2005-02-07 10:41:45 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-02-07 10:41:45 +0000 |
commit | f8d97a5f616c5e303b2822316fcef409baee6195 (patch) | |
tree | 6fb9696d4610ea19244f194d0c47fa748af72fd4 /industry_cmd.c | |
parent | ad837c2069d37ad36dfba07f62bd35a6694dd266 (diff) | |
download | openttd-f8d97a5f616c5e303b2822316fcef409baee6195.tar.xz |
(svn r1839) Move GetTileSlope() and GetTileZ() into tile.[ch] and use more explicit types as parameters
Diffstat (limited to 'industry_cmd.c')
-rw-r--r-- | industry_cmd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/industry_cmd.c b/industry_cmd.c index f0acc8310..961f44499 100644 --- a/industry_cmd.c +++ b/industry_cmd.c @@ -959,7 +959,7 @@ static void PlantFarmField(uint tile) int type, type2; if (_opt.landscape == LT_HILLY) { - if (GetTileZ(tile) >= (_opt.snow_line - 16)) + if (GetTileZ(tile) + 16 >= _opt.snow_line) return; } @@ -1169,7 +1169,7 @@ static bool CheckNewIndustry_NULL(uint tile, int type) static bool CheckNewIndustry_Forest(uint tile, int type) { if (_opt.landscape == LT_HILLY) { - if (GetTileZ(tile) < (_opt.snow_line + 16) ) { + if (GetTileZ(tile) < _opt.snow_line + 16U) { _error_message = STR_4831_FOREST_CAN_ONLY_BE_PLANTED; return false; } @@ -1202,7 +1202,7 @@ static bool CheckNewIndustry_Oilwell(uint tile, int type) static bool CheckNewIndustry_Farm(uint tile, int type) { if (_opt.landscape == LT_HILLY) { - if (GetTileZ(tile) >= (_opt.snow_line - 16)) { + if (GetTileZ(tile) + 16 >= _opt.snow_line) { _error_message = STR_0239_SITE_UNSUITABLE; return false; } |