diff --git a/WeakAuras/GenericTrigger.lua b/WeakAuras/GenericTrigger.lua index d0959dd2b8..f39b86459c 100644 --- a/WeakAuras/GenericTrigger.lua +++ b/WeakAuras/GenericTrigger.lua @@ -2611,6 +2611,17 @@ do end end + + ---@param identifier string | number + ---@return number? startTime, number? duration + function WeakAuras.GetSpellLossOfControlCooldown(identifier) + if WeakAuras.IsTWW() then + return C_Spell.GetSpellLossOfControlCooldown(identifier) + else + return GetSpellLossOfControlCooldown(identifier) + end + end + ---@param id string ---@param ignoreRuneCD boolean ---@param showgcd boolean diff --git a/WeakAuras/Prototypes.lua b/WeakAuras/Prototypes.lua index d24c133224..2c23ab5d87 100644 --- a/WeakAuras/Prototypes.lua +++ b/WeakAuras/Prototypes.lua @@ -5260,7 +5260,7 @@ Private.event_prototypes = { local charges, maxCharges, spellCount, chargeGainTime, chargeLostTime = WeakAuras.GetSpellCharges(spellname, ignoreSpellKnown, followoverride) local stacks = maxCharges and maxCharges ~= 1 and charges or (spellCount and spellCount > 0 and spellCount) or nil; if showlossofcontrol and startTime and duration then - local locStart, locDuration = GetSpellLossOfControlCooldown(spellname); + local locStart, locDuration = WeakAuras.GetSpellLossOfControlCooldown(spellname); if locStart and locDuration and (locStart + locDuration) > (startTime + duration) then startTime = locStart duration = locDuration