dyablohunter
New Member
- Reaction score
- 2
Simple question. Tricky answer.
I want a spell/ability like lightning shield but... I want it to only be able to damage enemy units within 200 yd of the unit that has lightning shield on it.
I know it's only possible with triggers but so far my triggers didnt work:
The actual damaging:
Can anybody help?
I want a spell/ability like lightning shield but... I want it to only be able to damage enemy units within 200 yd of the unit that has lightning shield on it.
I know it's only possible with triggers but so far my triggers didnt work:
Code:
Lightning Shield Ally lvl 1
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Lightning Shield [Shaman]
((Casting unit) belongs to an ally of Player 1 (Red)) Equal to True
(Level of Lightning Shield [Shaman] for (Casting unit)) Equal to 1
Actions
Set LightningShieldAlly = (Position of (Casting unit))
Trigger - Run Ally Lightning Shield 75 dmg <gen> (checking conditions)
Wait 15.00 game-time seconds
Trigger - Turn off Ally Lightning Shield 75 dmg <gen>
The actual damaging:
Code:
Ally Lightning Shield 75 dmg
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in (Units within 200.00 of LightningShieldAlly matching (((Matching unit) belongs to an enemy of Player 1 (Red)) Equal to True)) and do (Actions)
Loop - Actions
Unit - Cause Intercept Dummy 1 0092 <gen> to damage (Picked unit), dealing 75.00 damage of attack type Spells and damage type Lightning
Can anybody help?