CooldownIcons R(evamped)
Description
CIR is a cooldown-customization tool controlled by user input and various settings.
List of script commands can be found under help ingame.
Working process
Currently working on
- Tickets
- TODO List
upcoming features
- deletion
- grouping
- fake cooldowns
- pulse, and some more cosmetic things
currently please use "/cir" to show options - the blizz option thingie is coming later
Special thanks
Enkidu - Thanks for bugs/tickets & feedback
Most up-to-date version, but also alpha ones can be found on here.
Got some nice setup? I need some pictures/records to show of capacity/many things of CIR.
Send me a PM with a link to your screenshot (part-screen or full-screen doesn't matter)
Setups send to me can be found here.
if not_on_cooldown && holy_power > 2 then
grayscaleOff()
else
grayscaleOn()
end
Check Script command list for command that you can use. Either from website that provide under description or check help section inside addon.
local function SpellOnCooldown(name)
CIR:RegisterObjForEvent(f,"SPELL_UPDATE_COOLDOWN")
local _,duration = GetSpellCooldown(name)
if duration and duration>2 then
return true
else
return false
end
end
spell("Avenger's Shield")
if SpellOnCooldown("Avenger's Shield") then
GrayscaleOn()
else
GrayscaleOff()
end
I got some issue today when setting up Holy word Chastise.
if PlayerBuff("Chakra: Heal") or PlayerBuff("Chakra: Renew") or PlayerBuff("Chakra: Prayer of Healing") then
spell(88625)
else
spell(14751)
end
Chakra spell display just some place holder. Since I want to display something instead of fade out. Problem occur after I gain Chakra buff. Cooldown on that icon is still Chakra's CD. Icon changed to Holy word chastise but grayscale function no longer work.
After testing around. I figure out problem is mostly related to Holy Word: Chastise. that spell's CD does work if I use it as damage spell. But after Chakra change that spell's function. CD timer no longer work.
Also that CD timer stay on old spell's CD occur at talent group change too. So it will be good to implement a function to reset it or add something in code to reset CD after change to new spell.
And ResetGrayscale function doesn't work for me. Bug capture: CIREnv.lua:187: attempt to call method 'ResetGrayscale' (a nil value). I place that function after detect chakra buff and before change spell.
Under "local function updaterFunc(self, elapsed)"
Change code
///
if not CIR.db.char.gMisc.gFixGCD then
startT[obj], durationT[obj] = CooldownByCmd(icon.watch,icon.type)
end
///
TO
///
local start,duration = CooldownByCmd(icon.watch,icon.type)
if not CIR.db.char.gMisc.gFixGCD then
startT[obj]=start
durationT[obj]=duration
end
if durationT[obj]>0 then
if (startT[obj]+durationT[obj]) ~= (start+duration) then
startT[obj]=start
durationT[obj]=duration
end
end
/////
What it does is give one more condition to check if there is old cooldown. If true, then check whether new Cooldown's end time is same to old Cooldown's end time. If not. Update cooldown Info. Because old start time + duration should be always same to new Cooldown start time + duration.
cool addon! :) can u allow all the API commands in the code?
http://www.wowwiki.com/World_of_Warcraft_API
would be nice to set something like
IsUsableSpell("...") in a case, to check for the spell is able to use in cause of procs or sth...
or is it possible atm? i wanted to set an overpower icon, but i cannot enter a active-condition...
greetz kewl
btw n1 code, its readable :)
--SetDisplay, to handle displayType
local fadingTime=0.2
local function SetDisplay(self,bOnCooldown)
i set the fading time down, cause in some cases the spells have very small cooldowns (3 sec or so e.g. heroic strike), there would be confusing to put a fading time to 2.5seconds. perhaps u could make the fading time enter via config menu
just some suggestions :)
gw
greetz kewl
i gonna write up some examples (especially complicated ones) so that things should be clear \\
but all in all it's really simple if-then-else clauses except you have to remember to close them correctly and stuff \\
auto-completion / lego-like coding is a way far away feature
hope it helps
"Hand of Freedom" is