diff options
author | dP <dp@dpointer.org> | 2020-07-12 16:38:35 +0300 |
---|---|---|
committer | Niels Martin Hansen <nielsm@indvikleren.dk> | 2020-07-13 16:38:21 +0200 |
commit | 706c47265e3abf88341be8376532133bde582828 (patch) | |
tree | 3305d69b9ae9ced78c3629c9e951ecf3dd9ed155 | |
parent | 954d0b4e5b1261468ce0c1f64d3c885e1405fc1f (diff) | |
download | openttd-706c47265e3abf88341be8376532133bde582828.tar.xz |
Fix: Set invalid road and tram types for rail tunnel ends
-rw-r--r-- | src/tunnel_map.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/tunnel_map.h b/src/tunnel_map.h index 0fdfcecae..c347626d5 100644 --- a/src/tunnel_map.h +++ b/src/tunnel_map.h @@ -10,6 +10,7 @@ #ifndef TUNNEL_MAP_H #define TUNNEL_MAP_H +#include "rail_map.h" #include "road_map.h" @@ -79,7 +80,9 @@ static inline void MakeRailTunnel(TileIndex t, Owner o, DiagDirection d, RailTyp _m[t].m5 = TRANSPORT_RAIL << 2 | d; SB(_me[t].m6, 2, 4, 0); _me[t].m7 = 0; - _me[t].m8 = r; + _me[t].m8 = 0; + SetRailType(t, r); + SetRoadTypes(t, INVALID_ROADTYPE, INVALID_ROADTYPE); } #endif /* TUNNEL_MAP_H */ |