Simple memory leak problem

canons200

New Member
Reaction score
50
as we know,
unit in range matching condition >> leak
unit in entire map matching condition >> wont leak
unit in entire map ? leak or wont leak?
 

skyblader

You're living only because it's illegal killing.
Reaction score
159
As long as you're selecting units using unit group, it leaks. All 3 of them leaks. Before using it, just set it to a variable.

Set UnitGroupVariable = Units in range/region
call DestroyGroup(udg_UnitGroupVariable)
 

canons200

New Member
Reaction score
50
As long as you're selecting units using unit group, it leaks. All 3 of them leaks. Before using it, just set it to a variable.

Set UnitGroupVariable = Units in range/region
call RemoveLocation(udg_UnitGroupVariable)
oh ya, i forget that i am doing unitgroup rather than unit, thank for the quick help.
 

Azlier

Old World Ghost
Reaction score
461
Using many of the unit groups in GUI always leaks. No matter what. Absolutely nothing can be done to remedy the issue besides changing GUI itself.

The problem can be lessened by destroying the unit group with a native like one does with locations. In other words, DestroyGroup.
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top