Ashcat
Hellooo
- Reaction score
- 68
Okay, I'm trying to make a trigger that basically will do exactly what critical strike does. This is my trigger so far, right now it crashes the game, but I know why and thats not the problem. The problem is that I do not know how to refer to the damaged unit, as highlighted in the code:
If anyone could help me out with this I'd be really appreciative : )
Code:
Critical Strike
Events
Conditions
Actions
Set Temp_Point = (Position of ([B][COLOR="Red"]Attacked unit[/COLOR][/B]))
Floating Text - Create floating text that reads ((String((Integer(((Damage taken) + ((Damage taken) x (0.50 x (Real((Level of Critical Strike for (Damage source))))))))))) + !) at Temp_Point with Z offset 0.00, using font size 10.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 64.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 3.60 seconds
Unit - Cause (Damage source) to damage ([B][COLOR="Red"]Attacked unit[/COLOR][/B]), dealing ((Damage taken) x (0.50 x (Real((Level of Critical Strike for (Damage source)))))) damage of attack type Hero and damage type Normal
Custom script: call RemoveLocation (udg_Temp_Point)
If anyone could help me out with this I'd be really appreciative : )