(svn r2887) Fix regression: Two boolean expressions got flipped in r2595, which made it possible to place lighthouses and antennas everywhere BUT clear tiles (found and fixed by _Luca_)
authortron
Wed, 24 Aug 2005 18:47:26 +0000
changeset 2361 0c7f1f8032a0
parent 2360 09e42e4ee139
child 2362 c84208584a41
(svn r2887) Fix regression: Two boolean expressions got flipped in r2595, which made it possible to place lighthouses and antennas everywhere BUT clear tiles (found and fixed by _Luca_)
main_gui.c
--- a/main_gui.c	Tue Aug 23 18:47:04 2005 +0000
+++ b/main_gui.c	Wed Aug 24 18:47:26 2005 +0000
@@ -1219,7 +1219,7 @@
 	TileInfo ti;
 
 	FindLandscapeHeightByTile(&ti, tile);
-	if (IsTileType(tile, MP_CLEAR) || IsSteepTileh(ti.tileh))
+	if (!IsTileType(tile, MP_CLEAR) || IsSteepTileh(ti.tileh))
 		return;
 
 	ModifyTile(tile, MP_SETTYPE(MP_UNMOVABLE) | MP_MAP5, 1);
@@ -1231,7 +1231,7 @@
 	TileInfo ti;
 
 	FindLandscapeHeightByTile(&ti, tile);
-	if (IsTileType(tile, MP_CLEAR) || IsSteepTileh(ti.tileh))
+	if (!IsTileType(tile, MP_CLEAR) || IsSteepTileh(ti.tileh))
 		return;
 
 	ModifyTile(tile, MP_SETTYPE(MP_UNMOVABLE) | MP_MAP5, 0);