diff options
| author | jackpoz <giacomopoz@gmail.com> | 2021-07-11 11:55:23 +0200 |
|---|---|---|
| committer | jackpoz <giacomopoz@gmail.com> | 2021-07-11 11:55:23 +0200 |
| commit | 40f4b141bd602d6285c3d2d21315a29b2ab3cce1 (patch) | |
| tree | 20d1d67d89808e64c675d5068f4033762258326f /src | |
| parent | 9bb97a1ceef21e8945284be9deef79044194d9aa (diff) | |
Core/Unit: Include m_Controlled in crashlogs
Diffstat (limited to 'src')
| -rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 24896ab1560..5f486aa9082 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -13677,6 +13677,15 @@ std::string Unit::GetDebugInfo() const << "GetCharmedGUID(): " << GetCharmedGUID().ToString() << "\n" << "GetCharmerGUID(): " << GetCharmerGUID().ToString() << "\n" << "" << (GetVehicleKit() ? GetVehicleKit()->GetDebugInfo() : "No vehicle kit") << "\n" - << "GetGameClientMovingMe(): " << (GetGameClientMovingMe() ? GetGameClientMovingMe()->GetDebugInfo() : "NULL"); + << "GetGameClientMovingMe(): " << (GetGameClientMovingMe() ? GetGameClientMovingMe()->GetDebugInfo() : "NULL") << "\n" + << "m_Controlled size: " << m_Controlled.size(); + + size_t controlledCount = 0; + for (Unit* controlled : m_Controlled) + { + ++controlledCount; + sstr << "\n" << "m_Controlled " << controlledCount << " : " << controlled->GetGUID().ToString(); + } + return sstr.str(); } |
