diff --git a/src/monster.cpp b/src/monster.cpp index 8b7f5235d7f7..4e7b9fec9673 100644 --- a/src/monster.cpp +++ b/src/monster.cpp @@ -1394,7 +1394,6 @@ void monster::melee_attack( Creature &target ) void monster::melee_attack( Creature &target, float accuracy ) { - int hitspread = target.deal_melee_attack( this, melee::melee_hit_range( accuracy ) ); mod_moves( -type->attack_cost ); if( type->melee_dice == 0 ) { // We don't attack, so just return @@ -1410,6 +1409,8 @@ void monster::melee_attack( Creature &target, float accuracy ) return; } + int hitspread = target.deal_melee_attack( this, melee::melee_hit_range( accuracy ) ); + if( target.is_player() || ( target.is_npc() && g->u.attitude_to( target ) == A_FRIENDLY ) ) { // Make us a valid target for a few turns