mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
Fix TC build, analysis warnings and triggering addon message hooks
This commit is contained in:
30
HookMgr.cpp
30
HookMgr.cpp
@@ -1190,12 +1190,12 @@ void Eluna::OnMapChanged(Player* player)
|
||||
|
||||
bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg)
|
||||
{
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_CHAT))
|
||||
return true;
|
||||
|
||||
if (lang == LANG_ADDON)
|
||||
return OnAddonMessage(pPlayer, type, msg, NULL, NULL, NULL, NULL);
|
||||
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_CHAT))
|
||||
return true;
|
||||
|
||||
LOCK_ELUNA;
|
||||
bool result = true;
|
||||
Push(pPlayer);
|
||||
@@ -1223,12 +1223,12 @@ bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg)
|
||||
|
||||
bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg, Group* pGroup)
|
||||
{
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_GROUP_CHAT))
|
||||
return true;
|
||||
|
||||
if (lang == LANG_ADDON)
|
||||
return OnAddonMessage(pPlayer, type, msg, NULL, NULL, pGroup, NULL);
|
||||
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_GROUP_CHAT))
|
||||
return true;
|
||||
|
||||
LOCK_ELUNA;
|
||||
bool result = true;
|
||||
Push(pPlayer);
|
||||
@@ -1257,12 +1257,12 @@ bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg,
|
||||
|
||||
bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg, Guild* pGuild)
|
||||
{
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_GUILD_CHAT))
|
||||
return true;
|
||||
|
||||
if (lang == LANG_ADDON)
|
||||
return OnAddonMessage(pPlayer, type, msg, NULL, pGuild, NULL, NULL);
|
||||
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_GUILD_CHAT))
|
||||
return true;
|
||||
|
||||
LOCK_ELUNA;
|
||||
bool result = true;
|
||||
Push(pPlayer);
|
||||
@@ -1291,12 +1291,12 @@ bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg,
|
||||
|
||||
bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg, Channel* pChannel)
|
||||
{
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_CHANNEL_CHAT))
|
||||
return true;
|
||||
|
||||
if (lang == LANG_ADDON)
|
||||
return OnAddonMessage(pPlayer, type, msg, NULL, NULL, NULL, pChannel);
|
||||
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_CHANNEL_CHAT))
|
||||
return true;
|
||||
|
||||
LOCK_ELUNA;
|
||||
bool result = true;
|
||||
Push(pPlayer);
|
||||
@@ -1325,12 +1325,12 @@ bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg,
|
||||
|
||||
bool Eluna::OnChat(Player* pPlayer, uint32 type, uint32 lang, std::string& msg, Player* pReceiver)
|
||||
{
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_WHISPER))
|
||||
return true;
|
||||
|
||||
if (lang == LANG_ADDON)
|
||||
return OnAddonMessage(pPlayer, type, msg, pReceiver, NULL, NULL, NULL);
|
||||
|
||||
if (!PlayerEventBindings->HasEvents(PLAYER_EVENT_ON_WHISPER))
|
||||
return true;
|
||||
|
||||
LOCK_ELUNA;
|
||||
bool result = true;
|
||||
Push(pPlayer);
|
||||
|
||||
Reference in New Issue
Block a user