| 05-26-2008, 03:09 AM | #1 |
Hi all, i want to know/learn how to damages floating on hits... example: My hero/unit is going to attack someone and when i attacks shows above the enemies head the damage dealt... so im trying to find this day after day...it will be very useful for me and for other players who those wants to make an orpg. |
| 05-26-2008, 05:23 AM | #2 |
easiest solution would be a hidden critical strike ability with a factor of 1. |
| 05-26-2008, 05:26 AM | #3 |
JASS://^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // // {texttag msg} // //^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function SPL_TTMsg takes string s, unit u, integer r, integer g, integer b returns nothing local texttag tt=CreateTextTag() call SetTextTagText(tt, s, .024) call SetTextTagPosUnit(tt, u, 32.) call SetTextTagColor(tt, r, g, b, 0xff) call SetTextTagVelocity(tt, .0, .0355) call SetTextTagFadepoint(tt, 1.75) call SetTextTagPermanent(tt, false) call SetTextTagLifespan(tt, 3.75) endfunction //^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // // end {texttag msg} // //^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ and use any damage detection system: http://www.wc3campaigns.net/showthread.php?t=98231 http://www.wc3campaigns.net/showthread.php?t=100422 ... |
| 05-26-2008, 04:26 PM | #4 | |
Quote:
Ya i know...sometimes i use it...but it costs some abilities space so i want something coded in triggers! =D |
| 05-26-2008, 04:36 PM | #5 |
Im looking for something like critical strike number hits(not necessary red if it is changeable).All hits shows the damage dealt but i dont want the Critical strike abilitie added to the units. |
| 05-26-2008, 07:56 PM | #6 |
read ADLOF's post. The function he gave displays a TextTag with the string you define and color you want. Use a Damage Detection System to get the damage and then Display the Damage converted to a string. |
| 05-27-2008, 07:13 AM | #7 |
and use I2S(R2I(GetEventDamage())) =) |
| 05-31-2008, 09:26 AM | #8 |
This is a sample on how to do it with standard triggers (no scripting). Quite easy. - http://www.wc3campaigns.net/showthread.php?t=84913 - |
