diff options
author | tron <tron@openttd.org> | 2005-10-13 14:44:03 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-10-13 14:44:03 +0000 |
commit | d37639ac3eab8c7d8deb37ff9b7784f57aa580d4 (patch) | |
tree | 872b9d779dd2e0fa0c30ae1a452a51c28faa298e | |
parent | 03e947cbfedd431bd21805b6348a9f9c945b0b1a (diff) | |
download | openttd-d37639ac3eab8c7d8deb37ff9b7784f57aa580d4.tar.xz |
(svn r3036) Use IsCompatibleRail() to check the rail type of level crossings (not a fix, because the old == method works so far)
-rw-r--r-- | train_cmd.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/train_cmd.c b/train_cmd.c index 43c67132c..d01bfb767 100644 --- a/train_cmd.c +++ b/train_cmd.c @@ -2465,8 +2465,10 @@ static bool CheckCompatibleRail(const Vehicle *v, TileIndex tile) case MP_STREET: // tracks over roads, do owner check of tracks return - IsTileOwner(tile, v->owner) && - (v->subtype != TS_Front_Engine || GB(_m[tile].m4, 0, 4) == v->u.rail.railtype); + IsTileOwner(tile, v->owner) && ( + v->subtype != TS_Front_Engine || + IsCompatibleRail(v->u.rail.railtype, GB(_m[tile].m4, 0, 4)) + ); default: return true; |