fix @unitid fallback as it shouldnt

This commit is contained in:
Jrc13245
2025-12-14 17:39:10 -05:00
parent 3b47e7b164
commit 4c69457dff
+10
View File
@@ -2290,6 +2290,9 @@ function CleveRoids.DoTarget(msg)
-- Save original target GUID for potential restoration (SuperWoW returns GUID as 2nd value)
local _, originalTargetGuid = UnitExists("target")
-- Track if an explicit target was specified via @unit syntax
local explicitTarget = conditionals.target
do
local unitTok = conditionals.target
@@ -2316,6 +2319,13 @@ function CleveRoids.DoTarget(msg)
TargetUnit(unitTok)
return true
end
-- If an explicit target was specified via @unit syntax but doesn't exist or isn't valid,
-- return false instead of falling through to candidate search.
-- This ensures "/target [@mouseover,harm,alive]" does nothing when mouse is over empty ground.
if explicitTarget then
return false
end
end
if UnitExists("target") and IsGuidValid("target", conditionals) then