Kibaranger
New Member
- Reaction score
- 0
Can someone help me with a spell that deal damage over time and will kill the target instantly if its HP below X% ? (like AA's Ice Blast in dota)
Giga Thundershock
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Giga Thundershock
Actions
Set ShockCaster = (Casting unit)
Set ShockTarget = (Target unit of ability being cast)
Trigger - Turn on Giga Thundershock Check <gen>
Giga Thundershock Check
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(ShockTarget has buff Giga Thundershock ) Equal to True
Then - Actions
Unit - Cause ShockCaster to damage ShockTarget, dealing (25 + (25 x (Real((Level of Giga Thundershock for ShockCaster))))) damage of attack type Spells and damage type Magic
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Percentage life of ShockTarget) Less than or equal to 35.00
Then - Actions
Unit - Cause ShockCaster to damage ShockTarget, dealing 100000000.00 damage of attack type Chaos and damage type Normal
Else - Actions
Else - Actions
Trigger - Turn off (This trigger)
Custom script: set udg_ShockCaster = null
Custom script: set udg_ShockTarget = null
Giga Thundershock
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Giga Thundershock
Actions
Set ShockCaster[(Player number of (Owner of (Triggering unit)))] = (Casting unit)
Set ShockTarget[(Player number of (Owner of (Triggering unit)))] = (Target unit of ability being cast)
Trigger - Turn on Giga Thundershock Check <gen>
Giga Thundershock Check
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(ShockTarget[(Player number of (Owner of (Triggering unit)))] has buff Giga Thundershock ) Equal to True
Then - Actions
Unit - Cause ShockCaster[(Player number of (Owner of (Triggering unit)))] to damage ShockTarget[(Player number of (Owner of (Triggering unit)))], dealing (25.00 + (25.00 x (Real((Level of Giga Thundershock for ShockCaster[(Player number of (Owner of (Triggering unit)))]))))) damage of attack type Spells and damage type Magic
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Percentage life of ShockTarget[(Player number of (Owner of (Triggering unit)))]) Less than or equal to 20.00
Then - Actions
Unit - Cause ShockCaster[(Player number of (Owner of (Triggering unit)))] to damage ShockTarget[(Player number of (Owner of (Triggering unit)))], dealing 10000000.00 damage of attack type Chaos and damage type Enhanced
Else - Actions
Else - Actions
Trigger - Turn off (This trigger)
Custom script: set udg_ShockCaster[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] = null
Custom script: set udg_ShockTarget[GetConvertedPlayerId(GetOwningPlayer(GetTriggerUnit()))] = null