Hey guys k so I wanted to build a passive spell that deals 30/40/50% of the difference between the attacking unit's movement speed and the attacked unit's movement speed. It seems to be doing ALOT more damage than that though killing a black dragon in 2 and a half hits haha. Can anyone help?
Vantage Bite
Events
Unit - A unit Is attacked
Conditions
((Attacking unit) has buff Vantage Bite ) Equal to True
Actions
Set vantagebitemovespeeddiff = (((Integer((Current movement speed of (Attacking unit)))) - (Integer((Current movement speed of (Attacked unit))))) x (Integer((0.20 + (10.00 x (Real((Level of Vantage Bite for (Attacking unit)))))))))
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Attacked unit) is A structure) Equal to False
Then - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
vantagebitemovespeeddiff Greater than or equal to (Integer((Life of (Attacked unit))))
Then - Actions
Unit - Create 1 dummy for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
Unit - Add dummy instant kill firebolt to (Last created unit)
Unit - Order (Last created unit) to Neutral - Firebolt (Attacked unit)
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Else - Actions
Unit - Set life of (Attacked unit) to ((Life of (Attacked unit)) - (Real(vantagebitemovespeeddiff)))
Else - Actions
Do nothing
I had to add the:
If - Conditions
vantagebitemovespeeddiff Greater than or equal to (Integer((Life of (Attacked unit))))
Then - Actions
Unit - Create 1 dummy for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
Unit - Add dummy instant kill firebolt to (Last created unit)
Unit - Order (Last created unit) to Neutral - Firebolt (Attacked unit)
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
part because it would be killing units and not giving the gold/credit to the attacking hero.
Vantage Bite
Events
Unit - A unit Is attacked
Conditions
((Attacking unit) has buff Vantage Bite ) Equal to True
Actions
Set vantagebitemovespeeddiff = (((Integer((Current movement speed of (Attacking unit)))) - (Integer((Current movement speed of (Attacked unit))))) x (Integer((0.20 + (10.00 x (Real((Level of Vantage Bite for (Attacking unit)))))))))
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Attacked unit) is A structure) Equal to False
Then - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
vantagebitemovespeeddiff Greater than or equal to (Integer((Life of (Attacked unit))))
Then - Actions
Unit - Create 1 dummy for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
Unit - Add dummy instant kill firebolt to (Last created unit)
Unit - Order (Last created unit) to Neutral - Firebolt (Attacked unit)
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Else - Actions
Unit - Set life of (Attacked unit) to ((Life of (Attacked unit)) - (Real(vantagebitemovespeeddiff)))
Else - Actions
Do nothing
I had to add the:
If - Conditions
vantagebitemovespeeddiff Greater than or equal to (Integer((Life of (Attacked unit))))
Then - Actions
Unit - Create 1 dummy for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
Unit - Add dummy instant kill firebolt to (Last created unit)
Unit - Order (Last created unit) to Neutral - Firebolt (Attacked unit)
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
part because it would be killing units and not giving the gold/credit to the attacking hero.