• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Leak?

Status
Not open for further replies.
Level 13
Joined
Mar 24, 2013
Messages
1,105
EDIT:---This trig has been all deleaked the ones I'm still having some problems with are at the end! :D Thanks!

Until only recently I've learned that Leaks can really cause problems, so through the various guides on here I'm attempting to stop all my leaks, and I just want to be sure I'm on the right track before I continue further, so if anyone could tell me if these triggers have all their leaks removed that would be great! (Also the spell does not need to be MUI)

  • Aurora Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [Sinister Seal] Aurora Beam
    • Actions
      • Set Aurora_Caster = (Triggering unit)
      • Set Aurora_Target = ((Position of (Casting unit)) offset by 1200.00 towards (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees)
      • Unit - Create 1 [Dummy] Aurora Beam Dummy for (Owner of Aurora_Caster) at (Position of Aurora_Caster) facing (Target point of ability being cast)
      • Set TempPoint = (Position of (Last created unit))
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Set AuroraDummy = (Last created unit)
      • Unit Group - Add AuroraDummy to AuroraDummyMove
      • Trigger - Turn on Aurora Move <gen>
      • Wait 3.00 seconds
      • Trigger - Turn off Aurora Move <gen>
      • Unit - Create 1 [Dummy] Arrow Dummy [No Model] for (Owner of Aurora_Caster) at (Position of (Random unit from AuroraEnemyMove)) facing Default building facing degrees
      • Set TempPoint = (Position of (Last created unit))
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
      • Unit - Add [Sinster Seal] Aurora Beam Slow to (Last created unit)
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova (Random unit from AuroraEnemyMove)
      • Unit - Remove AuroraDummy from the game
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Unit - Turn collision for (Picked unit) On)
      • Unit Group - Remove all units from AuroraEnemyMove
      • Set GroupVar = AuroraEnemyMove
      • Custom script: call DestroyGroup(udg_GroupVar)
  • Aurora Move
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in AuroraDummyMove and do (Actions)
        • Loop - Actions
          • Unit - Move AuroraDummy instantly to ((Position of AuroraDummy) offset by 15.00 towards (Angle from (Position of AuroraDummy) to Aurora_Target) degrees)
          • Set TempPoint = (Position of AuroraDummy)
          • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from (Position of AuroraDummy) to Aurora_Target) degrees)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
      • Set Aurora_DummyLoc = (Position of AuroraDummy)
      • Set TempPoint = (Position of AuroraDummy)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Set AuroraEnemyMove = (Units within 175.00 of Aurora_DummyLoc matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) belongs to an enemy of (Owner of Aurora_Caster)) Equal to True) and ((((Matching unit) is dead) Not equal to True) and ((Matching uni
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Actions)
        • Loop - Actions
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Move (Picked unit) instantly to ((Position of AuroraDummy) offset by 15.00 towards (Angle from (Position of (Picked unit)) to Aurora_Target) degrees)
          • Unit - Cause Aurora_Caster to damage (Picked unit), dealing (Real(((Level of [Sinister Seal] Aurora Beam for Aurora_Caster) + 1))) damage of attack type Spells and damage type Normal
 
Last edited:
Level 20
Joined
Apr 14, 2012
Messages
2,901
You already leaked in here:
  • Unit - Create 1 [Dummy] Aurora Beam Dummy for (Owner of Aurora_Caster) at (Position of Aurora_Caster) facing (Target point of ability being cast)
  • Unit - Create 1 [Dummy] Arrow Dummy [No Model] for (Owner of Aurora_Caster) at (Position of (Random unit from AuroraEnemyMove)) facing Default building facing degrees
  • Unit - Move AuroraDummy instantly to ((Position of AuroraDummy) offset by 15.00 towards (Angle from (Position of AuroraDummy) to Aurora_Target) degrees)
  • Unit - Move (Picked unit) instantly to ((Position of AuroraDummy) offset by 15.00 towards (Angle from (Position of (Picked unit)) to Aurora_Target) degrees)
You think you don't leak when you refer to the position of a stored unit variable, but your wrong. Store the locations in a variable always, especially in the (Position of unit)...
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Here is an updated trigger--I believe I fixed the things MasterTrainer said

@deathismyfriend
I have no reasoning behind doing this, just that from reading the "Things that Leak" forum guide I thought every time I made a unit at a location I'm supposed to set the position of where I made it, and then clear it. :vw_sad: Guess I'm wrong (although I left it in there for now)

  • Aurora Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [Sinister Seal] Aurora Beam
    • Actions
      • Set Aurora_Caster = (Triggering unit)
      • Set Aurora_CasterLoc = (Position of Aurora_Caster)
      • Set Aurora_Target = ((Position of (Casting unit)) offset by 1200.00 towards (Angle from (Position of (Triggering unit)) to (Target point of ability being cast)) degrees)
      • Unit - Create 1 [Dummy] Aurora Beam Dummy for (Owner of Aurora_Caster) at Aurora_CasterLoc facing (Target point of ability being cast)
      • Set TempPoint = (Position of (Last created unit))
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Set AuroraDummy = (Last created unit)
      • Unit Group - Add AuroraDummy to AuroraDummyMove
      • Trigger - Turn on Aurora Move <gen>
      • Wait 3.00 seconds
      • Trigger - Turn off Aurora Move <gen>
      • Unit - Create 1 [Dummy] Arrow Dummy [No Model] for (Owner of Aurora_Caster) at (Position of (Random unit from AuroraEnemyMove)) facing Default building facing degrees
      • Set AuroraEnemyMove_RandomUnitLoc = (Position of (Random unit from AuroraEnemyMove))
      • Set TempPoint = (Position of (Last created unit))
      • Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
      • Unit - Add [Sinster Seal] Aurora Beam Slow to (Last created unit)
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova (Random unit from AuroraEnemyMove)
      • Unit - Remove AuroraDummy from the game
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Unit - Turn collision for (Picked unit) On)
      • Unit Group - Remove all units from AuroraEnemyMove
      • Set GroupVar = AuroraEnemyMove
      • Custom script: call DestroyGroup(udg_GroupVar)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_Aurora_CasterLoc)
      • Custom script: call RemoveLocation(udg_AuroraEnemyMove_RandomUnitLoc)

  • Aurora Move
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in AuroraDummyMove and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of AuroraDummy)
          • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from (Position of AuroraDummy) to Aurora_Target) degrees)
          • Unit - Move AuroraDummy instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
      • Set Aurora_DummyLoc = (Position of AuroraDummy)
      • Set TempPoint = Aurora_DummyLoc
      • Set AuroraEnemyMove = (Units within 175.00 of Aurora_DummyLoc matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) belongs to an enemy of (Owner of Aurora_Caster)) Equal to True) and ((((Matching unit) is dead) Not equal to True) and ((Matching uni
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Actions)
        • Loop - Actions
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Move (Picked unit) instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Unit - Cause Aurora_Caster to damage (Picked unit), dealing (Real(((Level of [Sinister Seal] Aurora Beam for Aurora_Caster) + 1))) damage of attack type Spells and damage type Normal
      • Custom script: call RemoveLocation(udg_TempPoint)
 
Last edited:
this also doesnt make sense since u dont use tempPoint2

  • Set TempPoint = (Position of AuroraDummy)
  • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from (Position of AuroraDummy) to Aurora_Target) degrees)
  • Unit - Move AuroraDummy instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
  • Custom script: call RemoveLocation(udg_TempPoint)
  • Custom script: call RemoveLocation(udg_TempPoint2)
 
Level 5
Joined
May 6, 2013
Messages
125
Leaking things are marked with >>leak<<.Hope you see the pattern.

  • Aurora Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [Sinister Seal] Aurora Beam
    • Actions
      • Set Aurora_Caster = (Triggering unit)
      • Set Aurora_CasterLoc = (Position of Aurora_Caster)
      • Set Aurora_Target = (>>(Position of (Casting unit))<< offset by 1200.00 towards (Angle from >>(Position of (Triggering unit))<< to >>(Target point of ability being cast)<<) degrees)
      • Unit - Create 1 [Dummy] Aurora Beam Dummy for (Owner of Aurora_Caster) at Aurora_CasterLoc facing >>(Target point of ability being cast)<<
      • Set TempPoint = (Position of (Last created unit))
      • Custom script: call RemoveLocation(udg_TempPoint) //unused
      • Set AuroraDummy = (Last created unit)
      • Unit Group - Add AuroraDummy to AuroraDummyMove
      • Trigger - Turn on Aurora Move <gen>
      • Wait 3.00 seconds
      • Trigger - Turn off Aurora Move <gen>
      • Unit - Create 1 [Dummy] Arrow Dummy [No Model] for (Owner of Aurora_Caster) at >>(Position of (Random unit from AuroraEnemyMove))<< facing Default building facing degrees
      • Set AuroraEnemyMove_RandomUnitLoc = (Position of (Random unit from AuroraEnemyMove))
      • Set TempPoint = (Position of (Last created unit))
      • Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
      • Unit - Add [Sinster Seal] Aurora Beam Slow to (Last created unit)
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova (Random unit from AuroraEnemyMove)
      • Unit - Remove AuroraDummy from the game
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Unit - Turn collision for (Picked unit) On)
      • Unit Group - Remove all units from AuroraEnemyMove
      • Set GroupVar = AuroraEnemyMove
      • Custom script: call DestroyGroup(udg_GroupVar)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_Aurora_CasterLoc)
      • Custom script: call RemoveLocation(udg_AuroraEnemyMove_RandomUnitLoc)
  • Aurora Move
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in AuroraDummyMove and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of AuroraDummy)
          • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from >>(Position of AuroraDummy)<< to Aurora_Target) degrees) //again, unused
          • Unit - Move AuroraDummy instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
      • Set Aurora_DummyLoc = (Position of AuroraDummy)
      • Set TempPoint = Aurora_DummyLoc
      • Set AuroraEnemyMove = (Units within 175.00 of Aurora_DummyLoc matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) belongs to an enemy of (Owner of Aurora_Caster)) Equal to True) and ((((Matching unit) is dead) Not equal to True) and ((Matching uni
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Actions)
        • Loop - Actions
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Move (Picked unit) instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Unit - Cause Aurora_Caster to damage (Picked unit), dealing (Real(((Level of [Sinister Seal] Aurora Beam for Aurora_Caster) + 1))) damage of attack type Spells and damage type Normal
      • Custom script: call RemoveLocation(udg_TempPoint)

Besides those obvious leaks:
- AuroraEnemyMove seems not to be erased in the periodic trigger at all, while beeing used, erased but not initialised in the main trigger. So, unless every 0.04 seconds someone casts that spell, you leak that unit group.
- Aurora_Target will leak every time you recast that spell as it is not destroyed at all
- your attempts to fix the leaks seem rather random to me. Maybe a thread with a name like "What leak actually is" would be more helpful than one telling you "things that leak without telling what a leak is, why it leaks and how you can see if things leak"
 
Last edited by a moderator:
Level 13
Joined
Mar 24, 2013
Messages
1,105
@Imp Midna -- My attempted fixes at leaks are borderline guesses, I'm still not exactly sure what a leak REALLY is, or how I can tell if it leaks by myself without having to waste other peoples time assisting me. About the AuroraEnemyMove, if
  • Set GroupVar = AuroraEnemyMove
  • Custom script: call DestroyGroup(udg_GroupVar)
is inadequate, how do I properly remove the leak?

Thanks!

  • Aurora Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [Sinister Seal] Aurora Beam
    • Actions
      • Set Aurora_Caster = (Triggering unit)
      • Set Aurora_CasterLoc = (Position of Aurora_Caster)
      • Set Aurora_TargetPoint = (Target point of ability being cast)
      • Set Aurora_Target = (Aurora_CasterLoc offset by 1200.00 towards (Angle from Aurora_CasterLoc to Aurora_TargetPoint) degrees)
      • Unit - Create 1 [Dummy] Aurora Beam Dummy for (Owner of Aurora_Caster) at Aurora_CasterLoc facing Aurora_TargetPoint
      • Set AuroraDummy = (Last created unit)
      • Unit Group - Add AuroraDummy to AuroraDummyMove
      • Trigger - Turn on Aurora Move <gen>
      • Wait 3.00 seconds
      • Trigger - Turn off Aurora Move <gen>
      • Set AuroraEnemyMove_RandomUnitLoc = (Position of (Random unit from AuroraEnemyMove))
      • Unit - Create 1 [Dummy] Arrow Dummy [No Model] for (Owner of Aurora_Caster) at AuroraEnemyMove_RandomUnitLoc facing Default building facing degrees
      • Set TempPoint = (Position of (Last created unit))
      • Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
      • Unit - Add [Sinster Seal] Aurora Beam Slow to (Last created unit)
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova (Random unit from AuroraEnemyMove)
      • Unit - Remove AuroraDummy from the game
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Unit - Turn collision for (Picked unit) On)
      • Unit Group - Remove all units from AuroraEnemyMove
      • Set GroupVar = AuroraEnemyMove
      • Custom script: call DestroyGroup(udg_GroupVar)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_Aurora_CasterLoc)
      • Custom script: call RemoveLocation(udg_AuroraEnemyMove_RandomUnitLoc)
      • Custom script: call RemoveLocation(udg_Aurora_TargetPoint)
      • Custom script: call RemoveLocation(udg_Aurora_Target)
  • Aurora Move
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in AuroraDummyMove and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of AuroraDummy)
          • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Unit - Move AuroraDummy instantly to TempPoint2
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
      • Set Aurora_DummyLoc = (Position of AuroraDummy)
      • Set TempPoint = Aurora_DummyLoc
      • Set AuroraEnemyMove = (Units within 175.00 of Aurora_DummyLoc matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) belongs to an enemy of (Owner of Aurora_Caster)) Equal to True) and ((((Matching unit) is dead) Not equal to True) and ((Matching uni
      • Unit Group - Pick every unit in AuroraEnemyMove and do (Actions)
        • Loop - Actions
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Move (Picked unit) instantly to (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
          • Unit - Cause Aurora_Caster to damage (Picked unit), dealing (Real(((Level of [Sinister Seal] Aurora Beam for Aurora_Caster) + 1))) damage of attack type Spells and damage type Normal
      • Custom script: call RemoveLocation(udg_TempPoint)
 
Level 20
Joined
Apr 14, 2012
Messages
2,901
@Imp Midna -- My attempted fixes at leaks are borderline guesses, I'm still not exactly sure what a leak REALLY is, or how I can tell if it leaks by myself without having to waste other peoples time assisting me. About the AuroraEnemyMove, if
  • Set GroupVar = AuroraEnemyMove
  • Custom script: call DestroyGroup(udg_GroupVar)
is inadequate, how do I properly remove the leak?

Why did you set the group variable to a value, then destroyed it immediately?
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
What I thought I understood was, you set this "GroupVar"
to the name of your Unit Group you want removed, and then Destroy it, removing the problem.

  • Set GroupVar = Pick every unit in (Playable Map Area)
  • Unit Group - Pick every unit in GroupVar and do (Unit - Hide (Picked unit))
  • Custom script: call DestroyGroup(udg_GroupVar)
^This is from the "Things that Leak" post, so I just figured that's what you did :goblin_cry:
 
Level 20
Joined
Apr 14, 2012
Messages
2,901
What I thought I understood was, you set this "GroupVar"
to the name of your Unit Group you want removed, and then Destroy it, removing the problem.

  • Set GroupVar = Pick every unit in (Playable Map Area)
  • Unit Group - Pick every unit in GroupVar and do (Unit - Hide (Picked unit))
  • Custom script: call DestroyGroup(udg_GroupVar)
^This is from the "Things that Leak" post, so I just figured that's what you did :goblin_cry:

Technically this would remove the leak, but you could also do this:

  • Set GroupVar = Pick every unit in (Playable Map Area)
    • Custom Script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in GroupVar and do (Unit - Hide (Picked unit))
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Ugh, I'm still not understanding how they are leaking, is there anyway you could spell it out exactly what I'm doing incorrectly? Because truly I'm not understanding what I'm doing improperly.

Also...probably why this one still leaks for me, but what am I doing wrong in this OTHER trigger? I'm trying to remove the leaks, because it has noticeable FPS drop after about 10 casts, and I thought I was doing it properly :/.

  • Boats
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [UD] Boats (Caster)
    • Actions
      • Set TempPoint = (Position of (Triggering unit))
      • Set TempPoint2 = (Target point of ability being cast)
      • Unit - Create 1 [Dummy] Boats for (Owner of (Triggering unit)) at TempPoint facing TempPoint
      • Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
      • Unit - Add [UD] Boats (Dummy) to (Last created unit)
      • Unit - Set level of [UD] Boats (Dummy) for (Last created unit) to (Level of [UD] Boats (Caster) for (Triggering unit))
      • Unit - Order (Last created unit) to Neutral Beastmaster - Stampede TempPoint2
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_TempPoint2)
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
the only thing u can do for this trigger is to save last created unit into a variable and use that. Other than that this doesnt leak.

What exactly do mean by this? Am I setting my dummy unit to a unit variable? How would I go about clearing this?? (Because I set it to a variable but it still drops my FPS quite low after multiple casts)

  • Boats
  • Events
  • Unit - A unit Starts the effect of an ability
  • Conditions
  • (Ability being cast) Equal to [UD] Boats (Caster)
  • Actions
  • Set TempPoint = (Position of (Triggering unit))
  • Set TempPoint2 = (Target point of ability being cast)
  • Unit - Create 1 [Dummy] Boats for (Owner of (Triggering unit)) at TempPoint facing TempPoint
  • Set Boat_Dummy = (Last created unit)
  • Unit - Add a 5.00 second Generic expiration timer to Boat_Dummy
  • Unit - Add [UD] Boats (Dummy) to Boat_Dummy
  • Unit - Set level of [UD] Boats (Dummy) for Boat_Dummy to (Level of [UD] Boats (Caster) for (Triggering unit))
  • Unit - Order Boat_Dummy to Neutral Beastmaster - Stampede TempPoint2
  • Custom script: call RemoveLocation(udg_TempPoint)
  • Custom script: call RemoveLocation(udg_TempPoint2)
this (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) creates a new point so u need to store it into a variable.

And is this not being set to TempPoint2 and then being cleared??
  • Set TempPoint = (Position of AuroraDummy)
  • Set TempPoint2 = (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target) degrees)
  • Unit - Move AuroraDummy instantly to TempPoint2
  • Custom script: call RemoveLocation(udg_TempPoint)
  • Custom script: call RemoveLocation(udg_TempPoint2)
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Second thing look in ur trigger when u use that thing I posted again and didn't set it to a variable....

Please state exactly what you mean, I'm sure this is simple for you, but I'm feeling clueless as to what you're saying...

I think you're saying that this

  • (TempPoint offset by 15.00 towards (Angle from TempPoint to Aurora_Target)
is supposed to set to a variable, but then again.. I did set this exact thing to TempPoint2...so maybe not.

Am I supposed to somehow save "Angle from TempPoint to Aurora_Target" to a variable? (Cause I can't figure out how to do that)

So confused :vw_sad:
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Well thank you for that nugget of knowledge :p, but I was wondering about my original trigger, unless you're saying that one is fine also?

But I thought I learned from what you'd been saying but this other trigger also causes lag and I'm not sure why xD...I'm gonna +rep you now so hopefully I can do it again since you've been such a HUGE help to me!

  • Combustion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [AW] Combustion
    • Actions
      • Set Combustion_Damage = False
      • Set Combustion_Caster = (Triggering unit)
      • Set Combustion_CasterLoc2 = (Position of (Triggering unit))
      • Set Combustion_Target2 = (Target point of ability being cast)
      • Set Combustion_Target = (Combustion_CasterLoc2 offset by 1200.00 towards (Angle from Combustion_CasterLoc2 to Combustion_Target2) degrees)
      • Unit - Create 1 Ball for (Owner of Combustion_Caster) at Combustion_CasterLoc2 facing Combustion_Target2
      • Unit - Add a 1.05 second Generic expiration timer to (Last created unit)
      • Set Combustion_Dummy = (Last created unit)
      • Trigger - Turn on Combustion Move <gen>
      • Wait until (((Combustion_Dummy is alive) Not equal to True) or (Combustion_Damage Equal to True)), checking every 0.10 seconds
      • Unit - Set the custom value of (Random unit from Combustion_RandomUnit) to (Integer(((Max mana of (Random unit from Combustion_RandomUnit)) - (Mana of (Random unit from Combustion_RandomUnit)))))
      • Unit - Cause Combustion_Caster to damage (Random unit from Combustion_RandomUnit), dealing (Real((Custom value of (Random unit from Combustion_RandomUnit)))) damage of attack type Chaos and damage type Universal
      • Special Effect - Create a special effect attached to the origin of (Random unit from Combustion_RandomUnit) using Abilities\Spells\Human\Feedback\ArcaneTowerAttack.mdl
      • Special Effect - Destroy (Last created special effect)
      • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
      • Floating Text - Create floating text that reads (String((Real((Custom value of (Random unit from Combustion_RandomUnit)))))) at TempPoint with Z offset 0.00, using font size 10.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Change the lifespan of (Last created floating text) to 2.00 seconds
      • Set Combustion_Dummy = No unit
      • Custom script: call RemoveLocation(udg_Combustion_Target)
      • Custom script: call RemoveLocation(udg_Combustion_Target2)
      • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
      • Custom script: call RemoveLocation(udg_TempPoint)
  • Combustion Move
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set TempPoint = (Position of Combustion_Dummy)
      • Unit - Move Combustion_Dummy instantly to (TempPoint offset by 35.00 towards (Angle from TempPoint to Combustion_Target) degrees)
      • Set Combustion_UnitGroup = (Units within 55.00 of TempPoint matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of Combustion_Dummy)) Equal to True))))
      • Set Combustion_RandomUnit = (Random 1 units from Combustion_UnitGroup)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in Combustion_UnitGroup) Equal to 1
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Unit - Kill Combustion_Dummy
          • Set Combustion_Damage = True
        • Else - Actions
      • Custom script: call RemoveLocation(udg_TempPoint)
 
it might be lagging because of this action
  • Wait until (((Combustion_Dummy is alive) Not equal to True) or (Combustion_Damage Equal to True)), checking every 0.10 seconds
Also it is not MUI and will bug up.
You should make it index so that it will be MUI and u dont have to worry about it.
Remove the wait. You shouldnt use waits in a spell. unless its a one cast only spell. I still dont like any spell being non-MUI, unless it can only be MPI.

Also thanks for the rep
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Well by "lag" I mean a drop in FPS, by the 10th cast or so on this spell my FPS drops from ~60 to ~40 and it continues to drop the more I cast, so I'm assuming I'm leaking. But I don't see where. Only 1 hero has this ability and only 1 hero of this type is ever alive at any given time, so MUI is not really needed, besides I don't know how to index :p.

  • Combustion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [AW] Combustion
    • Actions
      • Set Combustion_Caster = (Triggering unit)
      • Set Combustion_CasterLoc2 = (Position of (Triggering unit))
      • Set Combustion_Target2 = (Target point of ability being cast)
      • Set Combustion_Target = (Combustion_CasterLoc2 offset by 1200.00 towards (Angle from Combustion_CasterLoc2 to Combustion_Target2) degrees)
      • Unit - Create 1 Ball for (Owner of Combustion_Caster) at Combustion_CasterLoc2 facing Combustion_Target2
      • Unit - Add a 1.05 second Generic expiration timer to (Last created unit)
      • Set Combustion_Dummy = (Last created unit)
      • Trigger - Turn on Combustion Move <gen>
  • Combustion Move
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set TempPoint = (Position of Combustion_Dummy)
      • Unit - Move Combustion_Dummy instantly to (TempPoint offset by 35.00 towards (Angle from TempPoint to Combustion_Target) degrees)
      • Set Combustion_DummyLoc = (Position of Combustion_Dummy)
      • Set Combustion_UnitGroup = (Units within 55.00 of TempPoint matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of Combustion_Dummy)) Equal to True))))
      • Set Combustion_RandomUnit = (Random 1 units from Combustion_UnitGroup)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in Combustion_UnitGroup) Equal to 1
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Unit - Kill Combustion_Dummy
          • Unit - Set the custom value of (Random unit from Combustion_RandomUnit) to (Integer(((Max mana of (Random unit from Combustion_RandomUnit)) - (Mana of (Random unit from Combustion_RandomUnit)))))
          • Unit - Cause Combustion_Caster to damage (Random unit from Combustion_RandomUnit), dealing (Real((Custom value of (Random unit from Combustion_RandomUnit)))) damage of attack type Chaos and damage type Universal
          • Special Effect - Create a special effect attached to the origin of (Random unit from Combustion_RandomUnit) using Abilities\Spells\Human\Feedback\ArcaneTowerAttack.mdl
          • Special Effect - Destroy (Last created special effect)
          • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
          • Floating Text - Create floating text that reads (String((Real((Custom value of (Random unit from Combustion_RandomUnit)))))) at TempPoint with Z offset 0.00, using font size 10.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Change the lifespan of (Last created floating text) to 2.00 seconds
          • Custom script: call RemoveLocation(udg_Combustion_Target)
          • Custom script: call RemoveLocation(udg_Combustion_Target2)
          • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
          • Custom script: call RemoveLocation(udg_TempPoint)
        • Else - Actions
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
No my hero cannot cast the spell before the previous one has run its cycle.
I set the custom value so I can easily calculate the missing mana from the unit that gets hit by the spell. Does custom value leak? Or do I need to set it to null somehow? I'm not sure exactly how I would do that, I'm kind of just talking xD.

I went to the "Things a GUI user should know" and to debugging, but I didn't see this handle Counter you are referring too, am I looking in the proper place?
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
I'm trying to do that set up the trigger but I cant find the Key Location part of the below >.< and I can't comment on that post because its closed, would you happen to know how I get to it?

  • Game - Display to (All players) the text: (String((Key (Location)) - 1048576))
 
ok here post this in a blank converted trigger. Name the trigger HandleCounter

this will run every .09 seconds. Also u only have a leak if the number rapidly rises and doesnt go back down.
JASS:
function HandleCount takes nothing returns nothing
    local location L = Location(0,0)
    call BJDebugMsg(I2S(GetHandleId(L)-0x100000))
    call RemoveLocation(L)
    set L = null
endfunction

//===========================================================================
function InitTrig_HandleCounter takes nothing returns nothing
    local trigger t = CreateTrigger()
    call TriggerRegisterTimerEvent(t,0.09,true)
    call TriggerAddAction(t,function HandleCount)
    set t = null
endfunction
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Okay with using this Handle Counter Trigger my map starts out at 3303.. does that mean I have over three thousand leaks before the game even starts :goblin_jawdrop:?

And my spell shoots that number out of a cannon it increases very quickly after being cast... :(.. I also checked with a few of my other spells and many of them increase the number by about 50 or so and then chop it back down by like 30.. Is this reasonable ? I mean if spells were made with better triggering would this be closer to 0?
 
Okay with using this Handle Counter Trigger my map starts out at 3303.. does that mean I have over three thousand leaks before the game even starts :goblin_jawdrop:?

no like i said only if it rapidly rises and never falls is it leaking. That number comes from the amount of doodads / units / anything else u have at map init.

And my spell shoots that number out of a cannon it increases very quickly after being cast... :(.. I also checked with a few of my other spells and many of them increase the number by about 50 or so and then chop it back down by like 30.. Is this reasonable ? I mean if spells were made with better triggering would this be closer to 0?

Cast ur spell once and see what the number drops back down to. Does it drop back down close to the 3303 ?
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
The number rises rapidly after 1 cast and does not go back down.


Also...I have a few periodic triggers that run that check like if a unit has a specific buff. I initially disabled all of these to check my spell, but I wanted to see what happened if I left them on, and they seem to be leaking because the Handle # rises and never goes back down.
 


  • Set Combustion_UnitGroup = (Units within 55.00 of TempPoint matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of Combustion_Dummy)) Equal to True))))
after u select the random unit from the group destroy the group with this.
  • Custom script: call DestroyGroup( udg_Combustion_UnitGroup)
then null it after.
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Well...Everytime I cast my spell the Handle Counter increases by 100 if I hit a unit from max range~/ or let it time out. (less if it hits a unit earlier in which case its like 50 or so)
I believe this to mean I'm leaking 100 times. Is there something I'm just still not seeing?

Here's an updated trigger

  • Combustion New2
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [AW] Combustion
    • Actions
      • Set Combustion_Caster = (Triggering unit)
      • Set Combustion_CasterLoc2 = (Position of (Triggering unit))
      • Set Combustion_Target2 = (Target point of ability being cast)
      • Set Combustion_Target = (Combustion_CasterLoc2 offset by 1200.00 towards (Angle from Combustion_CasterLoc2 to Combustion_Target2) degrees)
      • Unit - Create 1 Ball for (Owner of Combustion_Caster) at Combustion_CasterLoc2 facing Combustion_Target2
      • Unit - Add a 1.05 second Generic expiration timer to (Last created unit)
      • Set Combustion_Dummy = (Last created unit)
      • Trigger - Turn on Combustion Move New2 <gen>
  • Combustion Move New2
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set TempPoint = (Position of Combustion_Dummy)
      • Unit - Move Combustion_Dummy instantly to (TempPoint offset by 35.00 towards (Angle from TempPoint to Combustion_Target) degrees)
      • Set Combustion_UnitGroup = (Units within 55.00 of TempPoint matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of Combustion_Dummy)) Equal to True))))
      • Set Combustion_RandomUnit = (Random 1 units from Combustion_UnitGroup)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in Combustion_UnitGroup) Equal to 1
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Unit - Kill Combustion_Dummy
          • Set Combustion_CusUnit = (Random unit from Combustion_RandomUnit)
          • Unit - Set the custom value of Combustion_CusUnit to (Integer(((Max mana of Combustion_CusUnit) - (Mana of Combustion_CusUnit))))
          • Unit - Cause Combustion_Caster to damage Combustion_CusUnit, dealing (Real((Custom value of Combustion_CusUnit))) damage of attack type Chaos and damage type Universal
          • Special Effect - Create a special effect attached to the origin of (Random unit from Combustion_RandomUnit) using Abilities\Spells\Human\Feedback\ArcaneTowerAttack.mdl
          • Special Effect - Destroy (Last created special effect)
          • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
          • Floating Text - Create floating text that reads (String((Real((Custom value of (Random unit from Combustion_RandomUnit)))))) at TempPoint with Z offset 0.00, using font size 10.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Change the lifespan of (Last created floating text) to 2.00 seconds
          • Custom script: call RemoveLocation(udg_Combustion_Target)
          • Custom script: call RemoveLocation(udg_Combustion_Target2)
          • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call DestroyGroup(udg_Combustion_UnitGroup)
          • Custom script: call DestroyGroup(udg_Combustion_RandomUnit)
          • Custom script: set udg_Combustion_UnitGroup = null
          • Custom script: set udg_Combustion_RandomUnit = null
          • Set Combustion_Dummy = No unit
          • Skip remaining actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Combustion_Dummy is alive) Not equal to True
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
          • Custom script: call RemoveLocation(udg_Combustion_Target)
          • Custom script: call RemoveLocation(udg_Combustion_Target2)
          • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call DestroyGroup(udg_Combustion_UnitGroup)
          • Custom script: call DestroyGroup(udg_Combustion_RandomUnit)
          • Custom script: set udg_Combustion_UnitGroup = null
          • Custom script: set udg_Combustion_RandomUnit = null
          • Set Combustion_Dummy = No unit
        • Else - Actions

Also, why are this groups leaking? I'm destroying all the groups, but its still..?
  • Dragons Claw Knockback
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DragonsClaw Equal to No unit
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Set DragonClaw_UnitGroup = (Units in (Playable map area) matching (((Matching unit) has buff Dragon's Claw Stun ) Equal to True))
      • Unit Group - Pick every unit in DragonClaw_UnitGroup and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of (Picked unit))
          • Set TempPoint2 = (Position of DragonsClaw)
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Cause DragonsClaw to damage (Picked unit), dealing 2.00 damage of attack type Spells and damage type Normal
          • Special Effect - Create a special effect at TempPoint using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Unit - Move (Picked unit) instantly to (TempPoint offset by 8.00 towards (Angle from TempPoint2 to TempPoint) degrees)
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Unit Group - Add (Picked unit) to DragonsClawEnemies
      • Unit Group - Pick every unit in DragonsClawEnemies and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Dragon's Claw Stun ) Equal to False
            • Then - Actions
              • Unit - Turn collision for (Picked unit) On
              • Unit Group - Remove (Picked unit) from DragonsClawEnemies
            • Else - Actions
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_TempPoint2)
      • Custom script: call DestroyGroup(udg_DragonClaw_UnitGroup)
      • Custom script: set udg_DragonClaw_UnitGroup = null
      • Custom script: call DestroyGroup(udg_DragonsClawEnemies)
      • Custom script: set udg_DragonsClawEnemies = null
 
Last edited:
Level 13
Joined
Mar 24, 2013
Messages
1,105
This is what you're asking about
  • Special Effect Destruction
    • Events
    • Conditions
    • Actions
      • Custom script: local effect tempEffect
      • Custom script: set tempEffect = udg_SpecialFX
      • Wait 3.00 game-time seconds
      • Custom script: set udg_SpecialFX = tempEffect
      • Special Effect - Destroy SpecialFX
What 2 points am I leaking?
 
right in here.
  • Unit Group - Pick every unit in DragonClaw_UnitGroup and do (Actions)
  • Loop - Actions
  • Set TempPoint = (Position of (Picked unit))
  • Set TempPoint2 = (Position of DragonsClaw)
  • Unit - Turn collision for (Picked unit) Off
  • Unit - Cause DragonsClaw to damage (Picked unit), dealing 2.00 damage of attack type Spells and damage type Normal
  • Special Effect - Create a special effect at TempPoint using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
  • Set SpecialFX = (Last created special effect)
  • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
  • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
  • Set SpecialFX = (Last created special effect)
  • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
  • Unit - Move (Picked unit) instantly to (TempPoint offset by 8.00 towards (Angle from TempPoint2 to TempPoint) degrees)
  • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
  • Set SpecialFX = (Last created special effect)
  • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
  • Unit Group - Add (Picked unit) to DragonsClawEnemies
u leak every unit that is in there except if there is only one unit in there.
every time u set a new location u need to remove the old one.
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
  • Dragons Claw Knockback
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DragonsClaw Equal to No unit
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Set DragonClaw_UnitGroup = (Units in (Playable map area) matching (((Matching unit) has buff Dragon's Claw Stun ) Equal to True))
      • Unit Group - Pick every unit in DragonClaw_UnitGroup and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of (Picked unit))
          • Set TempPoint2 = (Position of DragonsClaw)
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Cause DragonsClaw to damage (Picked unit), dealing 2.00 damage of attack type Spells and damage type Normal
          • Special Effect - Create a special effect at TempPoint using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Unit - Move (Picked unit) instantly to (TempPoint offset by 8.00 towards (Angle from TempPoint2 to TempPoint) degrees)
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Unit Group - Add (Picked unit) to DragonsClawEnemies
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
      • Unit Group - Pick every unit in DragonsClawEnemies and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Dragon's Claw Stun ) Equal to False
            • Then - Actions
              • Unit - Turn collision for (Picked unit) On
              • Unit Group - Remove (Picked unit) from DragonsClawEnemies
            • Else - Actions
      • Custom script: call DestroyGroup(udg_DragonClaw_UnitGroup)
      • Custom script: set udg_DragonClaw_UnitGroup = null
      • Custom script: call DestroyGroup(udg_DragonsClawEnemies)
      • Custom script: set udg_DragonsClawEnemies = null
I thought this would solve the problem but I guess not...cause it still leaks...why? ;o
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
  • Dragons Claw Knockback
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DragonsClaw Equal to No unit
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Set DragonClaw_UnitGroup = (Units in (Playable map area) matching (((Matching unit) has buff Dragon's Claw Stun ) Equal to True))
      • Unit Group - Pick every unit in DragonClaw_UnitGroup and do (Actions)
        • Loop - Actions
          • Set TempPoint = (Position of (Picked unit))
          • Set TempPoint2 = (Position of DragonsClaw)
          • Unit - Turn collision for (Picked unit) Off
          • Unit - Cause DragonsClaw to damage (Picked unit), dealing 2.00 damage of attack type Spells and damage type Normal
          • Special Effect - Create a special effect at TempPoint using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Set TempPoint3 = (TempPoint offset by 8.00 towards (Angle from TempPoint2 to TempPoint) degrees)
          • Unit - Move (Picked unit) instantly to TempPoint3
          • Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
          • Set SpecialFX = (Last created special effect)
          • Trigger - Run Special Effect Destruction <gen> (ignoring conditions)
          • Unit Group - Add (Picked unit) to DragonsClawEnemies
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_TempPoint2)
          • Custom script: call RemoveLocation(udg_TempPoint3)
      • Unit Group - Pick every unit in DragonsClawEnemies and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Dragon's Claw Stun ) Equal to False
            • Then - Actions
              • Unit - Turn collision for (Picked unit) On
              • Unit Group - Remove (Picked unit) from DragonsClawEnemies
            • Else - Actions
      • Custom script: call DestroyGroup(udg_DragonClaw_UnitGroup)
      • Custom script: set udg_DragonClaw_UnitGroup = null
      • Custom script: call DestroyGroup(udg_DragonsClawEnemies)
      • Custom script: set udg_DragonsClawEnemies = null
Its significantly less, its at 10 leaks a second now...? and I'm very confident is actually this trigger as once the "DragonClaw is not equal to no unit" is false the Handle Counter grows

  • Combustion New2
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to [AW] Combustion
    • Actions
      • Set Combustion_Caster = (Triggering unit)
      • Set Combustion_CasterLoc2 = (Position of (Triggering unit))
      • Set Combustion_Target2 = (Target point of ability being cast)
      • Set Combustion_Target = (Combustion_CasterLoc2 offset by 1200.00 towards (Angle from Combustion_CasterLoc2 to Combustion_Target2) degrees)
      • Unit - Create 1 ManaDamage for (Owner of Combustion_Caster) at Combustion_CasterLoc2 facing Combustion_Target2
      • Unit - Add a 1.05 second Generic expiration timer to (Last created unit)
      • Set Combustion_Dummy = (Last created unit)
      • Trigger - Turn on Combustion Move New2 <gen>
  • Combustion Move New2
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set TempPoint = (Position of Combustion_Dummy)
      • Set TempPoint2 = (TempPoint offset by 35.00 towards (Angle from TempPoint to Combustion_Target) degrees)
      • Unit - Move Combustion_Dummy instantly to TempPoint2
      • Set Combustion_UnitGroup = (Units within 55.00 of TempPoint matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of Combustion_Dummy)) Equal to True))))
      • Set Combustion_RandomUnit = (Random 1 units from Combustion_UnitGroup)
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: call RemoveLocation(udg_TempPoint2)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in Combustion_UnitGroup) Equal to 1
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Unit - Kill Combustion_Dummy
          • Set Combustion_CusUnit = (Random unit from Combustion_RandomUnit)
          • Unit - Set the custom value of Combustion_CusUnit to (Integer(((Max mana of Combustion_CusUnit) - (Mana of Combustion_CusUnit))))
          • Unit - Cause Combustion_Caster to damage Combustion_CusUnit, dealing (Real((Custom value of Combustion_CusUnit))) damage of attack type Chaos and damage type Universal
          • Special Effect - Create a special effect attached to the origin of (Random unit from Combustion_RandomUnit) using Abilities\Spells\Human\Feedback\ArcaneTowerAttack.mdl
          • Special Effect - Destroy (Last created special effect)
          • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
          • Floating Text - Create floating text that reads (String((Real((Custom value of (Random unit from Combustion_RandomUnit)))))) at TempPoint with Z offset 0.00, using font size 10.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Change the lifespan of (Last created floating text) to 2.00 seconds
          • Custom script: call RemoveLocation(udg_Combustion_Target)
          • Custom script: call RemoveLocation(udg_Combustion_Target2)
          • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call DestroyGroup(udg_Combustion_UnitGroup)
          • Custom script: call DestroyGroup(udg_Combustion_RandomUnit)
          • Custom script: set udg_Combustion_UnitGroup = null
          • Custom script: set udg_Combustion_RandomUnit = null
          • Set Combustion_Dummy = No unit
          • Skip remaining actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Combustion_Dummy is alive) Not equal to True
        • Then - Actions
          • Trigger - Turn off (This trigger)
          • Set TempPoint = (Position of (Random unit from Combustion_RandomUnit))
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Custom script: call RemoveLocation(udg_Combustion_Target)
          • Custom script: call RemoveLocation(udg_Combustion_Target2)
          • Custom script: call RemoveLocation(udg_Combustion_CasterLoc2)
          • Custom script: call DestroyGroup(udg_Combustion_UnitGroup)
          • Custom script: call DestroyGroup(udg_Combustion_RandomUnit)
          • Custom script: set udg_Combustion_UnitGroup = null
          • Custom script: set udg_Combustion_RandomUnit = null
          • Set Combustion_Dummy = No unit
        • Else - Actions
These 2 are together and seem to be leaking ,sometimes its next to nothing and other times it 100,either way after a few casts fps drops big time.

Any help would be awesome!
Thanks!
 
Last edited:
Status
Not open for further replies.
Top