mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-22 18:15:31 +01:00
Core/WorldStates: Migrate war mode bonus value worldstates to new system
This commit is contained in:
@@ -45,7 +45,7 @@
|
||||
#include "SpellPackets.h"
|
||||
#include "SpellScript.h"
|
||||
#include "Vehicle.h"
|
||||
#include "World.h"
|
||||
#include "WorldStateMgr.h"
|
||||
|
||||
class spell_gen_absorb0_hitlimit1 : public AuraScript
|
||||
{
|
||||
@@ -4821,10 +4821,15 @@ class spell_gen_war_mode_enlisted : public AuraScript
|
||||
if (!target)
|
||||
return;
|
||||
|
||||
if (target->GetTeamId() == sWorld->GetWarModeDominantFaction())
|
||||
return;
|
||||
|
||||
amount += sWorld->GetWarModeOutnumberedFactionReward();
|
||||
switch (target->GetTeamId())
|
||||
{
|
||||
case TEAM_ALLIANCE:
|
||||
amount = sWorldStateMgr->GetValue(WS_WAR_MODE_ALLIANCE_BUFF_VALUE, nullptr);
|
||||
break;
|
||||
case TEAM_HORDE:
|
||||
amount = sWorldStateMgr->GetValue(WS_WAR_MODE_HORDE_BUFF_VALUE, nullptr);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void Register() override
|
||||
|
||||
Reference in New Issue
Block a user