summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/monplace.h
diff options
context:
space:
mode:
authordolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-14 18:03:45 +0000
committerdolorous <dolorous@c06c8d41-db1a-0410-9941-cceddc491573>2008-06-14 18:03:45 +0000
commit866686d5df24c38a2838f6f06ef9186b2c392a1c (patch)
tree979cbc53f2f8f4f7cc278facf0fbf3086e506c29 /crawl-ref/source/monplace.h
parent661eef8d4e4e4c19309a45aa154b5a2349371435 (diff)
downloadcrawl-ref-866686d5df24c38a2838f6f06ef9186b2c392a1c.tar.gz
crawl-ref-866686d5df24c38a2838f6f06ef9186b2c392a1c.zip
Add more god gift-related fixes. First, expand mgen_data::hostile_at()
to allow specifying more parameters, and merge it with mgen_data::alert_hostile_at(), since their only difference after expansion is the hostile monster's target. Second, if a god makes you cast Fire Storm, any fire vortices produced will finally be marked as god gifts. Third, for consistency, don't immediately alert miscast-produced spatial vortices to your presence, since the aforementioned fire vortices aren't. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5818 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/monplace.h')
-rw-r--r--crawl-ref/source/monplace.h20
1 files changed, 8 insertions, 12 deletions
diff --git a/crawl-ref/source/monplace.h b/crawl-ref/source/monplace.h
index f0898245a2..bbba9f3c3f 100644
--- a/crawl-ref/source/monplace.h
+++ b/crawl-ref/source/monplace.h
@@ -216,19 +216,15 @@ struct mgen_data
}
static mgen_data hostile_at(monster_type what,
- const coord_def &where)
- {
- return mgen_data(what, BEH_HOSTILE, 0, where);
- }
-
- static mgen_data alert_hostile_at(monster_type what,
- const coord_def &where,
- int abj_deg = 0,
- unsigned flags = 0,
- god_type god = GOD_NO_GOD)
+ const coord_def &where,
+ int abj_deg = 0,
+ unsigned flags = 0,
+ bool alert = false,
+ god_type god = GOD_NO_GOD)
{
- return mgen_data(what, BEH_HOSTILE, abj_deg, where, MHITYOU, flags,
- god);
+ return mgen_data(what, BEH_HOSTILE, abj_deg, where,
+ alert ? MHITYOU : MHITNOT,
+ flags, god);
}
};