mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 02:20:27 +00:00
feat(Core/Hooks): added collection of hooks to extends AC (#3047)
This collection of hooks comes from the Maelstrom project. It allows to release modules such as : - 3v3-soloqueue - 1v1 arena - pvestats and many others
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
#include "ObjectMgr.h"
|
||||
#include "Opcodes.h"
|
||||
#include "Player.h"
|
||||
#include "ScriptMgr.h"
|
||||
#include "World.h"
|
||||
#include "WorldPacket.h"
|
||||
#include "WorldSession.h"
|
||||
@@ -196,9 +197,7 @@ void WorldSession::HandleSendMail(WorldPacket& recvData)
|
||||
}
|
||||
}*/
|
||||
|
||||
uint32 rc_account = receive
|
||||
? receive->GetSession()->GetAccountId()
|
||||
: sObjectMgr->GetPlayerAccountIdByGUID(rc);
|
||||
uint32 rc_account = receive ? receive->GetSession()->GetAccountId() : sObjectMgr->GetPlayerAccountIdByGUID(rc);
|
||||
|
||||
if (/*!accountBound*/ GetAccountId() != rc_account && !sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL) && player->GetTeamId() != rc_teamId && AccountMgr::IsPlayerAccount(GetSecurity()))
|
||||
{
|
||||
@@ -255,6 +254,9 @@ void WorldSession::HandleSendMail(WorldPacket& recvData)
|
||||
return;
|
||||
}
|
||||
|
||||
if (!sScriptMgr->CanSendMail(player, rc, mailbox, subject, body, money, COD, item))
|
||||
return;
|
||||
|
||||
items[i] = item;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user