- Joined
- Aug 7, 2013
- Messages
- 1,338
Hi,
If we want to destroy a trigger inside its own condition (preferably after it has done all its work), do we need to put the call in any particular spot?
e.g.
Here I made it the very last call, but what if I put it here
Will my local handles still leak? Or will the condition run to completion, and then destroy the trigger?
If we want to destroy a trigger inside its own condition (preferably after it has done all its work), do we need to put the call in any particular spot?
e.g.
JASS:
function main takes nothing returns boolean
//do some work
...
//clean up local handles
...
//destroy this trigger
call DestroyTrigger(GetTriggeringTrigger())
endfunction
Here I made it the very last call, but what if I put it here
JASS:
function main takes nothing returns boolean
//do some work
...
//destroy this trigger
call DestroyTrigger(GetTriggeringTrigger())
//clean up local handles
...
endfunction
Will my local handles still leak? Or will the condition run to completion, and then destroy the trigger?