• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Question about DestroyGroup Leak

Status
Not open for further replies.
Level 8
Joined
Jun 25, 2010
Messages
153
I know how to destroy leaks in Unit Group triggers, what from the countless threads about it. But a lot of these threads and tutorials don't seem to tell me one simple piece of information I really want to know before I get in Cinematic Triggering work.

Does bj_wantDestroyGroup = true or call destroygroup. Actually, destroy the Unit Group variable?

Can I still use the variable after doing this leak for another/different Unit Group? Or do I have to create countless Unit Group variables for every single unit group I will have?

Does it destroy the leak and the current group, or does it destroy the leak and the variable itself?
 
Level 8
Joined
Jun 25, 2010
Messages
153
It destroys the group not the variable. It sets the group to null. The variable may be used again but you will need to populate it first.

The leak would only happen if you set unit group = some_group and then later set it to = some_other_group without destroying it.

Ah, so it just empties the variable. The leak only occurs if I set it to else what when It already is something. Thanks for the explanation!
 
Status
Not open for further replies.
Top