View Single Post
11-19-19, 02:04 PM   #11
Mandraxon
A Fallenroot Satyr
AddOn Author - Click to view addons
Join Date: Jul 2009
Posts: 21
Originally Posted by SDPhantom View Post
To isolate the adjustment to only when the name is showing, we'll just semi-recreate the original function managing the buff container.
Lua Code:
  1. hooksecurefunc(NameplateBuffContainerMixin,"UpdateAnchor",function(self)
  2.     local parent=self:GetParent();
  3.     local unit=parent.unit;
  4.  
  5.     if unit and ShouldShowName(parent) then
  6. --      Replicate the calculation of the original function
  7.         local offset=self:GetBaseYOffset()+((unit and UnitIsUnit(unit,"target")) and self:GetTargetYOffset() or 0);
  8.         self:SetPoint("BOTTOM",parent,"TOP",0,offset);--    Apply offset here
  9.     end--   We'll leave the false side of this alone to preserve the original anchor in that case
  10. end);


dude thats awsome.
You are a true star.

i used to use flyplate debuffs and it had a toggle to show names on untracked nameplates (se image )
I need to be able to scale the debuffs to match the style better

Thanks for all the work man.. making my UI be how i want it to be.



as you can se, only the targeted nameplate has text.
i can fix it with the tracking function in wow.. but then i get names shwoing where i dont.
in FlyPlates i had a function to --fix nameplates without names like the dummys in the image.

anyhow.
Thanx for the aid.
  Reply With Quote