diff --git a/Conditionals.lua b/Conditionals.lua index 85a8bbd..6407258 100644 --- a/Conditionals.lua +++ b/Conditionals.lua @@ -137,6 +137,8 @@ local function GetSpellIDsForName(spellName) -- This handles cases like "Faerie Fire (Feral)(Rank 4)" -> "Faerie Fire (Feral)" if spellName then spellName = string.gsub(spellName, "%s*%(%s*Rank%s+%d+%s*%)", "") + -- Convert underscores to spaces for matching (e.g., "Thunder_Clap" -> "Thunder Clap") + spellName = string.gsub(spellName, "_", " ") end return _spellNameToIDs[spellName] end @@ -1163,6 +1165,8 @@ local function _get_debuff_timeleft(unitToken, auraName) -- Strip rank suffix for consistent matching (e.g., "Rake(Rank 4)" -> "Rake") if auraName then auraName = string.gsub(auraName, "%s*%(%s*Rank%s+%d+%s*%)", "") + -- Convert underscores to spaces for matching (e.g., "Thunder_Clap" -> "Thunder Clap") + auraName = string.gsub(auraName, "_", " ") end -- SuperWoW path: GUID-based lookup @@ -2433,6 +2437,8 @@ function CleveRoids.ValidateAura(unit, args, isbuff) -- Strip rank suffix for consistent matching (e.g., "Faerie Fire (Feral)(Rank 4)" -> "Faerie Fire (Feral)") if args.name then args.name = string.gsub(args.name, "%s*%(%s*Rank%s+%d+%s*%)", "") + -- Convert underscores to spaces for matching (e.g., "Thunder_Clap" -> "Thunder Clap") + args.name = string.gsub(args.name, "_", " ") end -- PERFORMANCE: Cache lowercased search name to avoid repeated string.lower calls @@ -2551,6 +2557,8 @@ function CleveRoids.ValidateUnitDebuff(unit, args) -- Strip rank suffix for consistent matching (e.g., "Faerie Fire (Feral)(Rank 4)" -> "Faerie Fire (Feral)") args.name = string.gsub(args.name, "%s*%(%s*Rank%s+%d+%s*%)", "") + -- Convert underscores to spaces for matching (e.g., "Thunder_Clap" -> "Thunder Clap") + args.name = string.gsub(args.name, "_", " ") local found = false local texture, stacks, spellID, remaining diff --git a/Core.lua b/Core.lua index 98582df..09f0bcb 100644 --- a/Core.lua +++ b/Core.lua @@ -1285,11 +1285,14 @@ function CleveRoids.ExecuteMacroBody(body,inline) -- This allows /nofirstaction to clear the stopMacroFlag set by /firstaction local _, _, nofirstactionArgs = string.find(trimmed, "^/nofirstaction%s*(.*)") if nofirstactionArgs then + -- Capture stopOnCastFlag BEFORE DoNoFirstAction clears it + -- If it was true, stopMacroFlag was set by /firstaction, not /stopmacro + local wasFirstActionActive = CleveRoids.stopOnCastFlag CleveRoids.DoNoFirstAction(nofirstactionArgs) -- Also clear stopMacroFlag if it was set by firstaction mechanism -- (but NOT if it was set by explicit /stopmacro) - if CleveRoids.stopOnCastFlag == false and CleveRoids.stopMacroFlag then - -- stopOnCastFlag is false (just cleared by DoNoFirstAction), stopMacroFlag is true + if wasFirstActionActive and CleveRoids.stopMacroFlag then + -- stopOnCastFlag was true before we cleared it, and stopMacroFlag is set -- This means stopMacroFlag was set by the firstaction mechanism, clear it CleveRoids.stopMacroFlag = false if CleveRoids.macroRefDebug then diff --git a/Utility.lua b/Utility.lua index c595637..a0268e2 100644 --- a/Utility.lua +++ b/Utility.lua @@ -1023,10 +1023,11 @@ lib.sharedDebuffs = lib.sharedDebuffs or { [11597] = 30, -- Sunder Armor (Rank 5) [6343] = 10, -- Thunder Clap (Rank 1) - [8198] = 10, -- Thunder Clap (Rank 2) - [8205] = 10, -- Thunder Clap (Rank 3) - [11580] = 10, -- Thunder Clap (Rank 4) - [11581] = 10, -- Thunder Clap (Rank 5) + [8198] = 14, -- Thunder Clap (Rank 2) + [8205] = 18, -- Thunder Clap (Rank 3) + [11580] = 22, -- Thunder Clap (Rank 4) + [11581] = 26, -- Thunder Clap (Rank 5) + [13532] = 30, -- Thunder Clap (Rank 6) [1160] = 30, -- Demoralizing Shout (Rank 1) [6190] = 30, -- Demoralizing Shout (Rank 2)