mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-15 01:59:09 +00:00
feat(Commands): Added cheat commands (#1412)
This commit is contained in:
committed by
Francesco Borzì
parent
e659ca5fe9
commit
40f68ab026
@@ -696,6 +696,10 @@ uint32 Unit::DealDamage(Unit* attacker, Unit* victim, uint32 damage, CleanDamage
|
||||
// Signal to pets that their owner was attacked
|
||||
Pet* pet = victim->ToPlayer()->GetPet();
|
||||
|
||||
if (victim->GetTypeId() == TYPEID_PLAYER)
|
||||
if (victim->ToPlayer()->GetCommandStatus(CHEAT_GOD))
|
||||
return 0;
|
||||
|
||||
if (pet && pet->IsAlive())
|
||||
pet->AI()->OwnerAttackedBy(attacker);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user