fix(Core/SpellMgr): Essence of Wintergrasp only applies if config is enabled (#4110)

This commit is contained in:
Degen
2021-01-17 15:14:27 -04:00
committed by GitHub
parent 27a0a59509
commit 5a1bb5bc66

View File

@@ -1109,6 +1109,9 @@ bool SpellArea::IsFitToRequirements(Player const* player, uint32 newZone, uint32
if (!player)
return false;
if (!sWorld->getBoolConfig(CONFIG_WINTERGRASP_ENABLE))
return false;
Battlefield* Bf = sBattlefieldMgr->GetBattlefieldByBattleId(BATTLEFIELD_BATTLEID_WG);
if (!Bf || player->GetTeamId() != Bf->GetDefenderTeam() || Bf->IsWarTime())
return false;