add player filter
This commit is contained in:
@@ -8,6 +8,10 @@ filter.attackable = function(unit)
|
||||
return UnitCanAttack("player", unit) and true or false
|
||||
end
|
||||
|
||||
filter.player = function(unit)
|
||||
return UnitIsPlayer(unit) and true or false
|
||||
end
|
||||
|
||||
filter.infight = function(unit)
|
||||
return UnitAffectingCombat(unit) and true or false
|
||||
end
|
||||
@@ -103,5 +107,9 @@ function Cursive:ShouldDisplayGuid(guid)
|
||||
shouldDisplay = shouldDisplay and filter.icon(guid)
|
||||
end
|
||||
|
||||
if Cursive.db.profile.filterplayer then
|
||||
shouldDisplay = shouldDisplay and filter.player(guid)
|
||||
end
|
||||
|
||||
return shouldDisplay
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user