summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-04-07 09:40:18 +0000
committerdshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-04-07 09:40:18 +0000
commit14c66301ea2ed5a18dbcf15c314781acd5d9e985 (patch)
tree1c1f98ecef3a9039413fe50e41918da303ece829
parent0465fe0800f27cb9df0f7dd32f3decb3b20f9edb (diff)
downloadcrawl-ref-14c66301ea2ed5a18dbcf15c314781acd5d9e985.tar.gz
crawl-ref-14c66301ea2ed5a18dbcf15c314781acd5d9e985.zip
Added save backward compatibility shim for cloud fix.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1251 c06c8d41-db1a-0410-9941-cceddc491573
-rw-r--r--crawl-ref/source/files.cc2
-rw-r--r--crawl-ref/source/tags.cc4
2 files changed, 5 insertions, 1 deletions
diff --git a/crawl-ref/source/files.cc b/crawl-ref/source/files.cc
index df241e835c..07b4676347 100644
--- a/crawl-ref/source/files.cc
+++ b/crawl-ref/source/files.cc
@@ -89,7 +89,7 @@
void save_level(int level_saved, bool was_a_labyrinth, char where_were_you);
#define GHOST_MINOR_VERSION 1
-#define LEVEL_MINOR_VERSION 1
+#define LEVEL_MINOR_VERSION 2
#define YOU_MINOR_VERSION 1
static void redraw_all(void)
diff --git a/crawl-ref/source/tags.cc b/crawl-ref/source/tags.cc
index b7d6d79fd5..68fa56440e 100644
--- a/crawl-ref/source/tags.cc
+++ b/crawl-ref/source/tags.cc
@@ -1530,6 +1530,10 @@ static void tag_read_level( struct tagHeader &th, char minorVersion )
mgrd[i][j] = NON_MONSTER;
env.cgrid[i][j] = (unsigned char) unmarshallByte(th);
+
+ // Ugh! Backward compatibility. 101 was the old (buggy) EMPTY_CLOUD
+ if (minorVersion < 2 && env.cgrid[i][j] == 101)
+ env.cgrid[i][j] = EMPTY_CLOUD;
}
}