aboutsummaryrefslogtreecommitdiff
path: root/src/server/game
diff options
context:
space:
mode:
authorTreeston <treeston.mmoc@gmail.com>2018-01-09 18:09:24 +0100
committerTreeston <treeston.mmoc@gmail.com>2018-01-09 18:09:24 +0100
commitf45c211987794ff7e4192e0d3d4ca6bf67335fb5 (patch)
treeb9bc15e45e349ca157f7d5401bbb2dab2b3a8d85 /src/server/game
parent274dede3dc89fa72ec1687d5ff454feba9849e47 (diff)
Scripts/Commands: New command: .debug threatinfo
Diffstat (limited to 'src/server/game')
-rw-r--r--src/server/game/Accounts/RBAC.h1
-rw-r--r--src/server/game/Combat/ThreatManager.h4
2 files changed, 4 insertions, 1 deletions
diff --git a/src/server/game/Accounts/RBAC.h b/src/server/game/Accounts/RBAC.h
index f745adba50c..f399ac69a21 100644
--- a/src/server/game/Accounts/RBAC.h
+++ b/src/server/game/Accounts/RBAC.h
@@ -775,6 +775,7 @@ enum RBACPermissions
RBAC_PERM_COMMAND_RELOAD_QUEST_GREETING_LOCALE = 867,
RBAC_PERM_COMMAND_MODIFY_POWER = 868, // reserved
RBAC_PERM_COMMAND_DEBUG_SEND_PLAYER_CHOICE = 869, // reserved
+ RBAC_PERM_COMMAND_DEBUG_THREATINFO = 870,
//
// IF YOU ADD NEW PERMISSIONS, ADD THEM IN MASTER BRANCH AS WELL!
//
diff --git a/src/server/game/Combat/ThreatManager.h b/src/server/game/Combat/ThreatManager.h
index 8ea28a65c11..fa6b596d88b 100644
--- a/src/server/game/Combat/ThreatManager.h
+++ b/src/server/game/Combat/ThreatManager.h
@@ -22,6 +22,7 @@
#include "IteratorPair.h"
#include "ObjectGuid.h"
#include "SharedDefines.h"
+#include <array>
#include <boost/heap/fibonacci_heap.hpp>
#include <unordered_map>
#include <vector>
@@ -204,7 +205,7 @@ class TC_GAME_API ThreatManager
void PutThreatenedByMeRef(ObjectGuid const& guid, ThreatReference* ref);
void PurgeThreatenedByMeRef(ObjectGuid const& guid);
std::unordered_map<ObjectGuid, ThreatReference*> _threatenedByMe; // these refs are entries for myself on other units' threat lists
- float _singleSchoolModifiers[MAX_SPELL_SCHOOL]; // most spells are single school - we pre-calculate these and store them
+ std::array<float, MAX_SPELL_SCHOOL> _singleSchoolModifiers; // most spells are single school - we pre-calculate these and store them
mutable std::unordered_map<std::underlying_type<SpellSchoolMask>::type, float> _multiSchoolModifiers; // these are calculated on demand
// redirect system (is kind of dumb, but that's because none of the redirection spells actually have any aura effect associated with them, so spellscript needs to deal with it)
@@ -218,6 +219,7 @@ class TC_GAME_API ThreatManager
friend class ThreatReference;
friend struct CompareThreatLessThan;
+ friend class debug_commandscript;
};
// Please check Game/Combat/ThreatManager.h for documentation on how this class works!