Minion Beta! - Help us test our new AddOn updater. Get it now!
Download
(34 Kb)
Download
Updated: 12-30-14 09:57 AM
Pictures
File Info
Compatibility:
Warlords of Draenor (6.0.3)
Updated:12-30-14 09:57 AM
Created:08-21-13 05:56 PM
Downloads:5,625
Favorites:45
MD5:

rNamePlates (Diablo)  Popular! (More than 5000 hits)

Version: 60000.09
by: zork [More]


INTRO

rNamePlates replaces the default name plates with a Diablo themed high FPS counterpart.
Based up on this: Nameplate FPS drop research
AURAS
rNamePlates supports auras. Auras are tracked for "player" and "pet" and saved in a spell-database per character. To administrate the spell-database check the slash commands.
SLASH COMMANDS
lua Code:
  1. /rnp -- shows all commands
  2. /rnp list -- shows all entries of spelldb for this character
  3. /rnp blacklist SPELLID -- blacklists a certain SPELLID in spelldb for this character
  4. /rnp whitelist SPELLID -- whitelists a certain SPELLID in spelldb for this character
  5. /rnp remove SPELLID -- removes a certain SPELLID from spelldb for this character
  6. /rnp disable -- disable the spelldb for this character
  7. /rnp enable -- enable the spelldb for this character
  8. /rnp resetspelldb -- reset the spelldb for this character

CONFIG
Small config on top of the rNamePlates.lua. Not much. Most of the stuff is hardcoded.
SVN
http://code.google.com/p/rothui/sour...0/rNamePlates/

60000.09
- healthbar colors now match faction colors
- color onupdate function throttled

60000.08
- hide default healthbar
- hide default castbar
- hide threat glow
- create new healthbar
- create new castbar
- added TANKMODE healthbar coloring

60000.07
- Added new command "disable" to disable the spellDB per character
- Added new command "enable" to enable the spellDB per character
- Remove obsolete checks for ScanAura
- Code cleanup

60000.06
- fixed the poor GUID handling

60000.05
- changed loading event to ADDON_LOADED
- fixed rNP_SPELL_DB = nil error

60000.04
- Loading SavedVariables with VARIABLES_LOADED event instead of ADDON_LOADED
- Added more spellDB checks
- Removed spellDB wipe on new WoW build
- Added new command "remove" to remove a spell from spellDB
- Renamed command "spelldb" to "list"

60000.03
- added auras to rNamePlates
- added slash commands to manage tracked auras

60000.02
- code cleanup

60000.01
- new nameplates for wod 6.0.2

50400.01
- added healthbar faction coloring
- updated toc to 50400

50300.04
- Added the threat bloat fix

50300.03
- changed the threat glow to a threat border around the healthbar

50300.02
- code cleanup/overhaul
- added 2 new statusbar textures to pick from

50300.01
- initial release
Optional Files (0)


Archived Files (10)
File Name
Version
Size
Author
Date
60000.08
33kB
zork
12-27-14 10:31 AM
60000.07
33kB
zork
11-10-14 12:16 PM
60000.06
33kB
zork
11-08-14 11:57 AM
60000.02
30kB
zork
10-24-14 07:51 PM
60000.01
30kB
zork
10-18-14 09:27 AM
50400.01
16kB
zork
09-16-13 04:39 AM
50300.04
16kB
zork
09-07-13 04:33 AM
50300.03
16kB
zork
08-24-13 08:10 PM
50300.02
50kB
zork
08-23-13 12:33 PM
50300.01
11kB
zork
08-21-13 05:56 PM


Post A Reply Comment Options
Unread 01-14-15, 01:50 AM  
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1408
File comments: 3449
Uploads: 90
No your solution sounds like the correct one.

WoW was first developed with 1024x768 pixels in mind.

Check
http://www.wowinterface.com/forums/s...ad.php?t=31813
and http://www.wowinterface.com/download...-UIScaler.html

Pixel perfection is kind of an complicated topic if you want to add it afterwards since you need to re-iterate all your values.

Additionally the nameplates live on the "WorldFrame" that frame may not factor in UIScale like "UIParent" does.

Basically I think you could use an inset of 1 if you you set your nameplate scale to 768/1050. I would not fiddle with the WorldFrame scale!

Btw my newPlate is just a simple square. I use as a base-frame that will center itself on the Blizzard nameplate.

Here is where I set the newPlate size:
https://code.google.com/p/rothui/sou...Plates.lua#450

Here is where the blizzPlate movement is triggered. There is a hidden frame that will change its size and trigger the event.
https://code.google.com/p/rothui/sou...Plates.lua#341

Best of luck.
__________________
| Simple is beautiful.
| Roth UI | Roth UI FAQ | GoogleCode | Zork | TDMOG

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
Last edited by zork : 01-14-15 at 01:59 AM.
zork is offline Report comment to moderator  
Reply With Quote
Unread 01-13-15, 10:28 PM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
I ended up just saying fuck it and did this:

I figured it was due to worldframe being 1366x768 and my monitor being 1920x1080. 768/1080 = 32/45, so I just set all the insets on the backdrop to 32/45 instead of 1. Shitty solution, but effective.
Last edited by sirann : 01-14-15 at 07:04 AM.
sirann is online now Report comment to moderator  
Reply With Quote
Unread 01-13-15, 07:17 PM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
I've tried math.floor(x) and math.floor(y) on blizzPlate.newPlate:SetPoint('CENTER', WorldFrame, 'BOTTOMLEFT', math.floor(x), math.floor(y))

uiscale in my escape > system > option is OFF, as none of my others addons have this issue (although none of my other addons are parented to WorldFrame lol. The addon's scale is set to 1. I have the size set to 130, 10, so I can't see any way why the issue is still, well, an issue. Any insight would be appreciated. I've looked at kuinameplates code for its pixel perfection, and it's got:
Lua Code:
  1. local w,h = f:GetSize()
  2. if f.trivial then
  3.     f.x = floor((w / 2) - (addon.sizes.frame.twidth / 2))
  4.     f.y = floor((h / 2) - (addon.sizes.frame.theight / 2))

when I attempted to put
Lua Code:
  1. local w, h = blizzPlate.newPlate:GetSize()
  2. print(w, h)

it would print out like 37 and 42 regardless of how ridiculously tall or wide I made the frame.

I'm quite unsure what's going on at this point, but the nameplate still doesn't fit in the backdrop with a 1 pixel border at all times. Any ideas or help would be cool.
sirann is online now Report comment to moderator  
Reply With Quote
Unread 01-13-15, 10:55 AM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
You sir, are a gentleman and a scholar. I'll try this out when I get home. Will post back when I get them functioning. If I can get this functioning, I'll probably attempt to implement some threat/target/mouseover coloring with the backdrop, red for threat (revert the name color change), white for target, and blue for mouseover. We'll see!
sirann is online now Report comment to moderator  
Reply With Quote
Unread 01-13-15, 01:44 AM  
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1408
File comments: 3449
Uploads: 90
No that's awesome. I want people to write their own additions and get into making their own stuff.

Regarding the backdrop. If a gradient would be ok you could use the backdrop I use here:
http://www.wowinterface.com/download...UF_Simple.html

For pixel perfect frames you need to first make sure your UIScale supports pixel perfection. Thus your nameplates need to use the same scale as your other frames. Next you need to make sure to never use non-floored setpoints for your nameplate. This https://code.google.com/p/rothui/sou...Plates.lua#348 has to become
Lua Code:
  1. blizzPlate.newPlate:SetPoint("CENTER", WorldFrame, "BOTTOMLEFT", math.floor(x), math.floor(y)) -- Immediately reposition frame

Pixel perfection has to be done in first place. You probably need to change the scale and all sizes of your nameplate to achieve it.
__________________
| Simple is beautiful.
| Roth UI | Roth UI FAQ | GoogleCode | Zork | TDMOG

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
Last edited by zork : 01-13-15 at 01:52 AM.
zork is offline Report comment to moderator  
Reply With Quote
Unread 01-12-15, 10:42 PM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
You're probably going to hate me, I've done some modifications to the code. I play a rogue, so I DO need to know when I have aggro on things, but I didn't really like the healthbarcolor change you have.

Additionally, since I am a rogue, assassination at that, I wanted the nameplates to change colors to orange when targets are below 35% health. I've altered the following function: NamePlateHealthBarColor to:
Lua Code:
  1. local _, healthmaxval, healthcurval
  2. local FACTION_BAR_COLORS = FACTION_BAR_COLORS
  3. local levelcolor = {}
  4. local function NamePlateHealthBarColor(blizzPlate)
  5.     if blizzPlate.threatTexture:IsShown() then
  6.         local r, g, b = blizzPlate.threatTexture:GetVertexColor()
  7.         local name = blizzPlate.nameString:GetText() or 'Unknown'
  8.         local level = blizzPlate.levelString:GetText() or '-1'
  9.         levelcolor = GetQuestDifficultyColor(level)
  10.         if g + b == 0 then
  11.             blizzPlate.newPlate.healthBar.name:SetFormattedText('|cff%02x%02x%02x%s '..'|cffb40000%s', levelcolor.r*255, levelcolor.g*255, levelcolor.b*255, level, name)--tank mode
  12.         else
  13.             blizzPlate.newPlate.healthBar:SetStatusBarColor(r, g, b)
  14.         end
  15.         return
  16.     end
  17.    
  18.     local r, g, b = blizzPlate.healthBar:GetStatusBarColor()
  19.     if g + b == 0 then -- hostile
  20.         healthcurval = blizzPlate.newPlate.healthBar:GetValue()
  21.         _, healthmaxval = blizzPlate.newPlate.healthBar:GetMinMaxValues()
  22.         if healthcurval / healthmaxval < 0.35 then
  23.             r, g, b = 1, 0.5, 0
  24.         else
  25.             r, g, b = 0.1, 0.1, 0.1
  26.         end
  27.     elseif r + b == 0 then -- friendly npc
  28.         r, g, b = FACTION_BAR_COLORS[6].r, FACTION_BAR_COLORS[6].g, FACTION_BAR_COLORS[6].b
  29.     elseif r + g > 1.95 then -- neutral
  30.         healthcurval = blizzPlate.newPlate.healthBar:GetValue()
  31.         healthmaxval, healthmaxval = blizzPlate.newPlate.healthBar:GetMinMaxValues()
  32.         if healthcurval / healthmaxval < 0.35 then
  33.             r, g, b = 1, 0.5, 0
  34.         else
  35.             r, g, b = FACTION_BAR_COLORS[4].r, FACTION_BAR_COLORS[4].g, FACTION_BAR_COLORS[4].b
  36.         end
  37.     elseif r + g == 0 then -- friendly player, we don't like 0,0,1 so we change it to a more likable color
  38.         r, g, b = 0/255, 100/255, 255/255
  39.     end
  40.    
  41.     blizzPlate.newPlate.healthBar:SetStatusBarColor(r, g, b)
  42. end

The code works exactly as intended, changes the color of the nameplates name text to red when I have aggro, and when mobs drop below 35% health, they get an orange healthbar. My question is, do you think this will impose some noticeable cpu performance impact, which this addon aims to tackle, and if so, could you suggest a better alternative?

Additionally, and unrelated to the aforementioned question(s), I am interested in applying a backdrop to these nameplates, however, my efforts to do so are currently in vain secondary to nameplates being parented to the WorldFrame, and therefore not pixelperfect. Is there a particular function I could edit to self enable pixel perfection?

Thanks for this fantastically written addon!
Last edited by sirann : 01-12-15 at 11:40 PM.
sirann is online now Report comment to moderator  
Reply With Quote
Unread 01-09-15, 09:28 AM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
I see. I'll mess with it more at home, thanks!

e: seems to be in functioning order after tweaking the placement. thanks!
Last edited by sirann : 01-12-15 at 10:43 PM.
sirann is online now Report comment to moderator  
Reply With Quote
Unread 01-09-15, 09:06 AM  
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1408
File comments: 3449
Uploads: 90
If you haven't screwed up the nameplate position to much you can actually click the nameplate. By the new nameplate is exactly on top of the old one.
__________________
| Simple is beautiful.
| Roth UI | Roth UI FAQ | GoogleCode | Zork | TDMOG

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
zork is offline Report comment to moderator  
Reply With Quote
Unread 01-08-15, 06:11 PM  
sirann
A Flamescale Wyrmkin

Forum posts: 105
File comments: 45
Uploads: 0
With the default name plates, it's possible to click the name plate itself to target the associated unit, additionally, when mousing over said nameplate, the name text is changed from white to yellow.

Is it possible to one, be able to add code to this addon to allow for targeting via left mouse click on name plate or elements thereof, and two, show some sort of color change, alpha change, etc to let you know which unit you're mousing over?
sirann is online now Report comment to moderator  
Reply With Quote
Unread 12-30-14, 09:00 PM  
Kabuto-eu
A Kobold Labourer

Forum posts: 0
File comments: 29
Uploads: 0
Unable to recreate the castbar flickering glitch so far.
Kabuto-eu is offline Report comment to moderator  
Reply With Quote
Unread 12-28-14, 06:05 PM  
furbolgi
A Kobold Labourer

Forum posts: 0
File comments: 7
Uploads: 0
Originally Posted by zork
@furbolgi
Yeah the nameplate healthbar color function was not throttled. A new version will do that. Decided to add faction based coloring aswell if no threat state is found on the nameplate.
https://code.google.com/p/rothui/source/detail?r=1361
But higher CPU usage is normal. I hook castbar and healthbar OnValueChanged functions and apply the given values to new health and castbars. What do you use for CPU profiling?
I use AddonProfiler http://wow.curseforge.com/addons/add...s/9-r20090903/ it's very dated but still works perfectly fine with some modifications (http://pastebin.com/cnJq1v3A).
furbolgi is offline Report comment to moderator  
Reply With Quote
Unread 12-28-14, 05:47 AM  
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1408
File comments: 3449
Uploads: 90
@furbolgi
Yeah the nameplate healthbar color function was not throttled. A new version will do that. Decided to add faction based coloring aswell if no threat state is found on the nameplate.
https://code.google.com/p/rothui/source/detail?r=1361
But higher CPU usage is normal. I hook castbar and healthbar OnValueChanged functions and apply the given values to new health and castbars. What do you use for CPU profiling?
__________________
| Simple is beautiful.
| Roth UI | Roth UI FAQ | GoogleCode | Zork | TDMOG

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
Last edited by zork : 12-28-14 at 05:49 AM.
zork is offline Report comment to moderator  
Reply With Quote
Unread 12-28-14, 12:04 AM  
Kabuto-eu
A Kobold Labourer

Forum posts: 0
File comments: 29
Uploads: 0
I'll try and recreate my glitch with this new version.
Kabuto-eu is offline Report comment to moderator  
Reply With Quote
Unread 12-27-14, 07:26 PM  
furbolgi
A Kobold Labourer

Forum posts: 0
File comments: 7
Uploads: 0
Originally Posted by zork
I need time till the weekend until I can spend some time on coding. Want to test my nameplate changes.

*edit*
Nameplate changes are active. See changelog.
Thanks, they seem to be working fine now, one thing I noticed is that the new version takes about 60% more cpu than the older version I modified.

Not sure if part of it is work that now is done by the addon and no longer done by blizzard and I can't profile blizzard's addons so no clue about the net effect.
furbolgi is offline Report comment to moderator  
Reply With Quote
Unread 12-25-14, 05:45 PM  
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1408
File comments: 3449
Uploads: 90
I need time till the weekend until I can spend some time on coding. Want to test my nameplate changes.

*edit*
Nameplate changes are active. See changelog.
__________________
| Simple is beautiful.
| Roth UI | Roth UI FAQ | GoogleCode | Zork | TDMOG

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
Last edited by zork : 12-27-14 at 11:20 AM.
zork is offline Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: