• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

How to make damage and healing numbers appear with the damage system?

Status
Not open for further replies.
Level 6
Joined
Aug 31, 2018
Messages
157
Is it hard to make every damage or healing that you do to appear as real numbers and different colors?

I have the damage detection system but i downloaded it yesterday, so i don't know how it works and how to do that.
 
Level 9
Joined
Jul 30, 2018
Messages
445
Can 1 trigger work for all spells and attacks?

Yes. Basically you can make everything in one trigger as long as they all share the same event.

As for the damage floating text, here's an example:
  • Damage Floating Text
    • Events
      • Game - DamageEvent becomes Equal to 1.00
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DamageEventType Equal to DamageTypeBlocked
        • Then - Actions
          • Floating Text - Create floating text that reads |cff808080Blocked!|r above DamageEventTarget with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DamageEventType Equal to DamageTypeCriticalStrike
            • Then - Actions
              • Floating Text - Create floating text that reads (|cffff0000 + ((String((Integer(DamageEventAmount)))) + !|r)) above DamageEventTarget with Z offset 0.00, using font size 11.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • IsDamageSpell Equal to True
                • Then - Actions
                  • Floating Text - Create floating text that reads (|cff00c8ff + (String((Integer(DamageEventAmount))))) above DamageEventTarget with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
                • Else - Actions
                  • Floating Text - Create floating text that reads (String((Integer(DamageEventAmount)))) above DamageEventTarget with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
      • Floating Text - Set the velocity of (Last created floating text) to 32.00 towards 90.00 degrees
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Change the lifespan of (Last created floating text) to 2.50 seconds
      • Floating Text - Change the fading age of (Last created floating text) to 1.50 seconds
 

Wrda

Spell Reviewer
Level 25
Joined
Nov 18, 2012
Messages
1,870
I have the damage detection system but i downloaded it yesterday, so i don't know how it works and how to do that.
You would know how it works if you stopped asking questions every 2 hours and actually read how to use a system you downloaded, because 1. it has instructions, 2. a lot of info and options, 3. there's a map with examples.
So please, just use your brain for things which can be easily solved if you stopped being this lazy. There's a lot of info, you just need to dig in and figure it out yourself
 
Just posting mine here;

  • Damage Text
    • Events
      • Game - DamageModifierEvent becomes Equal to 1.00
    • Conditions
    • Actions
      • Set Critchance = 15.00
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • IsDamageSpell Equal to True
        • Then - Actions
          • Set FontColor[1] = 0.00
          • Set FontColor[2] = 0.00
          • Set FontColor[3] = 100.00
        • Else - Actions
          • Set FontColor[1] = 100.00
          • Set FontColor[2] = 0.00
          • Set FontColor[3] = 0.00
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random real number between 0.00 and 100.00) Less than or equal to Critchance
        • Then - Actions
          • Set DamageEventAmount = (DamageEventAmount x 2.00)
          • Set FontSize = 20.00
        • Else - Actions
          • Set FontSize = 10.00
      • Set DamageInteger = (Integer(DamageEventAmount))
      • Set TempLocation[1] = (Position of DamageEventTarget)
      • Floating Text - Create floating text that reads (- + (String(DamageInteger))) at TempLocation[1] with Z offset 80.00, using font size FontSize, color (FontColor[1]%, FontColor[2]%, FontColor[3]%), and 0.00% transparency
      • Custom script: call RemoveLocation (udg_TempLocation[1])
      • Floating Text - Set the velocity of (Last created floating text) to 250.00 towards 90.00 degrees
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Change the lifespan of (Last created floating text) to 1.00 seconds
      • Floating Text - Change the fading age of (Last created floating text) to 0.50 seconds

This isn't complete but is the one I had available in the map I currently have open in the world editor. It works fine with normal attack damage and spell damage. It also comes with a flat 15% crit chance for all attacks, so you might wanna edit that to your liking.

You can very easily edit the font colors of the different damage types this way.
 
Level 6
Joined
Aug 31, 2018
Messages
157
Just posting mine here;

  • Damage Text
    • Events
      • Game - DamageModifierEvent becomes Equal to 1.00
    • Conditions
    • Actions
      • Set Critchance = 15.00
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • IsDamageSpell Equal to True
        • Then - Actions
          • Set FontColor[1] = 0.00
          • Set FontColor[2] = 0.00
          • Set FontColor[3] = 100.00
        • Else - Actions
          • Set FontColor[1] = 100.00
          • Set FontColor[2] = 0.00
          • Set FontColor[3] = 0.00
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random real number between 0.00 and 100.00) Less than or equal to Critchance
        • Then - Actions
          • Set DamageEventAmount = (DamageEventAmount x 2.00)
          • Set FontSize = 20.00
        • Else - Actions
          • Set FontSize = 10.00
      • Set DamageInteger = (Integer(DamageEventAmount))
      • Set TempLocation[1] = (Position of DamageEventTarget)
      • Floating Text - Create floating text that reads (- + (String(DamageInteger))) at TempLocation[1] with Z offset 80.00, using font size FontSize, color (FontColor[1]%, FontColor[2]%, FontColor[3]%), and 0.00% transparency
      • Custom script: call RemoveLocation (udg_TempLocation[1])
      • Floating Text - Set the velocity of (Last created floating text) to 250.00 towards 90.00 degrees
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Change the lifespan of (Last created floating text) to 1.00 seconds
      • Floating Text - Change the fading age of (Last created floating text) to 0.50 seconds

This isn't complete but is the one I had available in the map I currently have open in the world editor. It works fine with normal attack damage and spell damage. It also comes with a flat 15% crit chance for all attacks, so you might wanna edit that to your liking.

You can very easily edit the font colors of the different damage types this way.
Can you please post a map with this trigger? Sorry for wasting your time, but ill do this for hours.. I am still newbie at trigger making
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,496
@HolyWillRise
That trigger I made for you for your Sleep spell uses the Damage Engine. It runs whenever ANY unit takes damage. So all you have to do is add floating text to that trigger and set it's value to "DamageEventAmount". You can use that one trigger for ALL of your Damage Engine needs.

Check this out to create floating text or use the links that were posted by others:
Floating Text

Just put the floating text at the very bottom of the trigger (and not inside of that If Then Else statement with the "DamageEventTarget" has buff Sleep).
 
Status
Not open for further replies.
Top