(svn r3889) Change a part of the bridge drawing code to make it more comprehensible and add the needed accessors
This commit is contained in:
17
bridge_map.h
17
bridge_map.h
@@ -28,6 +28,23 @@ static inline DiagDirection GetBridgeRampDirection(TileIndex t)
|
||||
}
|
||||
|
||||
|
||||
static inline bool IsClearUnderBridge(TileIndex t)
|
||||
{
|
||||
return GB(_m[t].m5, 3, 3) == 0;
|
||||
}
|
||||
|
||||
|
||||
static inline bool IsTransportUnderBridge(TileIndex t)
|
||||
{
|
||||
return HASBIT(_m[t].m5, 5);
|
||||
}
|
||||
|
||||
static inline TransportType GetTransportTypeUnderBridge(TileIndex t)
|
||||
{
|
||||
return (TransportType)GB(_m[t].m5, 3, 2);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Starting at one bridge end finds the other bridge end
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user