Originally Posted by myrroddin
You need two things: - https://wow.gamepedia.com/API_UnitReaction in which case the unitID ("player") and the unitID of the comparison.
- The global table FACTION_BAR_COLORS in which to pass the reaction number above.
Lua Code:
local reaction = UnitReaction("target", "player") local reactionColor = FACTION_BAR_COLORS[reaction]
|
Thanks for the code.
I ended up using it like below and it works fine:
Lua Code:
local reaction = UnitReaction("target", "player")
local color = CUSTOM_FACTION_BAR_COLORS[reaction] or RAID_CLASS_COLORS[ccolor] or {r = 1, g = 1, b = 0}
So thanks again.
Coke