(svn r16349) -Codechange: rename IsPlainRailTile() to IsPlainRail(), introduce shiny new IsPlainRailTile()

This commit is contained in:
smatz
2009-05-18 01:26:23 +00:00
parent bad5d6d6a2
commit 05db91dc65
13 changed files with 51 additions and 41 deletions

View File

@@ -42,12 +42,23 @@ static inline RailTileType GetRailTileType(TileIndex t)
* @pre IsTileType(t, MP_RAILWAY)
* @return true if and only if the tile is normal rail (with or without signals)
*/
static inline bool IsPlainRailTile(TileIndex t)
static inline bool IsPlainRail(TileIndex t)
{
RailTileType rtt = GetRailTileType(t);
return rtt == RAIL_TILE_NORMAL || rtt == RAIL_TILE_SIGNALS;
}
/**
* Checks whether the tile is a rail tile or rail tile with signals.
* @param t the tile to get the information from
* @return true if and only if the tile is normal rail (with or without signals)
*/
static inline bool IsPlainRailTile(TileIndex t)
{
return IsTileType(t, MP_RAILWAY) && IsPlainRail(t);
}
/**
* Checks if a rail tile has signals.
* @param t the tile to get the information from