summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/traps.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-07-27 13:32:04 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2009-07-27 13:32:04 +0000
commit33cd5f7627dde3804aba172a68b994def4de896d (patch)
tree7f658fb890a29d4f5c4ac3bc9693b4bd99d08c79 /crawl-ref/source/traps.cc
parentd80b2858a02272181c42f6efc027713820fc0f09 (diff)
downloadcrawl-ref-33cd5f7627dde3804aba172a68b994def4de896d.tar.gz
crawl-ref-33cd5f7627dde3804aba172a68b994def4de896d.zip
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
Diffstat (limited to 'crawl-ref/source/traps.cc')
-rw-r--r--crawl-ref/source/traps.cc7
1 files changed, 2 insertions, 5 deletions
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)
{