Answer the question
In order to leave comments, you need to log in
How to remove a clone of an object when going out of the scene (2d)?
I started to study units and made a small semblance of a flappy bird.
And now the question is how to remove object clones (Pipes between which a bird flies), after they left the scene?
Answer the question
In order to leave comments, you need to log in
The simplest thing is to check by coordinates that the pipe is to the left of the bird, and remove it when the distance exceeds a certain threshold. The second option is to use Renderer.isVisible or Renderer.OnBecameInvisible to check if the pipe is on screen.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question