fix(Core/Unit): add Dual Wield 'auto' to improve scripting (#23078)

This commit is contained in:
sogladev
2025-10-03 08:26:31 +02:00
committed by GitHub
parent c13492fb31
commit 19f1ede216
6 changed files with 35 additions and 18 deletions

View File

@@ -3800,7 +3800,7 @@ bool Player::resetTalents(bool noResetCost)
if (m_canTitanGrip)
SetCanTitanGrip(false);
// xinef: remove dual wield if player does not have dual wield spell (shamans)
if (!HasSpell(674) && m_canDualWield)
if (!HasSpell(674) && CanDualWield())
SetCanDualWield(false);
AutoUnequipOffhandIfNeed();
@@ -15270,7 +15270,7 @@ void Player::ActivateSpec(uint8 spec)
if (!HasTalent(46917, GetActiveSpec()) && m_canTitanGrip)
SetCanTitanGrip(false);
// xinef: remove dual wield if player does not have dual wield spell (shamans)
if (!HasSpell(674) && m_canDualWield)
if (!HasSpell(674) && CanDualWield())
SetCanDualWield(false);
AutoUnequipOffhandIfNeed();