diff options
author | Vsevolod Kozlov <zaba@thorium.homeunix.org> | 2009-11-09 14:33:06 +0300 |
---|---|---|
committer | Vsevolod Kozlov <zaba@thorium.homeunix.org> | 2009-11-09 14:58:19 +0300 |
commit | 9338556ebf846bbc4176134e3846ef6699e8434b (patch) | |
tree | 2107949166730a765e3e1e98a66778f112fb5e6a /crawl-ref/source/monstuff.cc | |
parent | bf03515e22d610f81afa6d4153afc383f7331363 (diff) | |
download | crawl-ref-9338556ebf846bbc4176134e3846ef6699e8434b.tar.gz crawl-ref-9338556ebf846bbc4176134e3846ef6699e8434b.zip |
Replace mons_wont_attack with monsters::wont_attack.
Diffstat (limited to 'crawl-ref/source/monstuff.cc')
-rw-r--r-- | crawl-ref/source/monstuff.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/crawl-ref/source/monstuff.cc b/crawl-ref/source/monstuff.cc index 563e6aec1b..e9e42685a3 100644 --- a/crawl-ref/source/monstuff.cc +++ b/crawl-ref/source/monstuff.cc @@ -1998,7 +1998,7 @@ int monster_die(monsters *monster, killer_type killer, // Make sure Boris has a foe to address. if (monster->foe == MHITNOT) { - if (!mons_wont_attack(monster) && !crawl_state.arena) + if (!monster->wont_attack() && !crawl_state.arena) monster->foe = MHITYOU; else if (!invalid_monster_index(killer_index)) monster->foe = killer_index; @@ -2525,7 +2525,7 @@ static coord_def _random_monster_nearby_habitable_space(const monsters& mon, bool allow_adjacent, bool respect_los) { - const bool respect_sanctuary = mons_wont_attack(&mon); + const bool respect_sanctuary = mon.wont_attack(); coord_def target; int tries; @@ -3017,7 +3017,7 @@ bool simple_monster_message(const monsters *monster, const char *event, msg += event; msg = apostrophise_fixup(msg); - if (channel == MSGCH_PLAIN && mons_wont_attack(monster)) + if (channel == MSGCH_PLAIN && monster->wont_attack()) channel = MSGCH_FRIEND_ACTION; mpr(msg.c_str(), channel, param); @@ -3693,7 +3693,7 @@ void monster_teleport(monsters *monster, bool instan, bool silent) mgrd(oldplace) = NON_MONSTER; coord_def newpos; - if (monster_random_space(monster, newpos, !mons_wont_attack(monster))) + if (monster_random_space(monster, newpos, !monster->wont_attack())) monster->moveto(newpos); mgrd(monster->pos()) = monster_index(monster); |