• 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.

Damage Floating Text

Status
Not open for further replies.
Level 7
Joined
Apr 12, 2009
Messages
188
Check out the floating text damage detector in this game:

Gaia's Retaliation

...I was impressed by that one ^^

Anyway, if you're a noob like me you could check out this system:

GUI-Friendly Damage Detection

Easy to paste into your map and use for damage detection. Adding floating text would probably be pretty easy I would imagine, since you can detect the unit dealing damage and the damaged unit, and change the text color based on that, and have it shoot up at random directions.

There might be systems out there already done and packaged though :con:
 
Level 7
Joined
Apr 12, 2009
Messages
188
GUI damage detection system lack efficienty and are not very good, and may cause lag after some period.
Better use this one.

The system I was referring to is not done in GUI. I don't know all that much about the efficiency and lag, but I use the system in my map and notice neither of those problems after extended game play. And it only took me about 5 minutes to install the system and have it working properly. If you do all your work in the GUI, I'd highly recommend you look at it before dismissing it as 'not very good'.

The JASS code is given on the page where my original link sends you, if you care to review it.
 
Level 3
Joined
Jan 2, 2010
Messages
34
but how can i use this "super" damage detector if i can't open those maps in my WE :( i have a hero arena and i want damage floating text like on the map i posted on threat

(sorry for my english :p)
 
Level 7
Joined
Nov 6, 2009
Messages
279
but how can i use this "super" damage detector if i can't open those maps in my WE :( i have a hero arena and i want damage floating text like on the map i posted on threat

(sorry for my english :p)

GUI damage detection system lack efficienty and are not very good, and may cause lag after some period.
Better use this one.

Click the green "this" in MortAr's post.
 
Level 3
Joined
Jan 2, 2010
Messages
34
Eh i'm so weak in jass :(
I wanted damage engine which would work like this map but i see u can't help me ;/
Maybe i can make my own floating text but...
How to show floating text only to one player?
 
  • Player Group - Pick every player in (All players) and do (Actions)
    • Loop - Actions
      • If (All conditions are true) then do (Actions) else do (Actions)
        • If - Conditions
          • (Picked player) Not Equal to (Owner of (Triggering unit))
        • Then - Actions
          • Floating Text - Hide (Last created floating text) for (Picked player)
        • Else - Actions
This will hide the floating text for every player, but the owner of your unit, e.g. your caster. It can also be the damage source, so use "(Owner of (Damage Source))" instead.
 
Level 7
Joined
Apr 12, 2009
Messages
188
Yo dude,

GUI-Friendly Damage Detection

Click the above link, read up on how to install that damage detection system, and do it. Should literally only take you 5 minutes to download and copy over the three triggers that you'll need.

Then you can make a trigger like this:

  • Create Text
    • Events
      • Game - GDD_Event becomes Equal to 0.00
    • Conditions
      • GDD_Damage Greater than 1.00
    • Actions
      • Floating Text - Create floating text that reads (String((Integer(GDD_Damage)))) above GDD_DamagedUnit with Z offset 0.00, using font size 8.00, color (100.00%, 14.00%, 14.00%), and 0.00% transparency
      • Floating Text - Hide (Last created floating text) for (All players matching ((Owner of GDD_DamageSource) Not equal to (Matching player)))
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Set the velocity of (Last created floating text) to (Random real number between 50.00 and 100.00) towards (Random real number between 70.00 and 110.00) degrees
      • Floating Text - Change the lifespan of (Last created floating text) to 2.00 seconds
      • Floating Text - Change the fading age of (Last created floating text) to 1.00 seconds
There's a lot more flexibility than what I show above, but at least you can get the idea. A few minutes of work for a really decent looking damage text. I used Pharaoh_'s suggested technique for limiting the text to only the damaging player.

Only limitations are that the damage type is not recorded, so you will have to stick with just one color for damage on enemies, maybe one color for damage on allies, etc, since the only things returned from the damage event are the units involved and the amount of damage. Another thing is I don't think you can use this for detecting heals :nw:
 
Status
Not open for further replies.
Top