From 0915163a542776844b0ce664221417f86c05245c Mon Sep 17 00:00:00 2001 From: dolorous Date: Mon, 7 Apr 2008 22:50:11 +0000 Subject: More neutrality cleanups. Holy beings neutralized on sight by your piety will not attack you and can swap positions with you. All other neutral beings behave the same as before. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4119 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/fight.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'crawl-ref/source/fight.cc') diff --git a/crawl-ref/source/fight.cc b/crawl-ref/source/fight.cc index 0bba6838c7..998a3147e4 100644 --- a/crawl-ref/source/fight.cc +++ b/crawl-ref/source/fight.cc @@ -310,7 +310,7 @@ melee_attack::melee_attack(actor *attk, actor *defn, void melee_attack::check_hand_half_bonus_eligible() { - hand_half_bonus = + hand_half_bonus = unarmed_ok && !can_do_unarmed && !shield @@ -326,14 +326,14 @@ void melee_attack::init_attack() if (defender && defender->atype() == ACT_MONSTER) def = dynamic_cast(defender); - + weapon = attacker->weapon(attack_number); damage_brand = attacker->damage_brand(attack_number); if (weapon && weapon->base_type == OBJ_WEAPONS && is_random_artefact( *weapon )) { - randart_wpn_properties( *weapon, art_props ); + randart_wpn_properties( *weapon, art_props ); } wpn_skill = weapon? weapon_skill( *weapon ) : SK_UNARMED_COMBAT; @@ -3908,8 +3908,8 @@ bool monster_attack(int monster_attacking) { monsters *attacker = &menv[monster_attacking]; - // Friendly monsters won't attack unless confused. - if (mons_friendly(attacker) && !mons_is_confused(attacker)) + // Friendly and good neutral monsters won't attack unless confused. + if (mons_wont_attack(attacker) && !mons_is_confused(attacker)) return false; // In case the monster hasn't noticed you, bumping into it will -- cgit v1.2.3-54-g00ecf