--{{{ Libraries
local L = GridStatusHotsLocale
--}}}
...
local GridStatusHots = Grid:GetModule("GridStatus"):NewModule("GridStatusHots", "AceTimer-3.0")
...
function GridStatusHots:OnEnable()
if not GridRoster then
RL = AceLibrary("Roster-2.1")
end
if self.TimerSet == true then
self.CancelTimer(self.UpdateTimer, true)
end
self.UpdateTimer = self:ScheduleRepeatingTimer("UpdateAll", GridStatusHots.db.profile.frequency)
self.TimerSet = true
-- self:ScheduleRepeatingEvent("GHS_Refresh", self.UpdateAll, GridStatusHots.db.profile.frequency, self)
end
function GridStatusHots:UpdateFrequency()
if self.TimerSet == true then
self.CancelTimer(self.UpdateTimer, true)
end
self.UpdateTimer = self:ScheduleRepeatingTimer("UpdateAll", GridStatusHots.db.profile.frequency)
self.TimerSet = true
end
New File - GSHLocale-enUS.lua
local L = {}
L["Check, if you want to see a countdown for your Flash of Light - HoT behind your Sacred Shield (i.e. 25-10)"] = "Check, if you want to see a countdown for your Flash of Light - HoT behind your Sacred Shield (i.e. 25-10)"
L["Show Flash of Light - HoT"] = "Show Flash of Light - HoT"
L["Check, if you want to see the total of HoTs behind the countdown of your HoT(i.e. 13-5)"]="Check, if you want to see the total of HoTs behind the countdown of your HoT(i.e. 13-5)"
L["Show HoT-Counter"] = "Show HoT-Counter"
L["Check, if you want each stack of Lifebloom to count as 1 HoT"]="Check, if you want each stack of Lifebloom to count as 1 HoT"
L["Count Lifebloom as 1 HoT per stack"] = "Count Lifebloom as 1 HoT per stack"
L["Seconds between status refreshes"] = "Seconds between status refreshes"
L["Refresh frequency"] = "Refresh frequency"
L["Color 6"] = "Color 6"
L["Color 5"] = "Color 5"
L["Color 4"] = "Color 4"
L["Color 3"] = "Color 3"
L["Color 2"] = "Color 2"
L["Threshold to activate color 3"] = "Threshold to activate color 3"
L["Threshold to activate color 2"] = "Threshold to activate color 2"
L["Color when player has three charges of grace."] = "Color when player has three charges of grace."
L["Color when player has two charges of grace."] = "Color when player has two charges of grace."
L["Color when player has 5 or more charges of Earth Shield."] = "Color when player has 5 or more charges of Earth Shield."
L["Color when player has 4 charges of Earth Shield."] = "Color when player has 4 charges of Earth Shield."
L["Color when player has 3 charges of Earth Shield."] = "Color when player has 3 charges of Earth Shield."
L["Color when player has 2 charges of Earth Shield."] = "Color when player has 2 charges of Earth Shield."
L["Color when player has six charges of PoM."] = "Color when player has six charges of PoM."
L["Color when player has five charges of PoM."] = "Color when player has five charges of PoM."
L["Color when player has four charges of PoM."] = "Color when player has four charges of PoM."
L["Color when player has three charges of PoM."] = "Color when player has three charges of PoM."
L["Color when player has two charges of PoM."] = "Color when player has two charges of PoM."
L["Hots: My Grace Duration + Stack"] = "Hots: My Grace Duration + Stack"
L["Hots: My Grace Stack"] = "Hots: My Grace Stack"
L["Hots: My Beacon of Light"] = "Hots: My Beacon of Light"
L["Hots: My Prayer of Mending"] = "Hots: My Prayer of Mending"
L["Hots: My Flash of Light"] = "Hots: My Flash of Light"
L["Hots: My Earthliving"] = "Hots: My Earthliving"
L["Hots: My Riptide"] = "Hots: My Riptide"
L["Hots: My Sacred Shield"] = "Hots: My Sacred Shield"
L["Hots: My Sheath of Light"] = "Hots: My Sheath of Light"
L["Hots: My Wild Growth"] = "Hots: My Wild Growth"
L["Hots: My Lifebloom Stack Colored"] = "Hots: My Lifebloom Stack Colored"
L["Hots: My Lifebloom"] = "Hots: My Lifebloom"
L["Hots: My Regrowth"] = "Hots: My Regrowth"
L["Hots: My Rejuvenation"] = "Hots: My Rejuvenation"
L["Hots: My Renew"] = "Hots: My Renew"
L["Hots: My Gift of the Naaru"] = "Hots: My Gift of the Naaru"
L["Hots: My Earth Shield"] = "Hots: My Earth Shield"
L["Hots: Hot Count"] = "Hots: Hot Count"
L["My HoTs"] = "My HoTs"
GridStatusHotsLocale = L
File - GridStatusHots.toc
GSHLocale-enUS.lua --GridStatusHots_locale.lua
Deleted File - GridStatusHots_locale.lua
I can't access the repository from my work so if someone wants to verify my work and submit the changes go for it... it's working for me at the moment on my druid w/o any errors.
Thanks for all the hard work guys, but when I enable GridStatusHots, along with the suggested changes to the files, it doesn't show up in the status indicators, nor is there a checkbox for gridstatushots in the "debug" window.
Thanks for all the hard work guys, but when I enable GridStatusHots, along with the suggested changes to the files, it doesn't show up in the status indicators, nor is there a checkbox for gridstatushots in the "debug" window.
Would love some help!
I'm not sure if you have done it, but I have the Alpha of Grid installed (along with alphas of my other modules).
Outside of that I'll attach a zip of my entire folder for you to use. Again, I've never touched lua or any ace addons before so I make no long term guarantees :)
So MrHumpty, I should be able to download your zip file and replace my current GridStatusHots file and it should work? Sorry, I am not a programmer, and I'm very grateful that there are smart people like you guys to sort through all this stuff. :D
I erased my old post about the fix to the addon- it wasn't fixed!
But it is now.
Phanx- because there is no more AceOO, overriding SetIndicator/CreateIndicator requires some mangling of GridFrame.prototype. I tried doing it with metatables but that apparently causes tainting issues, because the contents of prototype are copied onto each GridFrame in InitializeFrame, and copying the metatable there causes securehandlers to bark.
Anyway, I'm attaching the zips of the two addons I have corrected so far- so far as I can. They both were using old AceConfig, and this is my first foray into lua, so I'm not 100% certain that they are feature complete- but they seem to work well enough.
The method I used to override is just a replacement. It looks like this:
local FrameOverride = {
super = {},
debug = false,
apply = function(self, onto)
for j,k in pairs(self) do
if self.debug then print( "might override ", j ) end
if not (j == "super" or j == "apply" or j == "debug" or j == debuginfo) then
if self.debug then print( "overriding ", j) end
self.super[j] = onto[j]
onto[j] = k
end
end
end,
}
...
function FrameOverride:SetIndicator(indicator, color, text, value, maxValue, texture, start, duration, stack)
FrameOverride.super.SetIndicator(self, indicator, color, text, value, maxValue, texture, start, duration, stack)
...
--at the end of file
FrameOverride:apply(GridFrame.prototype)
This seems to play nicely. However, can we maybe try something like passing in an indicator object? Current indicator addons insert directly into the indicator table, so maybe inserting something with some extra (smarter) callbacks or automatically passed overrides would be handy, so it feels less like we are contorting Grid and more like Grid is exposing its extension features.
ScheduleRepeatingEvent is no longer in ACEEvent. Can anybody advise me in getting that working again?
I'm hacking away here trying to get stuff working but in no way am I versed in lua or any of these libraries.
I'd like to think I need to find away to call ACE2's Event module which includes that method and functionality.
Any direction would be appreciated.
File-GridStatusHots.lua
New File - GSHLocale-enUS.lua
File - GridStatusHots.toc
Deleted File - GridStatusHots_locale.lua
I can't access the repository from my work so if someone wants to verify my work and submit the changes go for it... it's working for me at the moment on my druid w/o any errors.
instead of having to have them all typed out individually.
Would love some help!
Noted MSaint. I figured as I was doing it that there was a more efficient way to do it.
I'm not sure if you have done it, but I have the Alpha of Grid installed (along with alphas of my other modules).
http://www.wowace.com/addons/grid/files/ r1362.
Outside of that I'll attach a zip of my entire folder for you to use. Again, I've never touched lua or any ace addons before so I make no long term guarantees :)
A post coming soon has this and GridIndicatorCornerText fixed as well.
But it is now.
Phanx- because there is no more AceOO, overriding SetIndicator/CreateIndicator requires some mangling of GridFrame.prototype. I tried doing it with metatables but that apparently causes tainting issues, because the contents of prototype are copied onto each GridFrame in InitializeFrame, and copying the metatable there causes securehandlers to bark.
Anyway, I'm attaching the zips of the two addons I have corrected so far- so far as I can. They both were using old AceConfig, and this is my first foray into lua, so I'm not 100% certain that they are feature complete- but they seem to work well enough.
The method I used to override is just a replacement. It looks like this:
This seems to play nicely. However, can we maybe try something like passing in an indicator object? Current indicator addons insert directly into the indicator table, so maybe inserting something with some extra (smarter) callbacks or automatically passed overrides would be handy, so it feels less like we are contorting Grid and more like Grid is exposing its extension features.
Are you interested in direct assistance, Phanx?
I fixed the localization for all locales (or, at least, for enUS), and here's the post. It's working beautifully with cornerplus and cornertext. Yaay!
Next up, GridStatusHealthFade
no :(
Grid version r1362
Gridstatushots r142
Error Message? -> Ticket
Not in Auras, not in Debugging.
What version of Grid do you recommend?
Jamus, I can't wait to try yours tonight as well. Can you post your Zip file here for everyone? Thank you guys! :)