From 33cd5f7627dde3804aba172a68b994def4de896d Mon Sep 17 00:00:00 2001 From: j-p-e-g Date: Mon, 27 Jul 2009 13:32:04 +0000 Subject: Disallow vaults placing shaft traps if shafts are disallowed on that level. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@10427 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/traps.cc | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'crawl-ref/source/traps.cc') diff --git a/crawl-ref/source/traps.cc b/crawl-ref/source/traps.cc index a46995b4d6..5aff02caec 100644 --- a/crawl-ref/source/traps.cc +++ b/crawl-ref/source/traps.cc @@ -1273,11 +1273,8 @@ bool is_valid_shaft_level(const level_id &place) return (false); // Disallow shafts on the first two levels. - if (place == BRANCH_MAIN_DUNGEON - && you.your_level < 2) - { + if (place == BRANCH_MAIN_DUNGEON && you.your_level < 2) return (false); - } // Don't generate shafts in branches where teleport control // is prevented. Prevents player from going down levels without @@ -1330,7 +1327,7 @@ level_id generic_shaft_dest(level_pos lpos) // be created during level generation time. // Include level 27 of the main dungeon here, but don't restrict // shaft creation (so don't set branch.dangerous_bottom_level). - if ((branch.dangerous_bottom_level) + if (branch.dangerous_bottom_level && lid.depth == branch.depth && (branch.depth - curr_depth) > 1) { -- cgit v1.2.3-54-g00ecf