Thread Tools Display Modes
06-04-21, 02:01 AM   #1
Johanan
A Deviate Faerie Dragon
Join Date: Jun 2021
Posts: 15
Friendly NamePlates

/run C_NamePlate.SetNamePlateFriendlySize(50,100) - how to make an addon out of this?

C_NamePlate.SetNamePlateFriendlySize(50,100) - i tried to insert this into my addon but it doesn't work

(retail)
  Reply With Quote
06-05-21, 02:47 AM   #2
Johanan
A Deviate Faerie Dragon
Join Date: Jun 2021
Posts: 15
Fix it
Code:
local myFrame = CreateFrame("Frame")
myFrame:HookScript("OnEvent",
  function()
    C_NamePlate.SetNamePlateFriendlySize(50,100)
  end
);
myFrame:RegisterEvent("PLAYER_LOGIN")
But they periodically stop working (return to their original state), what should I do?

Last edited by Johanan : 06-05-21 at 02:49 AM.
  Reply With Quote
06-05-21, 03:48 AM   #3
Dridzt
A Pyroguard Emberseer
 
Dridzt's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2005
Posts: 1,359
There's nothing you can do if they stop working inside instances.

That's a blizzard limitation imposed on addons.
  Reply With Quote
06-05-21, 04:05 AM   #4
Johanan
A Deviate Faerie Dragon
Join Date: Jun 2021
Posts: 15
Originally Posted by Dridzt View Post
There's nothing you can do if they stop working inside instances.

That's a blizzard limitation imposed on addons.
That is, is it better to use a macro?
  Reply With Quote
06-05-21, 02:12 PM   #5
Dridzt
A Pyroguard Emberseer
 
Dridzt's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2005
Posts: 1,359
Originally Posted by Johanan View Post
That is, is it better to use a macro?
Macro is the same as addon in this particular case.
Friendly nameplates simply ignore changes no matter the method (addon or macro) inside instances.

Blizzard has restricted the players ability to modify friendly nameplates in instances because they were used in bossmods that were deemed too powerful / trivializing content.

Similar to how API changes have been made in the past to camera API to prevent AVR, to unit position API etc.
  Reply With Quote
06-06-21, 09:41 AM   #6
Johanan
A Deviate Faerie Dragon
Join Date: Jun 2021
Posts: 15
Originally Posted by Dridzt View Post
Macro is the same as addon in this particular case.
Friendly nameplates simply ignore changes no matter the method (addon or macro) inside instances.

Blizzard has restricted the players ability to modify friendly nameplates in instances because they were used in bossmods that were deemed too powerful / trivializing content.

Similar to how API changes have been made in the past to camera API to prevent AVR, to unit position API etc.
That is, both with an addon and with a macro, they will return to their original state sometimes? And then you have to either reuse the macro, or write /reload to reboot the addon?
  Reply With Quote
06-06-21, 10:50 AM   #7
jeffy162
A Pyroguard Emberseer
 
jeffy162's Avatar
AddOn Author - Click to view addons
Join Date: May 2009
Posts: 2,364
No, he means that you can't do anything to nameplates, at all, when you are in an instance. Friendly OR enemy nameplates.
__________________
Ahhhh, the vagueries of the aging mind. Wait.... What was I saying?


Carbonite <----- GitHub main module (Maps ONLY) download link. The other modules are also available on GitHub.
Carbonite-CLASSIC<----- GitHub link to Carbonite Classic. Thanks to ircdirk for this!
  Reply With Quote
06-21-21, 09:42 AM   #8
rulezyx
A Flamescale Wyrmkin
 
rulezyx's Avatar
Join Date: Jan 2020
Posts: 106
I would recommend to use this addon: https://www.curseforge.com/wow/addon...dly-nameplates

or at least the code.

You can adjust the size as you want and theres space to set up other options.

Friendly nameplate addons do not work in dungeons but arenas.

There are limitations but the size will stay as set even in dungeons.

Most overall limitations are related to the anchors and timers, so addons cant mess around with setting up special timers/frames above nameplates while in combat.

The size will only resett by making changes to the cvar within the instance and for this example by pressing the cvar macro over and over.

Last edited by rulezyx : 06-21-21 at 09:46 AM.
  Reply With Quote
06-23-21, 04:55 AM   #9
Johanan
A Deviate Faerie Dragon
Join Date: Jun 2021
Posts: 15
Originally Posted by rulezyx View Post
or at least the code.
What code?
  Reply With Quote
06-30-21, 07:15 PM   #10
rulezyx
A Flamescale Wyrmkin
 
rulezyx's Avatar
Join Date: Jan 2020
Posts: 106
Originally Posted by Johanan View Post
What code?
Use the addon and it will do what you are looking for.

For more customization (size) you have to edit the values in the lua file of the addon (code).

Theres a description (green text) next to the values in the file.
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Friendly NamePlates

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