- Joined
- Jul 9, 2008
- Messages
- 253
Hello, I made a spell called Lightning Vengeance, that makes a circle of lightning that moves towards the caster and then explodes, dealing damage to nearby enemy units.
The problem is that when I cast it the second time, it also gets cast on the spot where I casted it the first time. So it does the spells twice. This is strange because I don't have this in my trigger ( I believe I don't )
So could anyone help me?
Here is the trigger:
The problem is that when I cast it the second time, it also gets cast on the spot where I casted it the first time. So it does the spells twice. This is strange because I don't have this in my trigger ( I believe I don't )
So could anyone help me?
Here is the trigger:
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Lightning Vengeance
-
Actions
- Set Position = (Position of (Triggering unit))
- Unit - Create 1 Dummy - Buffer for (Owner of (Triggering unit)) at Position facing Default building facing degrees
- Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Level of Lightning Vengeance for (Triggering unit)) Equal to 2
-
Then - Actions
- Unit - Set level of Lightning Protection for (Last created unit) to 2
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Level of Lightning Vengeance for (Triggering unit)) Equal to 3
-
Then - Actions
- Unit - Set level of Lightning Protection for (Last created unit) to 3
- Else - Actions
-
If - Conditions
- Unit - Order (Last created unit) to Human Priest - Inner Fire (Triggering unit)
- Set Facing = 0.00
- Unit - Pause (Triggering unit)
-
For each (Integer A) from 1 to 18, do (Actions)
-
Loop - Actions
- Unit - Create 1 Dummy - Eyecandy for (Owner of (Triggering unit)) at (Position offset by 600.00 towards Facing degrees) facing Default building facing degrees
- Unit - Order (Last created unit) to Move To Position
- Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
- Set Facing = (Facing + 20.00)
-
Loop - Actions
- Wait 1.00 seconds
- Unit - Unpause (Triggering unit)
- Set Facing = 0.00
- Unit - Create 1 Dummy - Explosion for (Owner of (Triggering unit)) at Position facing Default building facing degrees
- Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
-
Unit Group - Pick every unit in (Units within 400.00 of Position matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True)) and do (Actions)
-
Loop - Actions
- Unit - Cause (Triggering unit) to damage (Picked unit), dealing ((50.00 x (Real((Level of Lightning Vengeance for (Triggering unit))))) + ((Real((Strength of (Triggering unit) (Include bonuses)))) x (Real((Level of Lightning Vengeance for (Triggering unit)))))) damage of attack type Spells and damage type Normal
-
Loop - Actions
- Custom script: call RemoveLocation( udg_Position )