From 6f40e4499e2e8057d7ff2476faec45d186daadfe Mon Sep 17 00:00:00 2001 From: Darshan Shaligram Date: Wed, 30 Dec 2009 08:24:00 +0530 Subject: Remove shoal decoy huts. The rune huts are now also used as decoys, with the rune replaced by | --- crawl-ref/source/dungeon.cc | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'crawl-ref/source/dungeon.cc') diff --git a/crawl-ref/source/dungeon.cc b/crawl-ref/source/dungeon.cc index 93e5086ef6..5cae7491fe 100644 --- a/crawl-ref/source/dungeon.cc +++ b/crawl-ref/source/dungeon.cc @@ -4085,8 +4085,11 @@ void _fixup_after_vault() // clobber: If true, assumes the newly placed vault can clobber existing // items and monsters (items may be destroyed, monsters may be // teleported). -bool dgn_place_map(const map_def *mdef, bool clobber, bool make_no_exits, - const coord_def &where) +bool dgn_place_map(const map_def *mdef, + bool clobber, + bool make_no_exits, + const coord_def &where, + int rune_subst) { const dgn_colour_override_manager colour_man; @@ -4114,8 +4117,7 @@ bool dgn_place_map(const map_def *mdef, bool clobber, bool make_no_exits, } } - int rune_subst = -1; - if (mdef->has_tag_suffix("_entry")) + if (rune_subst == -1 && mdef->has_tag_suffix("_entry")) rune_subst = _dgn_find_rune_subst_tags(mdef->tags); did_map = _build_secondary_vault(you.your_level, mdef, rune_subst, clobber, make_no_exits, where); @@ -4938,6 +4940,11 @@ static void _vault_grid(vault_placement &place, int which_depth; int spec = 250; + // If rune_subst is set to 0, the rune was already placed, + // take appropriate steps. + if (place.rune_subst == 0 && vgrid == 'O') + place.num_runes++; + if (vgrid == '$') { which_class = OBJ_GOLD; -- cgit v1.2.3-54-g00ecf