Scripts/Commands: Demangled typeinfo of f7466c2 for gcc/cmake

This commit is contained in:
Treeston
2018-07-18 17:33:43 +02:00
parent f7466c28a5
commit f93cb448f1
2 changed files with 6 additions and 2 deletions

View File

@@ -39,6 +39,8 @@ EndScriptData */
#include "PoolMgr.h"
#include "RBAC.h"
#include "WorldSession.h"
#include <boost/core/demangle.hpp>
#include <typeinfo>
// definitions are over in cs_npc.cpp
bool HandleNpcSpawnGroup(ChatHandler* handler, char const* args);
@@ -698,7 +700,7 @@ public:
handler->PSendSysMessage(LANG_OBJECTINFO_AIINFO, gameObjectInfo->AIName.c_str(), sObjectMgr->GetScriptName(gameObjectInfo->ScriptId).c_str());
if (GameObjectAI const* ai = thisGO ? thisGO->AI() : nullptr)
handler->PSendSysMessage(LANG_OBJECTINFO_AITYPE, typeid(*ai).name());
handler->PSendSysMessage(LANG_OBJECTINFO_AITYPE, boost::core::demangle(typeid(*ai).name()).c_str());
if (GameObjectDisplayInfoEntry const* modelInfo = sGameObjectDisplayInfoStore.LookupEntry(displayId))
handler->PSendSysMessage(LANG_GOINFO_MODEL, modelInfo->maxX, modelInfo->maxY, modelInfo->maxZ, modelInfo->minX, modelInfo->minY, modelInfo->minZ);

View File

@@ -42,6 +42,8 @@ EndScriptData */
#include "Transport.h"
#include "World.h"
#include "WorldSession.h"
#include <boost/core/demangle.hpp>
#include <typeinfo>
template<typename E, typename T = char const*>
struct EnumName
@@ -812,7 +814,7 @@ public:
handler->PSendSysMessage(LANG_NPCINFO_POSITION, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ());
handler->PSendSysMessage(LANG_OBJECTINFO_AIINFO, target->GetAIName().c_str(), target->GetScriptName().c_str());
if (CreatureAI const* ai = target->AI())
handler->PSendSysMessage(LANG_OBJECTINFO_AITYPE, typeid(*ai).name());
handler->PSendSysMessage(LANG_OBJECTINFO_AITYPE, boost::core::demangle(typeid(*ai).name()).c_str());
handler->PSendSysMessage(LANG_NPCINFO_FLAGS_EXTRA, cInfo->flags_extra);
for (uint8 i = 0; i < FLAGS_EXTRA_COUNT; ++i)
if (cInfo->flags_extra & flagsExtra[i].Value)