Core/Unit: Fix pets aggromode - do not set player in combat untill pet has actually done damage to target (fix by Kaelima)

Closes issue 4894.

--HG--
branch : trunk
This commit is contained in:
click
2010-11-26 02:02:05 +01:00
parent 54b8bca155
commit 025d070752
+1 -1
View File
@@ -9389,7 +9389,7 @@ bool Unit::Attack(Unit *victim, bool meleeAttack)
//if (GetTypeId() == TYPEID_UNIT)
// this->ToCreature()->SetCombatStartPosition(GetPositionX(), GetPositionY(), GetPositionZ());
if (GetTypeId() == TYPEID_UNIT)
if (GetTypeId() == TYPEID_UNIT && !this->ToCreature()->IsPet())
{
// should not let player enter combat by right clicking target
SetInCombatWith(victim);