add raid mark filter and fix casting on unmarked units

This commit is contained in:
pepopo978
2024-05-27 17:28:03 -07:00
parent c862d71d14
commit ed410c536d
3 changed files with 18 additions and 1 deletions
+1 -1
View File
@@ -131,7 +131,7 @@ end
local function pickTarget(selectedPriority, spellNameNoRank, checkRange)
-- Curse the target that best matches the selected priority
local highestPriorityValue = 0
local highestPriorityValue = -1
local targetedGuid = nil
local _, currentTargetGuid = UnitExists("target")
+4
View File
@@ -86,5 +86,9 @@ function Cursive:ShouldDisplayGuid(guid)
shouldDisplay = shouldDisplay and filter.range(guid)
end
if Cursive.db.profile.filterraidmark then
shouldDisplay = shouldDisplay and filter.range(guid)
end
return shouldDisplay
end
+13
View File
@@ -28,6 +28,7 @@ Cursive:RegisterDefaults("profile", {
filterhostile = true,
filterattackable = true,
filterrange = false,
filterraidmark = false,
})
local barOptions = {
@@ -208,6 +209,18 @@ local mobFilters = {
Cursive.db.profile.filterrange = v
end,
},
["raidmark"] = {
type = "toggle",
name = "Has Raid Mark",
desc = "Has Raid Mark",
order = 5,
get = function()
return Cursive.db.profile.filterraidmark
end,
set = function(v)
Cursive.db.profile.filterraidmark = v
end,
},
}
Cursive.cmdtable = {