Changeset - r7549:c84f0cb9f86a
[Not reviewed]
master
0 2 0
rubidium - 17 years ago 2007-09-09 11:30:44
rubidium@openttd.org
(svn r11069) -Codechange: allow slopes under statues. Patch by kaan.
2 files changed with 7 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/town_cmd.cpp
Show inline comments
 
@@ -1928,7 +1928,8 @@ static bool DoBuildStatueOfCompany(TileI
 
	PlayerID old;
 
	CommandCost r;
 

	
 
	if (GetTileSlope(tile, NULL) != SLOPE_FLAT) return false;
 
	/* Statues can be build on slopes, just like houses. Only the steep slopes is a no go. */
 
	if (IsSteepSlope(GetTileSlope(tile, NULL))) return false;
 

	
 
	if (!IsTileType(tile, MP_HOUSE) &&
 
			!IsTileType(tile, MP_CLEAR) &&
src/unmovable_cmd.cpp
Show inline comments
 
@@ -110,6 +110,8 @@ CommandCost CmdBuildCompanyHQ(TileIndex 
 
	return cost;
 
}
 

	
 
static Foundation GetFoundation_Unmovable(TileIndex tile, Slope tileh);
 

	
 
static void DrawTile_Unmovable(TileInfo *ti)
 
{
 

	
 
@@ -132,6 +134,9 @@ static void DrawTile_Unmovable(TileInfo 
 
		}
 

	
 
		case UNMOVABLE_STATUE:
 
			/* This should prevent statues from sinking into the ground when on a slope. */
 
			if (ti->tileh != SLOPE_FLAT) DrawFoundation(ti, GetFoundation_Unmovable(ti->tile, ti->tileh));
 

	
 
			DrawGroundSprite(SPR_CONCRETE_GROUND, PAL_NONE);
 

	
 
			AddSortableSpriteToDraw(SPR_STATUE_COMPANY, PLAYER_SPRITE_COLOR(GetTileOwner(ti->tile)), ti->x, ti->y, 16, 16, 25, ti->z, HASBIT(_transparent_opt, TO_STRUCTURES));
0 comments (0 inline, 0 general)