I have a “OnTriggerExit” that once the event is triggered, It would remove that Unit from a List, And at the same time it will Invoke another function " Invoke(“UpdateTarget”, 0);".
However, It is Possible that there are multiple Units that can trigger “OnTriggerExit”, Would it be possible, to only Invoke " Invoke(“UpdateTarget”, 0);" , if the Unit that exited the Trigger was my Target?
if the Unit gets destroyed, does that also count as an “OnTriggerExit”?
You might need a new UpdateTarget() function that accepts the other.gameObject to see if that’s the one it was targeting.
not sure, give it a try!That’s the beauty of Unity: you can test stuff SO easily and rapidly. Make a scene and a little script, set it up, then get it in the trigger area, and destroy it, see if you get the exit event.