1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-30 18:09:09 +00:00

(svn r3012) Extract the correct bits when checking if it's a road or rail tunnel; this is not flagged as fix, because it accidently worked

This commit is contained in:
tron
2005-10-04 06:34:39 +00:00
parent 01559c99b1
commit 8bd4a63c47

View File

@@ -708,7 +708,7 @@ start_at:
(uint)(_m[tile].m5 & 3) != (direction ^ 2)) {
/* This is a tunnel tile */
/* We are not just driving out of the tunnel */
if ( (uint)(_m[tile].m5 & 3) != direction || ((_m[tile].m5>>1)&6) != tpf->tracktype)
if ( (uint)(_m[tile].m5 & 3) != direction || GB(_m[tile].m5, 2, 2) != tpf->tracktype)
/* We are not driving into the tunnel, or it
* is an invalid tunnel */
continue;