oUF

97.2k Downloads

Target nameplate colored

pedrozc90 opened this issue ยท 0 comments

commented

Hello.

I not really sure if this is suggestion or just asking for help.

Describe the solution you'd like
I use oUF to style nameplates, and I would like to set a specific color to the nameplate which is my current target.
Perhaps by adding an option to health element like health.colorTarget = oUF:CreateColor(1.00, 1.00, 1.00) would work?
When UnitIsUnit("nameplate%d", "target") == true, the colorTarget would be applied, overriding other colors such as colorThread, colorReaction, etc.

Describe alternatives you've considered
I have tried a few different approaches without success:

  1. I tried using .PostUpdateColor, but it seems the health element does not listen to PLAYER_TARGET_CHANGED event. While the color change when I target the nameplate, it does not change back when I switch targets.
  2. The nameplate callback function listens to PLAYER_TARGET_CHANGED event. However, the color does not revert when switching targets.

If its possible to implement this behavior on the current version, I would appreciate an explanation of how can I achieve it.

Thank you