View Single Post
07-01-18, 09:24 AM   #5
Lolzen
An Aku'mai Servant
 
Lolzen's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2008
Posts: 36
Originally Posted by runamonk View Post
I added support to my layout, granted it only works while not in combat which is all I wanted/needed. This will work for now until we can get a more correct way to do it.

Lua Code:
  1. local function PostCreateIcon(Auras, button)
  2.     button.count = mnkLibs.createFontString(button, mnkLibs.Fonts.ap, 10,  nil, nil, true)
  3.     button.count:ClearAllPoints()
  4.     button.count:SetPoint('TOPRIGHT', button, 0, 2)
  5.     button.timer = mnkLibs.createFontString(button, mnkLibs.Fonts.ap, 10,  nil, nil, true)
  6.     button.timer:ClearAllPoints()
  7.     button.timer:SetPoint('BOTTOMLEFT', button, 0, 0)
  8.     button.icon:SetTexCoord(.07, .93, .07, .93)
  9.     button:SetScript('OnClick', function(self, button) CancelUnitBuff('player', self:GetName():match('%d')) end)
  10.     mnkLibs.createBorder(button, 1,-1,-1,1, {0,0,0,1})
  11. end
Yes, that was what i had when i started tinkering with that idea, but i wanted to be able to cancel the buffs in combat too, hence why i'm exploring this

Originally Posted by lightspark View Post
Use runamonk's solution, it's good enough, just add InCombatLockdown check around CancelUnitBuff, and you're good to go.

Nah, simply because it's something that doesn't work all the time, but only works when you're out of combat.
See above
My solution kind of works in combat, however taints. The idea back the was to add a secure version, which isn't as flexible as the current implementation due to limitations.

Thanks for the answers guys, i'll try to find a solution and will probably miserably fail and give up - however iÄm grateful for the official statement, thanks!
  Reply With Quote