Quantcast

- Per #1322 (Retail) Add Buff frame adjust and show / hide Titan start / reload messages for Titan name and plugins registered.

urnati [12-11-21 - 15:04]
- Per #1322 (Retail) Add Buff frame adjust and show / hide Titan start / reload messages for Titan name and plugins registered.
Filename
TitanClassic/TitanClassicConfig.lua
TitanClassic/TitanClassicMovable.lua
TitanClassic/TitanClassicUtils.lua
TitanClassic/TitanClassicVariables.lua
diff --git a/TitanClassic/TitanClassicConfig.lua b/TitanClassic/TitanClassicConfig.lua
index 5ea48af..cb642c4 100644
--- a/TitanClassic/TitanClassicConfig.lua
+++ b/TitanClassic/TitanClassicConfig.lua
@@ -1707,33 +1707,96 @@ local optionsAdvanced = {
 	name = L["TITAN_PANEL_MENU_ADV"],
 	type = "group",
 	args = {
-		confdesc = {
+		conftimerdesc = {
+			name = "Timers",
+			type = "group", inline = true,
 			order = 1,
-			type = "description",
-			name = L["TITAN_PANEL_MENU_ADV_DESC"],
-			cmdHidden = true
+			args = {
+				confdesc = {
+					order = 10,
+					type = "description",
+					name = L["TITAN_PANEL_MENU_ADV_DESC"],
+					cmdHidden = true
+					},
+				advtimerpew = {
+					name = L["TITAN_PANEL_MENU_ADV_PEW"],
+					desc = L["TITAN_PANEL_MENU_ADV_PEW_DESC"],
+					order = 20, type = "range", width = "full",
+					min = 1, max = 10, step = 0.5,
+					get = function() return TitanAllGetVar("TimerPEW") end,
+					set = function(_, a)
+						TitanAllSetVar("TimerPEW", a);
+						TitanTimers["EnterWorld"].delay = a
+					end,
+				},
+				advtimervehicle = {
+					name = L["TITAN_PANEL_MENU_ADV_VEHICLE"],
+					desc = L["TITAN_PANEL_MENU_ADV_VEHICLE_DESC"],
+					order = 50, type = "range", width = "full",
+					min = 1, max = 10, step = 0.5,
+					get = function() return TitanAllGetVar("TimerVehicle") end,
+					set = function(_, a)
+						TitanAllSetVar("TimerVehicle", a);
+						TitanTimers["Vehicle"].delay = a
+					end,
+				},
 			},
-		advtimerpew = {
-			name = L["TITAN_PANEL_MENU_ADV_PEW"],
-			desc = L["TITAN_PANEL_MENU_ADV_PEW_DESC"],
-			order = 10, type = "range", width = "full",
-			min = 1, max = 10, step = 0.5,
-			get = function() return TitanAllGetVar("TimerPEW") end,
-			set = function(_, a)
-				TitanAllSetVar("TimerPEW", a);
-				TitanTimers["EnterWorld"].delay = a
-			end,
 		},
-		advtimervehicle = {
-			name = L["TITAN_PANEL_MENU_ADV_VEHICLE"],
-			desc = L["TITAN_PANEL_MENU_ADV_VEHICLE_DESC"],
-			order = 50, type = "range", width = "full",
-			min = 1, max = 10, step = 0.5,
-			get = function() return TitanAllGetVar("TimerVehicle") end,
-			set = function(_, a)
-				TitanAllSetVar("TimerVehicle", a);
-				TitanTimers["Vehicle"].delay = a
-			end,
+		confbuffdesc = {
+			name = "Buff Icon Vertical Adjustment",
+			type = "group", inline = true,
+			order = 2,
+			args = {
+				confbuffdesc = {
+					order = 110,
+					type = "description",
+					name = "Adjust Buff icons only as needed. This will override the Titan default adjustment.", --L["TITAN_PANEL_MENU_ADV_DESC"],
+					cmdHidden = true
+					},
+				advbuffadj = {
+					name = "Buff", --L["TITAN_PANEL_MENU_ADV_PEW"],
+					desc = "", -- L["TITAN_PANEL_MENU_ADV_PEW_DESC"],
+					order = 120, type = "range", width = "full",
+					min = -100, max = 100, step = 1,
+					get = function() return TitanPanelGetVar("BuffIconVerticalAdj") end,
+					set = function(_, a)
+						TitanPanelSetVar("BuffIconVerticalAdj", a);
+						-- Adjust frame positions
+						TitanPanel_AdjustFrames(true, "BuffIconVerticalAdj")
+					end,
+				},
+			},
+		},
+		confoutputdesc = {
+			name = "Output",
+			type = "group", inline = true,
+			order = 3,
+			args = {
+				confdesc = {
+					order = 110,
+					type = "description",
+					name = "Output Various Titan Info At Startup or Reload.", --L["TITAN_PANEL_MENU_ADV_DESC"],
+					cmdHidden = true
+					},
+				advname = {
+					name = "Name and Version", --L["TITAN_PANEL_MENU_ADV_PEW"],
+					desc = "Show name and version in Chat", -- L["TITAN_PANEL_MENU_ADV_PEW_DESC"],
+					order = 120, type = "toggle", width = "full",
+					get = function() return not TitanAllGetVar("Silenced") end, -- yes, we did it to ourselves...
+					set = function(_, a)
+						TitanAllSetVar("Silenced", not a);
+					end,
+				},
+				advplugins = {
+					name = "Registration process", --L["TITAN_PANEL_MENU_ADV_PEW"],
+					desc = "Show Registration start and number of registered plugins", -- L["TITAN_PANEL_MENU_ADV_PEW_DESC"],
+					order = 130, type = "toggle", width = "full",
+					get = function() return TitanAllGetVar("ShowRegistered") end,
+					set = function(_, a)
+						TitanAllSetVar("ShowRegistered", a);
+					end,
+				},
+			},
 		},
 	},
 }
diff --git a/TitanClassic/TitanClassicMovable.lua b/TitanClassic/TitanClassicMovable.lua
index 6b9900f..2126af9 100755
--- a/TitanClassic/TitanClassicMovable.lua
+++ b/TitanClassic/TitanClassicMovable.lua
@@ -491,7 +491,7 @@ local MData = {
 			then
 				yOffset = (-TicketStatusFrame:GetHeight())
 			else
-				yOffset = -13
+				yOffset = TitanPanelGetVar("BuffIconVerticalAdj")  --  -13
 			end
 			MoveFrame("BuffFrame", yOffset, TITAN_PANEL_PLACE_TOP, force) end,
 		addonAdj = false, },
diff --git a/TitanClassic/TitanClassicUtils.lua b/TitanClassic/TitanClassicUtils.lua
index f34582a..d26c8c4 100644
--- a/TitanClassic/TitanClassicUtils.lua
+++ b/TitanClassic/TitanClassicUtils.lua
@@ -1662,17 +1662,21 @@ function TitanUtils_RegisterPluginList()
 	local id
 	local cnt = 0
 	if TitanPluginToBeRegisteredNum > 0 then
-		if not Titan__InitializedPEW and not TitanAllGetVar("Silenced") then
-			TitanDebug(L["TITAN_PANEL_REGISTER_START"], "normal")
+		if not Titan__InitializedPEW then
+			if TitanAllGetVar("ShowRegistered") then
+				TitanPrint(L["TITAN_PANEL_REGISTER_START"], "normal")
+			end
 		end
 		for index, value in ipairs(TitanPluginToBeRegistered) do
 			if TitanPluginToBeRegistered[index] then
-				TitanUtils_RegisterPlugin(TitanPluginToBeRegistered[index])
+					TitanUtils_RegisterPlugin(TitanPluginToBeRegistered[index])
 			end
 			cnt = cnt + 1
 		end
-		if not Titan__InitializedPEW and not TitanAllGetVar("Silenced") then
-			TitanDebug((L["TITAN_PANEL_REGISTER_END"].." "..cnt), "normal")
+		if not Titan__InitializedPEW then
+			if TitanAllGetVar("ShowRegistered") then
+				TitanPrint((L["TITAN_PANEL_REGISTER_END"].." "..cnt), "normal")
+			end
 		end
 	end
 end
diff --git a/TitanClassic/TitanClassicVariables.lua b/TitanClassic/TitanClassicVariables.lua
index e27f828..44b2f4b 100644
--- a/TitanClassic/TitanClassicVariables.lua
+++ b/TitanClassic/TitanClassicVariables.lua
@@ -277,6 +277,7 @@ TITAN_PANEL_SAVED_VARIABLES = {
 	AuxBar2_Transparency = 0.7,
 	AuxBar2_Align = TITAN_PANEL_BUTTONS_ALIGN_LEFT,
 	MainMenuBarXAdj = 0,
+	BuffIconVerticalAdj = -13,
 };

 --[[ Titan
@@ -296,6 +297,7 @@ TITAN_ALL_SAVED_VARIABLES = {
 	Silenced = false,
 	-- OrderHallCommandBar Status
 	--OrderHall = true,
+	ShowRegistered = true,
 };

 -- The skins released with Titan