summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2008-04-03 23:52:43 +0000
committersmatz <smatz@openttd.org>2008-04-03 23:52:43 +0000
commit673055d27f2ff9b8b6acde4fb389f1bf32eced4b (patch)
tree0eaf202a6527f99f6d33efecee66adac7de4bce6 /src
parentcc775d809c8e292fb44970d549cf22a36df11ab2 (diff)
downloadopenttd-673055d27f2ff9b8b6acde4fb389f1bf32eced4b.tar.xz
(svn r12556) -Fix (r6001): remove fences with fields when loading old savegames, looks better
Diffstat (limited to 'src')
-rw-r--r--src/openttd.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp
index 14a5f432d..1bc6ccad0 100644
--- a/src/openttd.cpp
+++ b/src/openttd.cpp
@@ -1963,7 +1963,12 @@ bool AfterLoadGame()
for (TileIndex t = 0; t < map_size; t++) {
if (IsTileType(t, MP_CLEAR) && IsClearGround(t, CLEAR_FIELDS)) {
+ /* remove fields */
MakeClear(t, CLEAR_GRASS, 3);
+ } else if (IsTileType(t, MP_CLEAR) || IsTileType(t, MP_TREES)) {
+ /* remove fences around fields */
+ SetFenceSE(t, 0);
+ SetFenceSW(t, 0);
}
}