- Joined
- Nov 17, 2010
- Messages
- 28
-
Wisp Hook CAST
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Wisp Hook
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Index[0] Equal to 0
-
Then - Actions
- Trigger - Turn on Wisp Hook LOOP <gen>
- Else - Actions
-
If - Conditions
- Set Index[0] = (Index[0] + 1)
- Set Index[1] = (Index[1] + 1)
- Set Caster[Index[1]] = (Triggering unit)
- Set Point[Index[1]] = (Position of (Triggering unit))
- Set Point1[Index[1]] = (Target point of ability being cast)
- Set Angle[Index[1]] = (Angle from Point[Index[1]] to Point1[Index[1]])
- Set Velocity = 30.00
- Set Damage = 360.00
- Set Come[Index[1]] = False
- Set AreaOfEffect = 150.00
- Set ActualDistance[Index[1]] = 0.00
- Set Distance = 900.00
- Set ActualDistance[Index[1]] = 0.00
- Set Target[Index[1]] = No unit
-
Unit Group - Pick every unit in Group[Index[1]] and do (Actions)
-
Loop - Actions
- Unit Group - Remove (Picked unit) from Group[Index[1]]
-
Loop - Actions
- Custom script: call DestroyGroup(udg_Group[udg_Index[1]])
- Set Boolean[Index[1]] = True
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Events
-
Wisp Hook LOOP
-
Events
- Time - Every 0.03 seconds of game time
- Conditions
-
Actions
-
For each (Integer Index[2]) from 1 to Index[1], do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Boolean[Index[2]] Equal to True
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- ActualDistance[Index[2]] Less than Distance
- Come[Index[2]] Equal to False
-
Then - Actions
- Set ActualDistance[Index[2]] = (ActualDistance[Index[2]] + Velocity)
- Set TempPoint = (Point[Index[2]] offset by ActualDistance[Index[2]] towards Angle[Index[2]] degrees)
- Unit - Create 1 Hook for (Owner of Caster[Index[2]]) at TempPoint facing Angle[Index[2]] degrees
- Set Dummy = (Last created unit)
- Unit Group - Add Dummy to Group[Index[2]]
- Set Target[Index[2]] = (Random unit from (Units within AreaOfEffect of TempPoint matching (((((Matching unit) is A structure) Equal to False) and (Caster[Index[2]] Not equal to (Matching unit))) and (((Matching unit) is alive) Equal to True))))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Target[Index[2]] Not equal to No unit
-
Then - Actions
- Set Come[Index[2]] = True
- Unit - Turn collision for Target[Index[2]] Off
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Target[Index[2]] belongs to an enemy of (Owner of Caster[Index[2]])) Equal to True
-
Then - Actions
- Unit - Cause Caster[Index[2]] to damage Target[Index[2]], dealing Damage damage of attack type Spells and damage type Normal
- Else - Actions
-
If - Conditions
- Else - Actions
-
If - Conditions
- Custom script: call RemoveLocation(udg_TempPoint)
-
Else - Actions
- Set Come[Index[2]] = True
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Come[Index[2]] Equal to True
- ActualDistance[Index[2]] Greater than or equal to 100.00
-
Then - Actions
- Set ActualDistance[Index[2]] = (ActualDistance[Index[2]] - Velocity)
- Set TempPoint = (Point[Index[2]] offset by ActualDistance[Index[2]] towards Angle[Index[2]] degrees)
- Unit - Move Target[Index[2]] instantly to TempPoint
- Special Effect - Create a special effect at (Position of Target[Index[2]]) using Objects\Spawnmodels\Orc\Orcblood\OrcBloodHellScream.mdl
- Special Effect - Destroy (Last created special effect)
-
Unit Group - Pick every unit in (Units within 29.00 of (Position of Target[Index[2]]) matching (((Matching unit) is in Group[Index[2]]) Equal to True)) and do (Actions)
-
Loop - Actions
- Unit - Explode (Picked unit)
-
Loop - Actions
- Custom script: call RemoveLocation(udg_TempPoint)
-
Else - Actions
- Unit - Turn collision for Target[Index[2]] Off
- Custom script: call DestroyGroup(udg_Group[udg_Index[2]])
- Set Boolean[Index[2]] = False
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Boolean[Index[2]] Equal to False
-
Then - Actions
- Set Index[0] = (Index[0] - 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Index[0] Equal to 0
-
Then - Actions
- Set Index[1] = 0
- Trigger - Turn off (This trigger)
- Else - Actions
-
If - Conditions
- Else - Actions
-
If - Conditions
-
If - Conditions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions
-
For each (Integer Index[2]) from 1 to Index[1], do (Actions)
-
Events
My problem is this!
When the Hook targets an enemy, the enemy comes to the caster but the dummys aren't killed/exploded/removed :S
Can anyone answerme the solution? or fix the map?