mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-15 23:20:36 +01:00
Core/PetAI: Change an assert to a TC_LOG_ERROR
(cherry picked from commit c3619f42a5)
This commit is contained in:
@@ -487,7 +487,11 @@ bool PetAI::CanAttack(Unit* target)
|
||||
return false;
|
||||
}
|
||||
|
||||
ASSERT(me->GetCharmInfo());
|
||||
if (!me->GetCharmInfo())
|
||||
{
|
||||
TC_LOG_ERROR("scripts.ai.petai", "me->GetCharmInfo() is NULL in PetAI::CanAttack(). Debug info: %s", GetDebugInfo().c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
// Passive - passive pets can attack if told to
|
||||
if (me->HasReactState(REACT_PASSIVE))
|
||||
|
||||
Reference in New Issue
Block a user