• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] Get a name to show over the unit like neutral hostiles do

Level 8
Joined
Jul 21, 2015
Messages
143
Hi all,

so basically I have custom names for most units in this rpg I am making and I would like their name to show in a cool way like the Neutral Hostiles do. Is this possible?

I see in this thread it was discussed:
this one

but I don't know if they are discussing the same thing as me.

Thanks all in advance for help!
1735783193680.png
 
Last edited:

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,866
I don't think it's possible.

But there's a function to detect when a Mouse is focused on a Unit so maybe you can show that frame if it exists.

Otherwise, Floating Text could be a decent alternative.

Edit: Here's a proof of concept. Note that this demo is only safe to use in offline solo play. However, it could be designed to work in multiplayer without too much tinkering, you'd just need to sync the information between players and use Arrays to store the data.
 

Attachments

  • Mouse Focus Text 1.w3m
    17.8 KB · Views: 7
Last edited:
Level 8
Joined
Jul 21, 2015
Messages
143
I like this method quite a bit, thank you for sharing Uncle! You da best!

I am curious that if I made each unit into a hero and made them have that proper name, if that would solve my problem. Sorry I didn't think of this before I posted the forum, but I see that Uther shows his name because he is a hero. Perhaps that could work as well.

Edit: I tested your map and that is supe cool, also giving the unit a proper name by making them a hero it shows the name now :D

Although I wish it didn't show the player but that may go away if I make them neutral-passive.
 
Top