diff options
author | rubidium <rubidium@openttd.org> | 2008-11-07 17:59:51 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-11-07 17:59:51 +0000 |
commit | c7f3935506b584415ea249ab01f4d2c8f70c08cc (patch) | |
tree | c380e6faa058315b7e8b64e8999b7750c233e297 /src/rail_map.h | |
parent | e91ae97e19634917cd9b866e1cab397970f33045 (diff) | |
download | openttd-c7f3935506b584415ea249ab01f4d2c8f70c08cc.tar.xz |
(svn r14566) -Fix [FS#2397]: RV's go via order would reserve a slot at the 'via' station which it never uses, which makes it unlikely that it reserves a slot for the next station and that makes queueing fail (Aali)
Diffstat (limited to 'src/rail_map.h')
-rw-r--r-- | src/rail_map.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/rail_map.h b/src/rail_map.h index a6077cf0d..cf4e6e861 100644 --- a/src/rail_map.h +++ b/src/rail_map.h @@ -598,6 +598,15 @@ static inline bool IsSnowRailGround(TileIndex t) return GetRailGroundType(t) == RAIL_GROUND_ICE_DESERT; } +static inline void UpdateStat(TileIndex t, bool on_track) +{ + _me[t].m7 = _me[t].m7 << 1 | !!on_track; +} + +static inline byte GetStat(TileIndex t) +{ + return _me[t].m7; +} static inline void MakeRailNormal(TileIndex t, Owner o, TrackBits b, RailType r) { |