diff options
author | Shmuale Mark <shm.mark@gmail.com> | 2014-08-03 11:58:23 -0400 |
---|---|---|
committer | Shmuale Mark <shm.mark@gmail.com> | 2014-08-03 14:16:52 -0400 |
commit | 7f77ec55743fce0d895242aab00b26976c8e9d3c (patch) | |
tree | 2e4fa068a11847bf54adeefffc1f32bc52d41d31 /crawl-ref/source/dgn-overview.cc | |
parent | d1e2701b5e277586b071030a45d86318c23e590d (diff) | |
download | crawl-ref-7f77ec55743fce0d895242aab00b26976c8e9d3c.tar.gz crawl-ref-7f77ec55743fce0d895242aab00b26976c8e9d3c.zip |
Properly hide conflicting branches on ctrl-O.
Also cleans up some old Forest code, which might make ^O look a bit
weird on imported saves; probably not a big problem.
Diffstat (limited to 'crawl-ref/source/dgn-overview.cc')
-rw-r--r-- | crawl-ref/source/dgn-overview.cc | 31 |
1 files changed, 4 insertions, 27 deletions
diff --git a/crawl-ref/source/dgn-overview.cc b/crawl-ref/source/dgn-overview.cc index faecab20e0..e755db7bb5 100644 --- a/crawl-ref/source/dgn-overview.cc +++ b/crawl-ref/source/dgn-overview.cc @@ -302,9 +302,6 @@ static string _get_unseen_branches() char buffer[100]; string disp; - /* see if we need to hide lair branches that don't exist */ - int seen_lair_branches = 0; - int seen_vaults_branches = 0; for (branch_iterator it; it; ++it) { if (it->id < BRANCH_FIRST_NON_DUNGEON) @@ -312,30 +309,10 @@ static string _get_unseen_branches() const branch_type branch = it->id; - if (!is_random_subbranch(branch)) - continue; - - if (stair_level.count(branch)) - { - if (parent_branch(branch) == BRANCH_LAIR) - seen_lair_branches++; - else if (parent_branch(branch) == BRANCH_VAULTS) - seen_vaults_branches++; - } - } - - for (branch_iterator it; it; ++it) - { - if (it->id < BRANCH_FIRST_NON_DUNGEON) - continue; - - const branch_type branch = it->id; - - if (is_random_subbranch(branch) - && ((parent_branch(branch) == BRANCH_LAIR - && seen_lair_branches >= 2) - || (parent_branch(branch) == BRANCH_VAULTS) - && seen_vaults_branches >= 1)) + if (branch == BRANCH_SPIDER && stair_level.count(BRANCH_SNAKE) + || branch == BRANCH_SNAKE && stair_level.count(BRANCH_SPIDER) + || branch == BRANCH_SWAMP && stair_level.count(BRANCH_SHOALS) + || branch == BRANCH_SHOALS && stair_level.count(BRANCH_SWAMP)) { continue; } |