diff --git a/api/config.lua b/api/config.lua index a5adcb27..7797aaa4 100644 --- a/api/config.lua +++ b/api/config.lua @@ -603,6 +603,7 @@ function pfUI:LoadConfig() pfUI:UpdateConfig("nameplates", nil, "heightcast", "8") pfUI:UpdateConfig("nameplates", nil, "cpdisplay", "0") pfUI:UpdateConfig("thirdparty", nil, "chatbg", "1") + pfUI:UpdateConfig("thirdparty", nil, "showmeter", "0") pfUI:UpdateConfig("thirdparty", "dpsmate", "skin", "1") pfUI:UpdateConfig("thirdparty", "dpsmate", "dock", "1") pfUI:UpdateConfig("thirdparty", "swstats", "skin", "1") diff --git a/env/translations_deDE.lua b/env/translations_deDE.lua index 073e5b22..cfbc24b0 100644 --- a/env/translations_deDE.lua +++ b/env/translations_deDE.lua @@ -373,6 +373,7 @@ pfUI_translation["deDE"] = { ["Show Hots of all Classes"] = nil, ["Show Inactive Tracking"] = nil, ["Show Macro Text"] = nil, + ["Show Meters By Default"] = nil, ["Show Players Only"] = nil, ["Show Procs as Buff Indicators"] = nil, ["Show Procs of all Classes"] = nil, diff --git a/env/translations_enUS.lua b/env/translations_enUS.lua index b2f13ec0..06a6a1c2 100644 --- a/env/translations_enUS.lua +++ b/env/translations_enUS.lua @@ -373,6 +373,7 @@ pfUI_translation["enUS"] = { ["Show Hots of all Classes"] = nil, ["Show Inactive Tracking"] = nil, ["Show Macro Text"] = nil, + ["Show Meters By Default"] = nil, ["Show Players Only"] = nil, ["Show Procs as Buff Indicators"] = nil, ["Show Procs of all Classes"] = nil, diff --git a/env/translations_esES.lua b/env/translations_esES.lua index 9df16d2f..9520e525 100644 --- a/env/translations_esES.lua +++ b/env/translations_esES.lua @@ -373,6 +373,7 @@ pfUI_translation["esES"] = { ["Show Hots of all Classes"] = "Mostrar Curación Periódica (HoTs) de Todas las Clases", ["Show Inactive Tracking"] = "Mostrar Rastreo Inactivo", ["Show Macro Text"] = "Mostrar Texto de Macro", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "Solamente Mostrar Jugadores", ["Show Procs as Buff Indicators"] = "Mostrar Ocurrencias aleatorias programadas (Procs) como Indicadores de Buffs", ["Show Procs of all Classes"] = "Mostrar Ocurrencias aleatorias programadas (Procs) de Todas las Clases", diff --git a/env/translations_frFR.lua b/env/translations_frFR.lua index 7cb5fd5e..5d84fb05 100644 --- a/env/translations_frFR.lua +++ b/env/translations_frFR.lua @@ -373,6 +373,7 @@ pfUI_translation["frFR"] = { ["Show Hots of all Classes"] = "Afficher les soins sur la durée de chaque classe", ["Show Inactive Tracking"] = nil, ["Show Macro Text"] = "Afficher le texte des macros", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "Afficher les joueurs uniquement", ["Show Procs as Buff Indicators"] = "Afficher les procs en tant qu'indicateur d'amélioration", ["Show Procs of all Classes"] = "Afficher les procs de chaque classe", diff --git a/env/translations_koKR.lua b/env/translations_koKR.lua index c93f78d6..6c946c88 100644 --- a/env/translations_koKR.lua +++ b/env/translations_koKR.lua @@ -373,6 +373,7 @@ pfUI_translation["koKR"] = { ["Show Hots of all Classes"] = "모든 클래스 핫버프 보기", ["Show Inactive Tracking"] = nil, ["Show Macro Text"] = "매크로 텍스트 표시", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "플레이어만 보기", ["Show Procs as Buff Indicators"] = "무기활성화버프 버프표시기에 보기", ["Show Procs of all Classes"] = "모든 클래스 무기활성화 버프 보기", diff --git a/env/translations_ruRU.lua b/env/translations_ruRU.lua index 18726a4a..58b8905c 100644 --- a/env/translations_ruRU.lua +++ b/env/translations_ruRU.lua @@ -373,6 +373,7 @@ pfUI_translation["ruRU"] = { ["Show Hots of all Classes"] = "Показать лечение со временем (HoT) всех классов", ["Show Inactive Tracking"] = "Показать неактивное отслеживание", ["Show Macro Text"] = "Показать текст макросов", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "Показать только игроков", ["Show Procs as Buff Indicators"] = "Показать проки (Procs) как индикаторы баффов", ["Show Procs of all Classes"] = "Показать проки (Procs) всех классов", diff --git a/env/translations_zhCN.lua b/env/translations_zhCN.lua index e06f9c51..6e714d78 100644 --- a/env/translations_zhCN.lua +++ b/env/translations_zhCN.lua @@ -373,6 +373,7 @@ pfUI_translation["zhCN"] = { ["Show Hots of all Classes"] = "显示所有职业的Hot", ["Show Inactive Tracking"] = "显示已激活的追踪图标", ["Show Macro Text"] = "显示宏的名字", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "仅显示自己", ["Show Procs as Buff Indicators"] = "在框架的Buff指示器显示触发效果", ["Show Procs of all Classes"] = "显示所有职业的触发效果", diff --git a/env/translations_zhTW.lua b/env/translations_zhTW.lua index c94f5c1f..0d015606 100644 --- a/env/translations_zhTW.lua +++ b/env/translations_zhTW.lua @@ -373,6 +373,7 @@ pfUI_translation["zhTW"] = { ["Show Hots of all Classes"] = "顯示所有職業的Hot", ["Show Inactive Tracking"] = nil, ["Show Macro Text"] = "顯示巨集的名字", + ["Show Meters By Default"] = nil, ["Show Players Only"] = "僅顯示自己", ["Show Procs as Buff Indicators"] = "在框架的Buff指示器顯示觸發效果", ["Show Procs of all Classes"] = "顯示所有職業的觸發效果", diff --git a/modules/gui.lua b/modules/gui.lua index eb1244d5..6468a169 100644 --- a/modules/gui.lua +++ b/modules/gui.lua @@ -1199,6 +1199,7 @@ pfUI:RegisterModule("gui", function () pfUI.gui.tabs.thirdparty.tabs.general = pfUI.gui.tabs.thirdparty.tabs:CreateTabChild(T["Thirdparty"], true) pfUI.gui.tabs.thirdparty.tabs.general:SetScript("OnShow", function() if not this.setup then + CreateConfig(nil, this, T["Show Meters By Default"], C.thirdparty, "showmeter", "checkbox") CreateConfig(nil, this, T["Use Chat Colors for Meters"], C.thirdparty, "chatbg", "checkbox") CreateConfig(nil, this, T["DPSMate (Skin)"], C.thirdparty.dpsmate, "skin", "checkbox") CreateConfig(nil, this, T["DPSMate (Dock)"], C.thirdparty.dpsmate, "dock", "checkbox") diff --git a/modules/thirdparty.lua b/modules/thirdparty.lua index 95f88ab2..bcac7d3b 100644 --- a/modules/thirdparty.lua +++ b/modules/thirdparty.lua @@ -580,4 +580,17 @@ pfUI:RegisterModule("thirdparty", function () end end end) + + -- toggle meter by default if configured + if C.thirdparty.ktm.dock == "1" or C.thirdparty.dpsmate.dock == "1" or C.thirdparty.swstats.dock == "1" then + if C.thirdparty.showmeter == "1" then + local f = CreateFrame("Frame") + f:RegisterEvent("PLAYER_ENTERING_WORLD") + f:SetScript("OnEvent", function() + pfUI.thirdparty.meters.state = false + pfUI.thirdparty.meters:Toggle() + this:UnregisterAllEvents() + end) + end + end end)