I found a good alternative, so I want to share it.
https://docs.unity3d.com/ScriptReference/MonoBehaviour.OnBecameInvisible.html
public class Laser : MonoBehaviour
{
void OnBecameInvisible()
{
Destroy(gameObject);
}
}
I found a good alternative, so I want to share it.
https://docs.unity3d.com/ScriptReference/MonoBehaviour.OnBecameInvisible.html
public class Laser : MonoBehaviour
{
void OnBecameInvisible()
{
Destroy(gameObject);
}
}
Nice. Reminds me of a recent article about rendering efficiency in modern games (Kotaku article). I guess this would be used to implement Frustum Culling, which I learnt about in the aforementioned article.