summaryrefslogtreecommitdiff
path: root/src/road_map.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/road_map.cpp')
-rw-r--r--src/road_map.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/road_map.cpp b/src/road_map.cpp
index 7dc26f079..0bdf66dfe 100644
--- a/src/road_map.cpp
+++ b/src/road_map.cpp
@@ -12,6 +12,7 @@
#include "tunnel_map.h"
#include "station_map.h"
#include "depot.h"
+#include "tunnelbridge_map.h"
RoadBits GetAnyRoadBits(TileIndex tile, RoadType rt)
@@ -34,11 +35,11 @@ RoadBits GetAnyRoadBits(TileIndex tile, RoadType rt)
case MP_TUNNELBRIDGE:
if (IsTunnel(tile)) {
- if (GetTunnelTransportType(tile) != TRANSPORT_ROAD) return ROAD_NONE;
- return DiagDirToRoadBits(ReverseDiagDir(GetTunnelDirection(tile)));
+ if (GetTunnelBridgeTransportType(tile) != TRANSPORT_ROAD) return ROAD_NONE;
+ return DiagDirToRoadBits(ReverseDiagDir(GetTunnelBridgeDirection(tile)));
} else {
- if (GetBridgeTransportType(tile) != TRANSPORT_ROAD) return ROAD_NONE;
- return DiagDirToRoadBits(ReverseDiagDir(GetBridgeRampDirection(tile)));
+ if (GetTunnelBridgeTransportType(tile) != TRANSPORT_ROAD) return ROAD_NONE;
+ return DiagDirToRoadBits(ReverseDiagDir(GetTunnelBridgeDirection(tile)));
}
default: return ROAD_NONE;