Answers for "how to turn components on and off in unity through code"

C#
0

how to turn components on and off in unity through code

//enable
GetComponent<Collider>().enabled = true;

//disabled
GetComponent<Collider>().disabled = false;
Posted by: Guest on April-22-2021

Code answers related to "how to turn components on and off in unity through code"

C# Answers by Framework

Browse Popular Code Answers by Language