• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Trigger] Texts: DMG, EXP, HP, MP, ect.

Status
Not open for further replies.
Level 3
Joined
Aug 22, 2006
Messages
37
You probably been fooled of the topic if you mean about game text messages. I need a basic trigger that shows a number over their head when they get hit, lose HP, lose MP, gain MP, gain HP, lose EXP, gain EXP, and all of the other thinks you can think of that is a number.
For example, I need a damage trigger that shows the exact damage on top of the attacked units' head. If you still don't know what I mean, download Heroes of Darkfall 1.13 by necross_19, in that game, when you damage a unit, the damage integer is on top of the unit's head, showing the amount of damage dealt. I'd appreciate any help.
 
Level 3
Joined
Aug 22, 2006
Messages
37
No what I mean is a quick number above the unit's head that will go away in a second. Critical Strike will be ascending for a few seconds and I don't want that. Try the map if you don't get it. The map is on the attachment.
 

Attachments

  • HoD v 2.01.w3x
    653.4 KB · Views: 93
Level 37
Joined
Mar 6, 2006
Messages
9,240
The next trigger might work for you. Change/remove the floating text properties to get the desired effect.


DamageToUnit
Events
Conditions
Actions
Floating Text - Create floating text that reads (String((Integer((Damage taken))))) above MyUnit with Z offset 0.00, using font size 15.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency
Floating Text - Change (Last created floating text): Disable permanence
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 2.00 seconds
Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees


You also have to add an event to the previous trigger. You have to do it this way because you can't do it the regular way. (Duh)

The bad thing is you have to add every unit's damage taken event to the trigger that creates the text. If you are buying/training units you have to add their events here too. Anyway, this one has worked for my purposes.

AddEvent
Events
Conditions
Actions
Trigger - Add to DamageToUnit <gen> the event (Unit - MyUnit Takes damage)
 
Status
Not open for further replies.
Top