unity desactivate collider code example Example: unity desactivate collider gameObject.GetComponent<Collider>().enabled = false;