So I'm creating a spell which silences an area every 0.5 seconds. I was following this guide: http://www.hiveworkshop.com/forums/...orials-279/visualize-dynamic-indexing-241896/
Here's my triggers:
Two things:
1.) Whenever the duration of the first cast has finished (10 seconds), all of the casts stop regardless of when they were cast. Why? How do I fix it?
2.) How do I fix the point leak? Not sure how to go about that.
I'm not that advanced with this stuff if you can make the explanation simple. Thanks
Here's my triggers:
-
Corruptor Silence
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Silence (Corruptor)
-
Actions
- Set Silence_Index = (Silence_Index + 1)
- Set Silence_Caster[Silence_Index] = (Triggering unit)
- Set Silence_Point[Silence_Index] = (Target point of ability being cast)
- Unit - Create 1 Dummy Unit for (Owner of (Triggering unit)) at Silence_Point[Silence_Index] facing Default building facing degrees
- Unit - Add a 12.00 second Generic expiration timer to (Last created unit)
- Set Silence_Dummy[Silence_Index] = (Last created unit)
- Set Silence_Counter[Silence_Index] = 0.00
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Silence_Index Equal to 1
-
Then - Actions
- Trigger - Turn on Corruptor Silence Loop <gen>
- Else - Actions
-
If - Conditions
-
Events
-
Corruptor Silence Loop
-
Events
- Time - Every 0.25 seconds of game time
- Conditions
-
Actions
-
For each (Integer Silence_LoopInteger) from 1 to Silence_Index, do (Actions)
-
Loop - Actions
- Unit - Order Silence_Dummy[Silence_LoopInteger] to Neutral Dark Ranger - Silence Silence_Point[Silence_LoopInteger]
- Set Silence_Counter[Silence_LoopInteger] = (Silence_Counter[Silence_LoopInteger] + 0.25)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Silence_Counter[Silence_LoopInteger] Greater than or equal to 10.00
-
Then - Actions
- Set Silence_Dummy[Silence_LoopInteger] = Silence_Dummy[Silence_Index]
- Set Silence_Point[Silence_LoopInteger] = Silence_Point[Silence_Index]
- Set Silence_Caster[Silence_LoopInteger] = Silence_Caster[Silence_Index]
- Set Silence_Dummy[Silence_LoopInteger] = Silence_Dummy[Silence_Index]
- Set Silence_Index = (Silence_Index - 1)
- Set Silence_LoopInteger = (Silence_LoopInteger - 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Silence_Index Equal to 0
-
Then - Actions
- Trigger - Turn off (This trigger)
- Else - Actions
-
If - Conditions
- Else - Actions
-
If - Conditions
-
Loop - Actions
-
For each (Integer Silence_LoopInteger) from 1 to Silence_Index, do (Actions)
-
Events
1.) Whenever the duration of the first cast has finished (10 seconds), all of the casts stop regardless of when they were cast. Why? How do I fix it?
2.) How do I fix the point leak? Not sure how to go about that.
I'm not that advanced with this stuff if you can make the explanation simple. Thanks