Pyropenguins
New Member
- Reaction score
- 4
I need some help with the memory leaks. I'm not sure how to spot them. Please help me with this trigger and maybe i will learn from it
+rep for help :thup:
Trigger:
- First
- Events
- Unit - A unit owned by Player 1 (Red) Begins construction
- Conditions
- Actions
- Unit Group - Remove all units from Chain
- Unit Group - Add (Triggering unit) to Chain
- Trigger - Run Net <gen> (checking conditions)
- Events
Trigger:
- Next
- Events
- Conditions
- Actions
- Set BlockCheck = False
- Unit Group - Pick every unit in Chain and do (Actions)
- Loop - Actions
- Unit Group - Pick every unit in (Units owned by (Owner of (Triggering unit)) matching ((((Matching unit) is A structure) Equal to True) and ((((Matching unit) is in Chain) Equal to False) and ((Distance between (Position of (Picked unit)) and (Position of (Matching unit))) Less than 182.00) and do (Actions)
- Loop - Actions
- Unit Group - Add (Picked unit) to Chain
- Set BlockCheck = True
- Loop - Actions
- Unit Group - Pick every unit in (Units owned by (Owner of (Triggering unit)) matching ((((Matching unit) is A structure) Equal to True) and ((((Matching unit) is in Chain) Equal to False) and ((Distance between (Position of (Picked unit)) and (Position of (Matching unit))) Less than 182.00) and do (Actions)
- Loop - Actions
- If (BlockCheck Equal to True) then do (Trigger - Run (This trigger) (checking conditions)) else do (Trigger - Run Finally <gen> (checking conditions))
Trigger:
- Last
- Events
- Conditions
- Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Or - Any (Conditions) are true
- Conditions
- ((Number of units in (Units in 1RedPinkGreen L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1RedPinkGreen R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1RedPinkGreen L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Top Right <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1RedPinkGreen L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Bot R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Top L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1RedPinkGreen R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Top L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Top Right <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Top L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Bot R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Bot L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1RedPinkGreen R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Bot L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Top Right <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- ((Number of units in (Units in 1Red Bot L <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1) and ((Number of units in (Units in 1Red Bot R <gen> matching (((Matching unit) is in Chain) Equal to True))) Greater than or equal to 1)
- Conditions
- Or - Any (Conditions) are true
- Then - Actions
- Unit - Remove (Triggering unit) from the game
- Else - Actions
- Do nothing
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
+rep for help :thup: