Changeset - r16038:9c4e6a0b8700
[Not reviewed]
master
0 4 0
frosch - 14 years ago 2010-09-05 13:18:54
frosch@openttd.org
(svn r20741) -Cleanup: Use IsTileOnWater() in more places.
4 files changed with 4 insertions and 4 deletions:
0 comments (0 inline, 0 general)
src/newgrf_airporttiles.cpp
Show inline comments
 
@@ -270,7 +270,7 @@ static void AirportDrawTileLayout(const 
 
	SpriteID pal   = dts->ground.pal;
 

	
 
	if (GB(image, 0, SPRITE_WIDTH) != 0) {
 
		if (image == SPR_FLAT_WATER_TILE && GetWaterClass(ti->tile) != WATER_CLASS_INVALID) {
 
		if (image == SPR_FLAT_WATER_TILE && IsTileOnWater(ti->tile)) {
 
			DrawWaterClassGround(ti);
 
		} else {
 
			DrawGroundSprite(image, GroundSpritePaletteTransform(image, pal, GENERAL_SPRITE_COLOUR(colour)));
src/smallmap_gui.cpp
Show inline comments
 
@@ -401,7 +401,7 @@ static inline uint32 GetSmallMapIndustri
 
			return GetIndustrySpec(Industry::GetByTile(tile)->type)->map_colour * 0x01010101;
 
		} else {
 
			/* Otherwise, return the colour which will make it disappear */
 
			t = (GetWaterClass(tile) == WATER_CLASS_INVALID) ? MP_CLEAR : MP_WATER;
 
			t = (IsTileOnWater(tile) ? MP_WATER : MP_CLEAR);
 
		}
 
	}
 

	
src/station_cmd.cpp
Show inline comments
 
@@ -2663,7 +2663,7 @@ static void DrawTile_Station(TileInfo *t
 
		}
 
	}
 

	
 
	if (IsBuoy(ti->tile) || IsDock(ti->tile) || (IsOilRig(ti->tile) && GetWaterClass(ti->tile) != WATER_CLASS_INVALID)) {
 
	if (IsBuoy(ti->tile) || IsDock(ti->tile) || (IsOilRig(ti->tile) && IsTileOnWater(ti->tile))) {
 
		if (ti->tileh == SLOPE_FLAT) {
 
			DrawWaterClassGround(ti);
 
		} else {
src/water_cmd.cpp
Show inline comments
 
@@ -485,7 +485,7 @@ static bool IsWateredTile(TileIndex tile
 
				if ((IsTileType(src_tile, MP_STATION) && IsOilRig(src_tile)) ||
 
				    (IsTileType(src_tile, MP_INDUSTRY))) return true;
 

	
 
				return GetWaterClass(tile) != WATER_CLASS_INVALID;
 
				return IsTileOnWater(tile);
 
			}
 
			return (IsDock(tile) && GetTileSlope(tile, NULL) == SLOPE_FLAT) || IsBuoy(tile);
 

	
0 comments (0 inline, 0 general)