From 78a45dd9099c4340a9aec9d634d3ef91bab181ac Mon Sep 17 00:00:00 2001 From: haranp Date: Mon, 16 Feb 2009 13:14:09 +0000 Subject: Fix [2004960]: clean up sanctuary logic. Monsters will now stop fleeing and attack you if you step outside of sanctuary; also, they can acquire and chase new targets while still respecting sanctuary. Hopefully non-buggy. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9100 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/mon-util.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'crawl-ref/source/mon-util.h') diff --git a/crawl-ref/source/mon-util.h b/crawl-ref/source/mon-util.h index 1cbf54ed89..ab343e73df 100644 --- a/crawl-ref/source/mon-util.h +++ b/crawl-ref/source/mon-util.h @@ -161,7 +161,6 @@ enum mon_event_type ME_ANNOY, // annoy at range ME_ALERT, // alert to presence ME_WHACK, // physical attack - ME_SHOT, // attack at range ME_SCARE, // frighten monster ME_CORNERED // cannot flee }; @@ -767,6 +766,8 @@ bool mons_is_panicking(const monsters *m); bool mons_is_cornered(const monsters *m); bool mons_is_lurking(const monsters *m); bool mons_is_batty(const monsters *m); +bool mons_is_influenced_by_sanctuary(const monsters *m); +bool mons_is_fleeing_sanctuary(const monsters *m); bool mons_was_seen(const monsters *m); bool mons_is_known_mimic(const monsters *m); bool mons_is_holy(const monsters *mon); @@ -783,6 +784,9 @@ monster_type mons_species(int mc); bool mons_looks_stabbable(const monsters *m); bool mons_looks_distracted(const monsters *m); +void mons_start_fleeing_from_sanctuary(monsters *monster); +void mons_stop_fleeing_from_sanctuary(monsters *monster); + bool mons_has_smite_attack(const monsters *monster); bool check_mons_resist_magic(const monsters *monster, int pow); -- cgit v1.2.3-54-g00ecf