add options for time and fps

This commit is contained in:
Eric Mauser
2016-05-21 12:57:43 +02:00
parent 0bf37d7eba
commit c5f71be8aa
2 changed files with 18 additions and 5 deletions
+13
View File
@@ -33,6 +33,19 @@ pfUI:RegisterModule("panel", function ()
pfUI.panel:UpdateZone()
end
end)
pfUI.panel.clock = CreateFrame("Frame",nil,UIParent)
pfUI.panel.clock:SetScript("OnUpdate",function(s,e)
if not pfUI.panel.clock.tick then pfUI.panel.clock.tick = GetTime() - 1 end
if GetTime() >= pfUI.panel.clock.tick + 1 then
pfUI.panel.clock.tick = GetTime()
pfUI.panel:OutputPanel("time", date("%H:%M:%S"))
local _, _, lag = GetNetStats();
local fps = floor(GetFramerate());
pfUI.panel:OutputPanel("fps", floor(GetFramerate()) .. " fps & " .. lag .. " ms")
end
end);
-- Update "exp"
function pfUI.panel:UpdateExp ()
if UnitLevel("player") ~= 60 then
+5 -5
View File
@@ -87,13 +87,13 @@ pfUI_config = {
},
["panel"] = {
["left"] = {
left = "exp",
center = "friends",
right = "guild",
left = "guild",
center = "durability",
right = "friends",
},
["right"] = {
left = "durability",
center = "gold",
left = "fps",
center = "time",
right = "gold",
},
["other"] = {