summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortron <tron@openttd.org>2005-04-24 07:56:18 +0000
committertron <tron@openttd.org>2005-04-24 07:56:18 +0000
commit566df8dc655995fba246fc4373bb8fc5e7ddd6bb (patch)
tree1921eef5050a755b36ca4b35b1d4623fca503bca
parent6ceeedfd3c32228a54cce9c65ca7994d14e6c909 (diff)
downloadopenttd-566df8dc655995fba246fc4373bb8fc5e7ddd6bb.tar.xz
(svn r2223) When adding tracks to a railway tile reset the ground to bare land, fix for a glitch in r2131
-rw-r--r--rail_cmd.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/rail_cmd.c b/rail_cmd.c
index b7724d553..40498cb68 100644
--- a/rail_cmd.c
+++ b/rail_cmd.c
@@ -343,7 +343,10 @@ int32 CmdBuildSingleRail(int x, int y, uint32 flags,
if (CmdFailed(ret)) return ret;
cost += ret;
- if (flags & DC_EXEC) _map5[tile] = m5 | rail_bit;
+ if (flags & DC_EXEC) {
+ _map2[tile] &= ~RAIL_MAP2LO_GROUND_MASK; // Bare land
+ _map5[tile] = m5 | rail_bit;
+ }
break;
case MP_STREET: