diff options
author | Matthew Cline <zelgadis@sourceforge.net> | 2009-11-05 23:30:01 -0800 |
---|---|---|
committer | Matthew Cline <zelgadis@sourceforge.net> | 2009-11-05 23:37:28 -0800 |
commit | d3c2214dea8cb19bcaa4dfe1303f0368e8cdf4aa (patch) | |
tree | a12096e5191629b8a6cb335aebdb4652491d6771 /crawl-ref/source/mon-cast.h | |
parent | d6874ba95d47b886b55d0e65310c837206246223 (diff) | |
download | crawl-ref-d3c2214dea8cb19bcaa4dfe1303f0368e8cdf4aa.tar.gz crawl-ref-d3c2214dea8cb19bcaa4dfe1303f0368e8cdf4aa.zip |
Error for non-monster spells in monster specs
Give an error when parsing a monster spec if it lists a spell a monster
can't cast, rather than causing an assertion when the monster tries to
cast it.
Diffstat (limited to 'crawl-ref/source/mon-cast.h')
-rw-r--r-- | crawl-ref/source/mon-cast.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/crawl-ref/source/mon-cast.h b/crawl-ref/source/mon-cast.h index 5d10125d98..6d7d023abc 100644 --- a/crawl-ref/source/mon-cast.h +++ b/crawl-ref/source/mon-cast.h @@ -12,9 +12,13 @@ class monsters; class bolt; +void init_mons_spells(); +bool is_valid_mon_spell(spell_type spell); + bool handle_mon_spell(monsters *monster, bolt &beem); -bolt mons_spells(monsters *mons, spell_type spell_cast, int power); +bolt mons_spells(monsters *mons, spell_type spell_cast, int power, + bool check_validity = false); void mons_cast(monsters *monster, bolt &pbolt, spell_type spell_cast, bool do_noise = true); void mons_cast_noise(monsters *monster, bolt &pbolt, spell_type spell_cast); |