/* * Copyright (C) 2016+ AzerothCore , released under GNU GPL v2 license, you may redistribute it * and/or modify it under version 2 of the License, or (at your option), any later version. */ #ifndef _PLAYERBOT_H #define _PLAYERBOT_H #include "AiObjectContext.h" #include "Group.h" #include "Pet.h" #include "PlayerbotAI.h" #include "PlayerbotAIConfig.h" #include "PlayerbotMgr.h" #include "RandomPlayerbotMgr.h" #include "SharedValueContext.h" #include "Spell.h" #include "SpellMgr.h" #include "TravelNode.h" std::vector split(std::string const s, char delim); void split(std::vector& dest, std::string const str, char const* delim); #ifndef WIN32 int strcmpi(char const* s1, char const* s2); #endif #define CAST_ANGLE_IN_FRONT (2.f * static_cast(M_PI) / 3.f) #define EMOTE_ANGLE_IN_FRONT (2.f * static_cast(M_PI) / 6.f) #define GET_PLAYERBOT_AI(object) sPlayerbotsMgr->GetPlayerbotAI(object) #define GET_PLAYERBOT_MGR(object) sPlayerbotsMgr->GetPlayerbotMgr(object) #define AI_VALUE(type, name) context->GetValue(name)->Get() #define AI_VALUE2(type, name, param) context->GetValue(name, param)->Get() #define AI_VALUE_LAZY(type, name) context->GetValue(name)->LazyGet() #define AI_VALUE2_LAZY(type, name, param) context->GetValue(name, param)->LazyGet() #define AI_VALUE_REF(type, name) context->GetValue(name)->RefGet() #define SET_AI_VALUE(type, name, value) context->GetValue(name)->Set(value) #define SET_AI_VALUE2(type, name, param, value) context->GetValue(name, param)->Set(value) #define RESET_AI_VALUE(type, name) context->GetValue(name)->Reset() #define RESET_AI_VALUE2(type, name, param) context->GetValue(name, param)->Reset() #define PAI_VALUE(type, name) sPlayerbotsMgr->GetPlayerbotAI(player)->GetAiObjectContext()->GetValue(name)->Get() #define PAI_VALUE2(type, name, param) \ sPlayerbotsMgr->GetPlayerbotAI(player)->GetAiObjectContext()->GetValue(name, param)->Get() #define GAI_VALUE(type, name) sSharedValueContext->getGlobalValue(name)->Get() #define GAI_VALUE2(type, name, param) sSharedValueContext->getGlobalValue(name, param)->Get() #endif