mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-03-08 02:00:29 +00:00
fix(Core/Scripting): Call OnBattlefieldPlayerJoinWar() before adding … (#24964)
This commit is contained in:
@@ -434,6 +434,8 @@ void Battlefield::PlayerAcceptInviteToWar(Player* player)
|
||||
if (!IsWarTime())
|
||||
return;
|
||||
|
||||
sScriptMgr->OnBattlefieldPlayerJoinWar(this, player);
|
||||
|
||||
if (AddOrSetPlayerToCorrectBfGroup(player))
|
||||
{
|
||||
player->GetSession()->SendBfEntered(m_BattleId);
|
||||
@@ -444,7 +446,6 @@ void Battlefield::PlayerAcceptInviteToWar(Player* player)
|
||||
player->ToggleAFK();
|
||||
|
||||
OnPlayerJoinWar(player); //for scripting
|
||||
sScriptMgr->OnBattlefieldPlayerJoinWar(this, player);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user