diff options
author | smatz <smatz@openttd.org> | 2007-12-11 22:50:13 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2007-12-11 22:50:13 +0000 |
commit | cd580452341b6077e29bb7554d4f5e296a6ea901 (patch) | |
tree | f3b3fdf6faa33d44bc1c90d91254d883c0a364e3 /src/train_cmd.cpp | |
parent | ad022c535c438d8966db0c2f4949b5c5df9d7261 (diff) | |
download | openttd-cd580452341b6077e29bb7554d4f5e296a6ea901.tar.xz |
(svn r11623) -Fix [FS#1533] (r11619): assert when train is going over two crossings next to each other
Diffstat (limited to 'src/train_cmd.cpp')
-rw-r--r-- | src/train_cmd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/train_cmd.cpp b/src/train_cmd.cpp index 2e9f39bc3..6b71962a1 100644 --- a/src/train_cmd.cpp +++ b/src/train_cmd.cpp @@ -3242,7 +3242,7 @@ static bool TrainCheckIfLineEnds(Vehicle *v) if ((ts &= (ts >> 16)) == 0) { /* make a rail/road crossing red * do not make crossing red behind depot the train is entering */ - if (IsLevelCrossingTile(tile) && (GetRailTileType(v->tile) != RAIL_TILE_DEPOT || GetRailDepotDirection(v->tile) == dir)) { + if (IsLevelCrossingTile(tile) && (!IsTileDepotType(v->tile, TRANSPORT_RAIL) || GetRailDepotDirection(v->tile) == dir)) { if (!IsCrossingBarred(tile)) { BarCrossing(tile); SndPlayVehicleFx(SND_0E_LEVEL_CROSSING, v); |