Hey, i tryed to make a spell that if u alternate the left and right arrow keys then you damage every opponents unit&hero near 300. I need alot of help plz
Code:
Spell
Events
Unit - A unit starts an a effect of an a Ability
Conditions
(Ability Being Cast) Equal to Spell
Actions
Set Caster = (Casting Unit)
Set EffectPoint = (Position of Caster offset by 500
Unit - Pause Caster
Set EffectIsOn = True
Turn on Spell Effect
Wait 5 Seconds
Turn off Spell Effect
Set EffectIsOn = False
Custom Script: call RemoveLocation(udg_EffectPoint)
Unit - Unpause Caster
Code:
Spell Effect
Events
Owner of Caster presses the Left Arrow Key
Owner of Caster presses the Right Arrow Key
Conditions
EffectIsOn equal to True
Actions
Special Effect - Create Special Effect at the origin of Caster using Thunder Clap [sorry, dont have WE opened]
Set EffectModel = (Last Created Special Effect)
Unit - Cause Caster to Damage Units within EffectPoint dealing 20 Damage of damage type Normal and Type Hero
Wait 1 Seconds
Special Effect - Destroy Last Created Special Effect.