I thought i removed the leaks right but it disable trigger because it expects a function any help please?
Trigger:
- Darkness
- Events
- Unit - A unit Begins casting an ability
- Conditions
- (Ability being cast) Equal to Darkness
- Actions
- Set Darkness_point = (Position of (Triggering unit))
- Hashtable - Create a hashtable
- Set Lightning_hash = (Last created hashtable)
- Hashtable - Create a hashtable
- Set Dummy_position_hash = (Last created hashtable)
- Unit - Pause (Triggering unit)
- Unit - Make (Triggering unit) Invulnerable
- Special Effect - Create a special effect at Darkness_point using Abilities\Spells\Orc\WarStomp\WarStompCaster.mdl
- Set Darkness_Nova_end = (Darkness_point offset by 50.00 towards (10.00 x (Real((Integer A)))) degrees)
- For each (Integer A) from 1 to 30, do (Actions)
- Loop - Actions
- Unit - Create 1 Darkness Dummy for (Triggering player) at Darkness_point facing Default building facing degrees
- Unit - Add Carrion Swarm to (Last created unit)
- Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm Darkness_Nova_end
- Loop - Actions
- Unit Group - Pick every unit in (Units within 500.00 of Darkness_point matching (((Picked unit) belongs to an enemy of Player 1 (Red)) Equal to True)) and do (Actions)
- Loop - Actions
- Unit - Pause (Picked unit)
- Loop - Actions
- Wait 0.03 seconds
- Unit Group - Pick every unit in (Units owned by (Triggering player) of type Darkness Dummy) and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Wait 1.00 seconds
- Special Effect - Create a special effect at Darkness_point using Abilities\Spells\Orc\WarStomp\WarStompCaster.mdl
- For each (Integer A) from 1 to 30, do (Actions)
- Loop - Actions
- Unit - Create 1 Darkness Dummy for (Triggering player) at Darkness_point facing Default building facing degrees
- Unit - Add Carrion Swarm to (Last created unit)
- Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm Darkness_Nova_end
- Loop - Actions
- Wait 0.05 seconds
- Unit Group - Pick every unit in (Units owned by (Triggering player) of type Darkness Dummy) and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Wait 1.00 seconds
- Special Effect - Create a special effect at Darkness_point using Abilities\Spells\Orc\WarStomp\WarStompCaster.mdl
- For each (Integer A) from 1 to 30, do (Actions)
- Loop - Actions
- Unit - Create 1 Darkness Dummy for (Triggering player) at Darkness_point facing Default building facing degrees
- Unit - Add Carrion Swarm to (Last created unit)
- Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm Darkness_Nova_end
- Loop - Actions
- Wait 0.05 seconds
- Unit Group - Pick every unit in (Units owned by (Triggering player) of type Darkness Dummy) and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Wait 1.00 seconds
- Special Effect - Create a special effect at Darkness_point using Abilities\Spells\Orc\WarStomp\WarStompCaster.mdl
- For each (Integer A) from 1 to 30, do (Actions)
- Loop - Actions
- Unit - Create 1 Darkness Dummy for (Triggering player) at Darkness_point facing Default building facing degrees
- Unit - Add Carrion Swarm to (Last created unit)
- Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm Darkness_Nova_end
- Loop - Actions
- Wait 0.05 seconds
- Unit Group - Pick every unit in (Units owned by (Triggering player) of type Darkness Dummy) and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Wait 1.00 seconds
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (0.00, 300.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 1 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (0.00, 30.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 1 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (300.00, 0.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 2 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (30.00, 0.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 2 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (0.00, -300.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 3 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (0.00, -30.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 3 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (-300.00, 0.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 4 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (-30.00, 0.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 4 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (225.00, 225.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 5 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (25.00, 25.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 5 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (-225.00, -225.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 6 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (-25.00, -25.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 6 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (-225.00, 225.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 7 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (-25.00, 25.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 7 of 8 in Lightning_hash
- Unit - Create 1 Darkness Dummy for (Triggering player) at (Darkness_point offset by (225.00, -225.00)) facing Default building facing degrees
- Hashtable - Save Handle Of(Position of (Last created unit)) as 8 of 8 in Dummy_position_hash
- Lightning - Create a Chain Lightning - Primary lightning effect from source (Position of (Last created unit)) to target (Darkness_point offset by (25.00, -25.00))
- Hashtable - Save Handle Of(Last created lightning effect) as 8 of 8 in Lightning_hash
- Wait 3.00 seconds
- Set Loop = 0
- For each (Integer A) from 1 to 10, do (Actions)
- Loop - Actions
- Lightning - Destroy (Load Loop of 8 in Lightning_hash)
- Set Loop = (Loop + 1)
- Loop - Actions
- Special Effect - Create a special effect at Darkness_point using Abilities\Spells\Orc\Voodoo\VoodooAura.mdl
- Hashtable - Save Handle Of(Last created special effect) as 1 of 10 in Effect
- Set Loop = 0
- For each (Integer A) from 1 to 10, do (Actions)
- Loop - Actions
- Special Effect - Create a special effect at (Load Loop of 8 in Dummy_position_hash) using Abilities\Spells\Orc\WarStomp\WarStompCaster.mdl
- Set Loop = (Loop + 1)
- Loop - Actions
- Environment - Create a 3.00 second Temporary crater deformation at Darkness_point with radius 500.00 and depth 200.00
- Wait 2.00 seconds
- Environment - Create a 2.00 second Depression ripple deformation at Darkness_point with starting radius 1024.00, ending radius 1024.00, and depth 200.00, using 0.50 second ripples spaced 512.00 apart
- Environment - Create Blight for (Owner of (Triggering unit)) from Darkness_point to a radius of 100.00
- Wait 0.25 seconds
- Environment - Create Blight for (Owner of (Triggering unit)) from Darkness_point to a radius of 200.00
- Wait 0.25 seconds
- Environment - Create Blight for (Owner of (Triggering unit)) from Darkness_point to a radius of 300.00
- Wait 0.25 seconds
- Environment - Create Blight for (Owner of (Triggering unit)) from Darkness_point to a radius of 400.00
- Wait 0.25 seconds
- Environment - Create Blight for (Owner of (Triggering unit)) from Darkness_point to a radius of 500.00
- Wait 1.00 seconds
- Game - Set the time of day to 24.00
- Special Effect - Destroy (Load 1 of 10 in Effect)
- Unit - Remove (Picked unit) from the game
- Special Effect - Create a special effect at Darkness_point using Objects\Spawnmodels\Undead\UndeadDissipate\UndeadDissipate.mdl
- Unit Group - Pick every unit in (Units owned by (Triggering player) of type Darkness Dummy) and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Wait 0.50 seconds
- Unit - Unpause (Triggering unit)
- Unit - Make (Triggering unit) Vulnerable
- Custom script: call remove location (udg_Darkness_point)
- Custom script: call remove location (udg_Darkness_Nova_end)
- Custom script: call remove location (udg_Dummy_positions)
- Events