Answer the question
In order to leave comments, you need to log in
How not to render the whole scene?
How to set the renderer to render only displayables and not the whole scene
public void OnCollisionStep2D(Collider col)
{
col.GetComponent<MeshRenderer>().enabled = true;
col.GetComponentInChildren<MeshRenderer>().enabled = true;
Debug.Log("На сцене ");
}
public void OnCollisionExit2D(Collider col)
{
col.GetComponent<MeshRenderer>().enabled = false;
col.GetComponentInChildren<MeshRenderer>().enabled = false;
Debug.Log("Вышел");
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question