From 1766a587e1c5e3824e522572d45ff4b4416952ad Mon Sep 17 00:00:00 2001 From: Parnic Date: Fri, 5 Nov 2010 00:52:39 +0000 Subject: [PATCH] - changed the 'update period' slider to represent number of updates per second instead of seconds between updates. now higher is more frequent and lower is less frequent which makes more sense to users --- IceCore.lua | 2 +- IceHUD_Options/Options.lua | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/IceCore.lua b/IceCore.lua index a0a7b25..71bc61f 100644 --- a/IceCore.lua +++ b/IceCore.lua @@ -116,7 +116,7 @@ StaticPopupDialogs["ICEHUD_CONVERTED_TO_ACE3"] = StaticPopupDialogs["ICEHUD_UPDATE_PERIOD_MATTERS"] = { - text = L["Since the last time you updated IceHUD, many significant CPU and memory optimizations have been made. If bar animation looks jumpy to you, open the /icehud configuration page and lower the 'Update Period' slider. This will cause higher CPU usage but will look nicer. Enjoy IceHUD!"], + text = L["Since the last time you updated IceHUD, many significant CPU and memory optimizations have been made. If bar animation looks jumpy to you, open the /icehud configuration page and raise the 'Update Period' slider. This will cause higher CPU usage but will look nicer. Enjoy IceHUD!"], button1 = OKAY, timeout = 0, whileDead = 1, diff --git a/IceHUD_Options/Options.lua b/IceHUD_Options/Options.lua index 43971b9..51ec786 100644 --- a/IceHUD_Options/Options.lua +++ b/IceHUD_Options/Options.lua @@ -604,16 +604,16 @@ Expand "|cffffdc42Module Settings|r", expand PlayerInfo (or TargetInfo for targe updatePeriod = { type = 'range', name = L["Update Period"], - desc = L["Time between display updates in seconds"], + desc = L["Number of updates per second. The higher this number is, the smoother bars will animate. However, higher settings will also use more CPU, so balance it to your liking. 30 is the recommended setting."], get = function() - return IceHUD.IceCore:UpdatePeriod() + return math.ceil(1/IceHUD.IceCore:UpdatePeriod()) end, set = function(info, v) - IceHUD.IceCore:SetUpdatePeriod(v) + IceHUD.IceCore:SetUpdatePeriod(1/v) end, - min = 0, - max = 1, - step = 0.001, + min = 5, + max = 60, + step = 1, order = 97 },