- Joined
- May 16, 2020
- Messages
- 660
Hi guys
Within this trigger I use a "MUI" wait as described here:
MUI Triggers with Waits
My problem is that I don't think the points can be made MUI here without leaking, right?
Reason being that Point[1] cannot be removed before the wait is over as another unit might use the Point [1] as well... And if I only remove it after the wait, it has already been overwritten by another unit, hence creating a leak.
Within this trigger I use a "MUI" wait as described here:
MUI Triggers with Waits
My problem is that I don't think the points can be made MUI here without leaking, right?
Reason being that Point[1] cannot be removed before the wait is over as another unit might use the Point [1] as well... And if I only remove it after the wait, it has already been overwritten by another unit, hence creating a leak.
-
Burrowstrike
-
Events
-
Unit - A unit Starts the effect of an ability
-
-
Conditions
-
(Ability being cast) Equal to Burrowstrike
-
-
Actions
-
Set VariableSet Burrowstrike_IndexWrite = (Burrowstrike_IndexWrite + 1)
-
Set VariableSet Burrowstrike_Caster[Burrowstrike_IndexWrite] = (Triggering unit)
-
Set VariableSet Burrowstrike_Level = (Level of Burrowstrike for Burrowstrike_Caster[Burrowstrike_IndexWrite])
-
Set VariableSet Burrowstrike_Point[1] = (Position of Burrowstrike_Caster[Burrowstrike_IndexWrite])
-
Set VariableSet Burrowstrike_Point[2] = (Target point of ability being cast)
-
Set VariableSet Burrowstrike_Point[3] = (Burrowstrike_Point[1] offset by -100.00 towards (Angle from Burrowstrike_Point[1] to Burrowstrike_Point[2]) degrees.)
-
Set VariableSet Burrowstrike_Distance = (Distance between Burrowstrike_Point[1] and Burrowstrike_Point[2])
-
-------- --------
-
Unit - Create 1 Dummy (Ground/Speed 0) for (Owner of Burrowstrike_Caster[Burrowstrike_IndexWrite]) at Burrowstrike_Point[3] facing Default building facing degrees
-
Set VariableSet Burrowstrike_Dummy = (Last created unit)
-
Unit - Add Burrowstrike_Ability[Burrowstrike_Level] to Burrowstrike_Dummy
-
Unit - Set level of Burrowstrike_Ability[Burrowstrike_Level] for Burrowstrike_Dummy to (Integer((Burrowstrike_Distance / 100.00)))
-
Unit - Order Burrowstrike_Dummy to Undead Crypt Lord - Impale Burrowstrike_Point[2]
-
Unit - Add a 0.50 second Generic expiration timer to Burrowstrike_Dummy
-
Custom script: call RemoveLocation(udg_Burrowstrike_Point[2])
-
Custom script: call RemoveLocation(udg_Burrowstrike_Point[3])
-
Wait (Burrowstrike_Distance / 4000.00) seconds
-
Set VariableSet Burrowstrike_IndexRead = (Burrowstrike_IndexRead + 1)
-
Unit - Move Burrowstrike_Caster[Burrowstrike_IndexRead] instantly to Burrowstrike_Point[2]
-
Animation - Play Burrowstrike_Caster[Burrowstrike_IndexRead]'s morph alternate animation
-
Animation - Queue Burrowstrike_Caster[Burrowstrike_IndexRead]'s stand animation
-
Custom script: call RemoveLocation(udg_Burrowstrike_Point[1])
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Burrowstrike_IndexRead Equal to Burrowstrike_IndexWrite
-
-
Then - Actions
-
Set VariableSet Burrowstrike_IndexWrite = 0
-
Set VariableSet Burrowstrike_IndexRead = 0
-
-
Else - Actions
-
-
-
Last edited: