Can anyone tell me how I can destroy GameObjects once they go offscreen? Is there a method off the camera that I can use to find out if a GameObject is inside the view frustum?
Hi!
ScreenToWorldPos, or WorldToScreenPos (dont remember well) if the object returns a position that is not in the screen of the game, then you can destroy it
cheers!
Juan Sebastian Muñoz
There’s also a callback function for when an object is no longer visible by any camera.
Thanks for the replies.
OnBecameInvisible is perfect.