summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/goditem.cc
diff options
context:
space:
mode:
authorDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-11-09 23:59:39 -0600
committerDavid Lawrence Ramsey <dolorous@users.sourceforge.net>2009-11-09 23:59:39 -0600
commit5d7a50baaa1a688660fed5da400ff1ebd5c81049 (patch)
tree0779feeed704112196221ba57ef3c9edc28d85e6 /crawl-ref/source/goditem.cc
parente79ba3e8f21761993dfce92a4d8753dbc8503809 (diff)
downloadcrawl-ref-5d7a50baaa1a688660fed5da400ff1ebd5c81049.tar.gz
crawl-ref-5d7a50baaa1a688660fed5da400ff1ebd5c81049.zip
Add spell flag SPFLAG_HASTY, and mark hasty spells with it.
Diffstat (limited to 'crawl-ref/source/goditem.cc')
-rw-r--r--crawl-ref/source/goditem.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/crawl-ref/source/goditem.cc b/crawl-ref/source/goditem.cc
index 5b31e5efd8..742236b286 100644
--- a/crawl-ref/source/goditem.cc
+++ b/crawl-ref/source/goditem.cc
@@ -277,10 +277,9 @@ bool is_hasty_spell(spell_type spell, god_type god)
{
UNUSED(god);
- return (spell == SPELL_HASTE
- || spell == SPELL_SWIFTNESS
- || spell == SPELL_BERSERKER_RAGE
- || spell == SPELL_HASTE_OTHER);
+ unsigned int flags = get_spell_flags(spell);
+
+ return (flags & SPFLAG_HASTY);
}
// The default suitable() function for is_spellbook_type().