Removing Memory Leaks, Does Wiping over work?

Status
Not open for further replies.

PossiblyMatt

P

PossiblyMatt

I have read the basic tutorial on memory leaks and am now in the process of cleaning them up from my GUI triggers. What I would like to know is do i have to destroy the group/point reference after each use or can I overwrite it. i.e. If I were to create a line of units could I do

SetVariable: temppoint = position of triggering unit offset 100 towards 90.0 degrees
Unit: Create 1 footman at temppoint
SetVariable: temppoint = position of triggering unit offset 200 towards 90.0 degrees
Unit: Create 1 footman at temppoint
etc.
Custom Script: RemoveLocation( udg_temppoint)

Or should I remove the point each time

SetVariable: temppoint = position of triggering unit offset 100 towards 90.0 degrees
Unit: Create 1 footman at temppoint
Custom Script: RemoveLocation( udg_temppoint)
SetVariable: temppoint = position of triggering unit offset 200 towards 90.0 degrees
Unit: Create 1 footman at temppoint
Custom Script: RemoveLocation( udg_temppoint)
etc.

Any help will be appreciated.

PossiblyMatt
 
Thanks for the help everyone.
Now just to redo nearly every trigger in my map :P
 
Status
Not open for further replies.
Back
Top