diff --git a/Core.lua b/Core.lua index 8d7a81cbe..9c01eae34 100644 --- a/Core.lua +++ b/Core.lua @@ -1668,7 +1668,7 @@ function Hekili.Update( initial ) if ( casting or channeling ) and not shouldBreak and not shouldCheck then if debug then Hekili:Debug( 1, "Finishing queued event #%d ( %s of %s ) due at %.2f as player is casting and castable spells are not ready.\nCasting: %s, Channeling: %s, Break: %s, Check: %s", n, event.type, event.action, t, casting and "Yes" or "No", channeling and "Yes" or "No", shouldBreak and "Yes" or "No", shouldCheck and "Yes" or "No" ) end - if t > 0 then + if t >= 0 then state.advance( t ) local resources diff --git a/Events.lua b/Events.lua index c8039c259..76c727b3b 100644 --- a/Events.lua +++ b/Events.lua @@ -29,6 +29,8 @@ local GetSpellCooldown = function(spellID) end end +local GetSpellInfo = ns.GetUnpackedSpellInfo + local FindStringInInventoryItemTooltip = ns.FindStringInInventoryItemTooltip local ResetDisabledGearAndSpells = ns.ResetDisabledGearAndSpells local WipeCovenantCache = ns.WipeCovenantCache diff --git a/State.lua b/State.lua index 65a0424ab..2e45312a2 100644 --- a/State.lua +++ b/State.lua @@ -6786,10 +6786,6 @@ end function state.advance( time ) - if time <= 0 then - return - end - if not state.resetting and not state.modified then state.modified = true end @@ -6835,6 +6831,10 @@ function state.advance( time ) if eCount == 10 then break end end + if time <= 0 then + return + end + for k in pairs( class.resources ) do local resource = state[ k ]