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 | 93f003919f2c99a74b529eefd56fa13dfea5c975 (patch) | |
tree | 872b9d779dd2e0fa0c30ae1a452a51c28faa298e /train_cmd.c | |
parent | 2f6f8215acc14ae29c19b952e492ce269f0786a1 (diff) | |
download | openttd-93f003919f2c99a74b529eefd56fa13dfea5c975.tar.xz |
(svn r3036) Use IsCompatibleRail() to check the rail type of level crossings (not a fix, because the old == method works so far)
Diffstat (limited to 'train_cmd.c')
-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; |