[General] What leaks in 1.26?

Level 2
Joined
Jan 12, 2025
Messages
5
G'day mates
Do units leak? It's kind of hard to understand whether or not I need to null unit variables after use.
 
Generally speaking, units do not leak. The only case where unit itself would be considered to leak memory is when you create a dummy unit and do not remove/kill it afterwards. Since dummy units have Locust ability, it makes them invulnerable and unselectable by players. So if you do not kill/remove such unit, it would persist in the game, taking a bit of memory and processing power.

Nulling variables does not clear any leak, unless you are talking about local variables. But that would require you to use JASS scripts. GUI variables (globals) do not really leak anything.
 

I think it covers everything well. On the topic of units, I have heard some discussion of permanent leaks when there's too many units being used on the map (like hundreds of thousands) which is unavoidable, but I might be misremembering.
 
Back
Top