Flashy name for nearby guild mates - Page 2 - WoWInterface
Thread Tools Display Modes
05-03-21, 03:30 PM   #21
nUI Maintainer
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,638
Just put it before the if guildie line to include the others. But you will then have to move the line starting with local nameplate = to the same place so you can access the nameplate object.

So instead of ..
Lua Code:
  1. if guildie[guid] then
  2.             PlaySound(416)
  3.             local nameplate = C_NamePlate.GetNamePlateForUnit(unit)
  4.             nameplate.UnitFrame.name:SetTextColor(1,1,1,1)
  5.             nameplate.UnitFrame.healthBar:Hide()
  6.             print(name)
  7.         end

It should look like this..
Lua Code:
  1. local nameplate = C_NamePlate.GetNamePlateForUnit(unit)
  2.         nameplate.UnitFrame.healthBar:Hide()
  3.         if guildie[guid] then
  4.             PlaySound(416)
  5.             nameplate.UnitFrame.name:SetTextColor(1,1,1,1)
  6.             print(name)
  7.         end

This essentially hides the healthbar immediately when they first are shown ( but wow may show it again during its update routine ) and then does the guildie check before setting the text color and playing the sound if it is a guildie.
  Reply With Quote
05-03-21, 06:38 PM   #22
An Aku'mai Servant
Yukka's Avatar
Join Date: Feb 2020
Posts: 32
Thanks it works like a charm!

I think the addon is complete now. Hope people will see this and use it as well to hug their guildies

kisses to you Xrystal, Kanegasi and the others <3
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » Flashy name for nearby guild mates

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off