mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-17 08:00:48 +01:00
Core/Unit: Add more logs for #26325
Add more logs to try spotting the cause of #26325 . It might be that a minion is added to a owner that is not in world.
Report any issue with minions/pets that contain the log.
(cherry picked from commit 3f08c16749)
This commit is contained in:
@@ -5815,6 +5815,12 @@ void Unit::SetMinion(Minion *minion, bool apply)
|
||||
return;
|
||||
}
|
||||
|
||||
if (!IsInWorld())
|
||||
{
|
||||
TC_LOG_FATAL("entities.unit", "SetMinion: Minion being added to owner not in world. Minion: %s, Owner: %s", minion->GetGUID().ToString().c_str(), GetDebugInfo().c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
minion->SetOwnerGUID(GetGUID());
|
||||
|
||||
m_Controlled.insert(minion);
|
||||
|
||||
Reference in New Issue
Block a user