mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-01-30 10:54:40 +00:00
(svn r4214) -Fix: Do not try to obtain Trackbits for normal rails, bus stops, airports and other non-rail tiles
This commit is contained in:
parent
736983a06d
commit
1f88ea4ec6
2
elrail.c
2
elrail.c
@ -101,9 +101,11 @@ static TrackBits GetRailTrackBitsUniversal(TileIndex t, byte *override)
|
||||
}
|
||||
}
|
||||
case MP_STREET:
|
||||
if (!GetRoadType(t) == ROAD_CROSSING) return 0;
|
||||
if (GetRailTypeCrossing(t) != RAILTYPE_ELECTRIC) return 0;
|
||||
return GetCrossingRailBits(t);
|
||||
case MP_STATION:
|
||||
if (!IsRailwayStation(t)) return 0;
|
||||
if (GetRailType(t) != RAILTYPE_ELECTRIC) return 0;
|
||||
return TrackToTrackBits(GetRailStationTrack(t));
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user