Commit aed4410a authored by Sean Anderson / Shrom's avatar Sean Anderson / Shrom Committed by Simpy
Browse files

add tap denied filter

parent f6eea199
......@@ -660,6 +660,12 @@ function mod:StyleFilterConditionCheck(frame, filter, trigger)
if frame.isPlayerControlled and not frame.isPlayer then passed = true else return end
end
-- Unit Tap Denied
if trigger.isTapDenied or trigger.isNotTapDenied then
local isTapDenied = UnitIsTapDenied(frame.unit)
if (trigger.isTapDenied and isTapDenied) or (trigger.isNotTapDenied and not isTapDenied) then passed = true else return end
end
-- Player Vehicle
if trigger.inVehicle or trigger.outOfVehicle then
local inVehicle = UnitInVehicle('player')
......@@ -1021,6 +1027,10 @@ function mod:StyleFilterConfigure()
mod.StyleFilterTriggerEvents.UNIT_PET = 1
end
if t.isTapDenied or t.isNotTapDenied then
mod.StyleFilterTriggerEvents.UNIT_FLAGS = 1
end
if t.raidTarget then
mod.StyleFilterTriggerEvents.RAID_TARGET_UPDATE = 1
end
......
......@@ -246,6 +246,8 @@ E.StyleFilterDefaults = {
},
isResting = false,
isPet = false,
isTapDenied = false,
isNotTapDenied = false,
-- combat
inCombat = false,
outOfCombat = false,
......
......@@ -606,6 +606,8 @@ L["If enabled then the filter will only activate when the unit is in combat."] =
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = "Wenn eingeschlatet, wird der Filter nur aktiviert wenn die Einheit nicht in einem Fahrzeug ist."
L["If enabled then the filter will only activate when the unit is not targeting you."] = "Wenn eingeschaltet, wird der Filter nur aktiviert, wenn die Einheit dich nicht als Ziel hat."
L["If enabled then the filter will only activate when the unit is out of combat."] = "Wenn eingeschaltet, wird der Filter nur aktiviert, wenn die Einheit nicht im Kampf ist."
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is targeting you."] = "Wenn eingeschaltet, wird der Filter nur aktiviert, wenn die Einheit dich als Ziel hat."
L["If enabled then the filter will only activate when you are focusing the unit."] = "Wenn eingeschaltet, wird der Filter nur aktiviert, wenn du die Einheit fokussierst."
L["If enabled then the filter will only activate when you are in a Vehicle."] = "Wenn eingeschaltet, wird der Filter nur aktiviert, wenn du in einem Fahrzeug bist."
......@@ -1252,6 +1254,9 @@ L["Uniform Threshold"] = "Einheitlicher Schwellenwert"
L["Unit Conditions"] = "Einheit Konditionen"
L["Unit in Combat"] = "Einheit im Kampf"
L["Unit in Vehicle"] = "Einheit im Fahrzeug"
L["Unit is Pet"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit Out of Combat"] = "Einheit nicht im Kampf"
L["Unit Out of Vehicle"] = "Einheit nicht im Fahrzeug"
L["Unit Prefix Style"] = "Einheit Präfix Stil"
......
......@@ -599,6 +599,7 @@ L["If enabled then the filter will only activate if the level of the unit is equ
L["If enabled then the filter will only activate if the level of the unit is equal to or lower than this value."] = true
L["If enabled then the filter will only activate if the level of the unit matches this value."] = true
L["If enabled then the filter will only activate if the level of the unit matches your own."] = true
L["If enabled then the filter will only activate when the unit is a player's pet"] = true
L["If enabled then the filter will only activate if the unit is casting interruptible spells."] = true
L["If enabled then the filter will only activate if the unit is casting not interruptible spells."] = true
L["If enabled then the filter will only activate if the unit is not casting or channeling one of the selected spells."] = true
......@@ -607,6 +608,8 @@ L["If enabled then the filter will only activate when the unit is in combat."] =
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = true
L["If enabled then the filter will only activate when the unit is out of combat."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is targeting you."] = true
L["If enabled then the filter will only activate when you are focusing the unit."] = true
L["If enabled then the filter will only activate when you are in a Vehicle."] = true
......@@ -1251,11 +1254,14 @@ L["Uniform Threshold"] = true
L["Unit Conditions"] = true
L["Unit in Combat"] = true
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = true
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = true
L["Unit Target"] = true
L["Unit Type"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["UnitFrames"] = true
L["Unlock various elements of the UI to be repositioned."] = true
L["Up"] = true
......
......@@ -598,11 +598,14 @@ L["If enabled then the filter will only activate if the level of the unit matche
L["If enabled then the filter will only activate if the unit is casting interruptible spells."] = true
L["If enabled then the filter will only activate if the unit is casting not interruptible spells."] = true
L["If enabled then the filter will only activate if the unit is not casting or channeling one of the selected spells."] = true
L["If enabled then the filter will only activate when the unit is a player's pet"] = true
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is in combat."] = true
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = true
L["If enabled then the filter will only activate when the unit is out of combat."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is targeting you."] = true
L["If enabled then the filter will only activate when you are focusing the unit."] = true
L["If enabled then the filter will only activate when you are in a Vehicle."] = true
......@@ -1245,8 +1248,11 @@ L["Under Power Threshold"] = true
L["Unfriendly"] = true
L["Uniform Threshold"] = true
L["Unit Conditions"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = true
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = true
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = true
......
......@@ -604,6 +604,8 @@ L["If enabled then the filter will only activate when the unit is in combat."] =
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = true
L["If enabled then the filter will only activate when the unit is out of combat."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is targeting you."] = true
L["If enabled then the filter will only activate when you are focusing the unit."] = true
L["If enabled then the filter will only activate when you are in a Vehicle."] = true
......@@ -1245,8 +1247,11 @@ L["Under Power Threshold"] = true
L["Unfriendly"] = true
L["Uniform Threshold"] = "Déclencheur identique"
L["Unit Conditions"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = true
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = true
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = "Style des préfixes d'unités"
......
......@@ -601,6 +601,8 @@ L["If enabled then the filter will only activate if the unit is not casting or c
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is in combat."] = "활성화하면 유닛이 전투 중일때만 필터가 작동합니다."
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = "활성화하면 유닛이 자신을 대상으로 잡고 있지 않을 때만 필터가 작동합니다."
L["If enabled then the filter will only activate when the unit is out of combat."] = "활성화하면 유닛이 비전투 중일때만 필터가 작동합니다."
L["If enabled then the filter will only activate when the unit is targeting you."] = "활성화하면 유닛이 자신을 대상으로 잡고 있을 때만 필터가 작동합니다."
......@@ -1245,8 +1247,11 @@ L["Under Power Threshold"] = true
L["Unfriendly"] = true
L["Uniform Threshold"] = true
L["Unit Conditions"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = "유닛 전투중"
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = "유닛 비전투"
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = "단위 축약 방식"
......
......@@ -602,6 +602,8 @@ L["If enabled then the filter will only activate if the unit is not casting or c
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is in combat."] = true
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = true
L["If enabled then the filter will only activate when the unit is out of combat."] = true
L["If enabled then the filter will only activate when the unit is targeting you."] = true
......@@ -1246,8 +1248,11 @@ L["Under Power Threshold"] = true
L["Unfriendly"] = true
L["Uniform Threshold"] = true
L["Unit Conditions"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = true
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = true
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = true
......
......@@ -601,6 +601,8 @@ L["If enabled then the filter will only activate if the unit is not casting or c
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is in combat."] = "Если включено, фильтр будет активирован только когда юнит в бою."
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = "Если включено, фильтр будет активирован только когда вы не являетесь целью юнита."
L["If enabled then the filter will only activate when the unit is out of combat."] = "Если включено, фильтр будет активирован только когда юнит вне боя."
L["If enabled then the filter will only activate when the unit is targeting you."] = "Если включено, фильтр будет активирован только когда вы являетесь целью юнита."
......@@ -1245,8 +1247,11 @@ L["Under Power Threshold"] = "Менее значения ресурса"
L["Unfriendly"] = "Неприязнь"
L["Uniform Threshold"] = "Граница убывания"
L["Unit Conditions"] = true
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = "Юнит в бою"
L["Unit in Vehicle"] = true
L["Unit is Pet"] = true
L["Unit Out of Combat"] = "Юнит вне боя"
L["Unit Out of Vehicle"] = true
L["Unit Prefix Style"] = "Стиль сокращений"
......
......@@ -603,6 +603,8 @@ L["If enabled then the filter will only activate if the unit is not casting or c
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = "启用后过滤器仅在单位在载具中的时候激活."
L["If enabled then the filter will only activate when the unit is in combat."] = "启用后过滤器仅在单位在战斗中的时候激活."
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = "启用后过滤器仅在单位不在载具中的时候激活."
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = "启用后过滤器仅在单位目标不为你的时候激活."
L["If enabled then the filter will only activate when the unit is out of combat."] = "启用后过滤器仅在单位不在战斗中的时候激活."
L["If enabled then the filter will only activate when the unit is targeting you."] = "启用后过滤器仅在单位目标为你的时候激活."
......@@ -1246,8 +1248,11 @@ L["Under Power Threshold"] = "低于能量阈值"
L["Unfriendly"] = "非友好"
L["Uniform Threshold"] = "统一阈值"
L["Unit Conditions"] = "单位状态"
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = "单位在战斗中"
L["Unit in Vehicle"] = "单位在载具中"
L["Unit is Pet"] = true
L["Unit Out of Combat"] = "单位不在战斗中"
L["Unit Out of Vehicle"] = "单位不在载具中"
L["Unit Prefix Style"] = "单位缩写"
......
......@@ -603,6 +603,8 @@ L["If enabled then the filter will only activate if the unit is not casting or c
L["If enabled then the filter will only activate when the unit is in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is in combat."] = "如果選中則過濾器只會在單位在戰鬥中的時候啟動"
L["If enabled then the filter will only activate when the unit is not in a Vehicle."] = true
L["If enabled then the filter will only activate when the unit is tap denied"] = true
L["If enabled then the filter will only activate when the unit is not tap denied"] = true
L["If enabled then the filter will only activate when the unit is not targeting you."] = "如果選中則過濾器只會在單位沒有選中你的時候啟動"
L["If enabled then the filter will only activate when the unit is out of combat."] = "如果選中則過濾器只會在單位不在戰鬥中的時候啟動"
L["If enabled then the filter will only activate when the unit is targeting you."] = "如果選中則過濾器只會在單位選中你的時候啟動"
......@@ -1247,8 +1249,11 @@ L["Under Power Threshold"] = "低於能量閾值"
L["Unfriendly"] = "不友好"
L["Uniform Threshold"] = "統一閾值"
L["Unit Conditions"] = "單位條件"
L["Unit is Tap Denied"] = true
L["Unit is Not Tap Denied"] = true
L["Unit in Combat"] = "單位戰鬥中"
L["Unit in Vehicle"] = "單位在載具"
L["Unit is Pet"] = true
L["Unit Out of Combat"] = "單位戰鬥外"
L["Unit Out of Vehicle"] = "單位不在載具"
L["Unit Prefix Style"] = "單位縮寫"
......
......@@ -996,6 +996,18 @@ local function UpdateFilterGroup()
desc = L["If enabled then the filter will only activate when the unit is a player's pet"],
order = 12,
},
isTapDenied = {
type = 'toggle',
name = L["Unit is Tap Denied"],
desc = L["If enabled then the filter will only activate when the unit is tap denied"],
order = 13,
},
isNotTapDenied = {
type = 'toggle',
name = L["Unit is Not Tap Denied"],
desc = L["If enabled then the filter will only activate when the unit is not tap denied"],
order = 14,
},
}
}
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment