This Event appers to have two ...arguments?.. associated with it. "arg1" is theunitname, "player" "target" etc. But I'm not sure what the arg2 number represents. I've got values from 0 to 100, 75, 64, 11598, etc....Can't seem to find any correlation between the change in buffs and arg2.
I'm trying to work on an addon to count the number of times a particular buff is received. I have a simple frame registered to the UNIT_BUFF_CHANGED event, and when arg1 is "player", I scan through player buffs to increment a counter. The problem is that this event fires multiple times, and for a single count, I end up with a counter value of 16+.
I'm currently playing with UnitBuffLeftTime > X to try to get only a single count for a given event. There's a limitation to this though....if an unrelated buff gets applied/refreshed while time > X, you still get multiple counts.
But I was hoping there was a simpler way, maybe through some global variable associated with the UNIT_BUFF_CHANGED event (like how _source and _target are related to COMBATMETER_DAMAGE event).
EDIT: It occurred to me that I can just use the combat log message event rather than going through the buff bar, but question about buff-related global vars still remains.
This post has been edited 3 times, last edit by "BlankMinded" (Oct 25th 2016, 9:46pm)