summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/ouch.cc
diff options
context:
space:
mode:
authordshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-05-10 16:38:57 +0000
committerdshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-05-10 16:38:57 +0000
commit90ac0755a3ded561037b612fa7adbf293887e050 (patch)
tree71bf12b204b207c8c6bc143851b040bbf9fb69c9 /crawl-ref/source/ouch.cc
parenta4ac31b1514c2eb7066379e79bfdd5985a7ddecb (diff)
downloadcrawl-ref-90ac0755a3ded561037b612fa7adbf293887e050.tar.gz
crawl-ref-90ac0755a3ded561037b612fa7adbf293887e050.zip
Level-files are now saved with subdungeon depths rather than absolute depths.
Breaks save compatibility resoundingly. The advantage of the change is that ghosts dying in a branch will always be reloaded at the same depth in the branch. Fixed minor bug that could result in branch stairs taking you to different places on successive visits. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1446 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/ouch.cc')
-rw-r--r--crawl-ref/source/ouch.cc13
1 files changed, 8 insertions, 5 deletions
diff --git a/crawl-ref/source/ouch.cc b/crawl-ref/source/ouch.cc
index 8e05aed8a8..fdac3faa45 100644
--- a/crawl-ref/source/ouch.cc
+++ b/crawl-ref/source/ouch.cc
@@ -845,17 +845,20 @@ void end_game( struct scorefile_entry &se )
{
if (tmp_file_pairs[level][dungeon])
{
- unlink(make_filename( you.your_name, level, dungeon,
- LEVEL_DUNGEON, false ).c_str());
+ unlink(
+ make_filename( you.your_name, level,
+ static_cast<branch_type>(dungeon),
+ LEVEL_DUNGEON, false ).c_str() );
}
}
}
// temp levels, if any
- unlink( make_filename( you.your_name, 0, 0, LEVEL_ABYSS, false ).c_str() );
- unlink( make_filename( you.your_name, 0, 0,
+ unlink( make_filename( you.your_name, 0, BRANCH_MAIN_DUNGEON,
+ LEVEL_ABYSS, false ).c_str() );
+ unlink( make_filename( you.your_name, 0, BRANCH_MAIN_DUNGEON,
LEVEL_PANDEMONIUM, false ).c_str() );
- unlink( make_filename( you.your_name, 0, 0,
+ unlink( make_filename( you.your_name, 0, BRANCH_MAIN_DUNGEON,
LEVEL_LABYRINTH, false ).c_str() );
// create base file name