HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Pick every unit in unit group: Memory Leak

11-10-2004, 08:24 PM#1
BanishedSoull
I know that the action 'Pick Every Unt in Unit Group and do Actions' causes memory leaks, but i am wondering how to not have the memory leaks while still preferably having the trigger in GUI using the 'Custom Script' action. Thanks in advance for your help
11-10-2004, 08:55 PM#2
AFB-DieHard
CustomScript:
Code:
call DestroyGroup(GetLastCreatedGroup())
should work
11-10-2004, 09:07 PM#3
BanishedSoull
thx, ill try it as soon as i can
11-11-2004, 01:49 AM#4
CCrew
Quote:
Originally Posted by BanishedSoull
I know that the action 'Pick Every Unt in Unit Group and do Actions' causes memory leaks, but i am wondering how to not have the memory leaks while still preferably having the trigger in GUI using the 'Custom Script' action. Thanks in advance for your help
By making custom script that makes it jass......
11-11-2004, 02:53 PM#5
a thing
What I do is I have a global TempGroup and before all unit group actions I set TempGroup to what units I want picked and use TempGroup in the unit group loop. ex:

Set TempGroup = (All units in (Playable map area))
Unit group - Pick all units in TempGroup and do
-stuff

Even though TempGroup isn't destroied it won't leak unless that the last time it'll be used since it's will be set to something else later and used again.

I also do this for points.