summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/dungeon.cc
diff options
context:
space:
mode:
authorMatthew Cline <zelgadis@sourceforge.net>2009-12-05 00:51:57 -0800
committerMatthew Cline <zelgadis@sourceforge.net>2009-12-05 00:53:46 -0800
commit8069f7106f92be1e447c830c92ab1628701ab782 (patch)
tree2caa2bb7f02536e9869538534c0ea3731c50c5d2 /crawl-ref/source/dungeon.cc
parentaa95d78c68b44e943944ae64c24b346b16fbe881 (diff)
downloadcrawl-ref-8069f7106f92be1e447c830c92ab1628701ab782.tar.gz
crawl-ref-8069f7106f92be1e447c830c92ab1628701ab782.zip
Do "post_activate_remove" in dgn_place_map()
Fixes MonPropsMarkers not being removed-on-activation when a vault is placed via &L.
Diffstat (limited to 'crawl-ref/source/dungeon.cc')
-rw-r--r--crawl-ref/source/dungeon.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/crawl-ref/source/dungeon.cc b/crawl-ref/source/dungeon.cc
index 39f599bb2e..d8372805a9 100644
--- a/crawl-ref/source/dungeon.cc
+++ b/crawl-ref/source/dungeon.cc
@@ -4435,8 +4435,15 @@ bool dgn_place_map(const map_def *mdef, bool clobber, bool make_no_exits,
{
std::vector<map_marker *> markers =
env.markers.get_markers_at(coord_def(x, y));
+ std::vector<map_marker*> to_remove;
for (int i = 0, size = markers.size(); i < size; ++i)
+ {
markers[i]->activate();
+ if (markers[i]->property("post_activate_remove") != "")
+ to_remove.push_back(markers[i]);
+ }
+ for (unsigned int i = 0; i < to_remove.size(); i++)
+ env.markers.remove(to_remove[i]);
if (!you.see_cell(coord_def(x, y)))
set_terrain_changed(x, y);