fix multiple castsequence lines with supermacro

This commit is contained in:
Jrc13245
2025-08-27 17:06:33 -04:00
parent b91461f1c3
commit cc9198e940
+11 -2
View File
@@ -1477,16 +1477,25 @@ function CleveRoids.DoCastSequence(sequence)
sequence.lastUpdate = GetTime()
sequence.expires = 0
-- Tentatively claim the active sequence, but only keep it if a cast actually fires.
local prevSeq = CleveRoids.currentSequence
CleveRoids.currentSequence = sequence
local action = (sequence.cond or "") .. active.action
-- Ensure we still cast if there are no [] conditionals
local result = CleveRoids.DoWithConditionals(
action,
function(msg) CastSpellByName(msg) end, -- cast even when there are no [] conditionals
nil,
function(msg) CastSpellByName(msg) end, -- fallback cast when no []
CleveRoids.FixEmptyTarget, -- optional: preserves your targeting behavior
not CleveRoids.hasSuperwow,
CastSpellByName
)
-- If the conditionals failed and no cast was started, don't steal currentSequence
if not result then
CleveRoids.currentSequence = prevSeq
end
return result
end
end