// Start is called before the first frame update void Start() { Cursor.lockState = CursorLockMode.Locked; orbitCamera.SetFollowTransform(cameraFollowPoint); orbitCamera.IgnoredColliders = character.GetComponentsInChildren <Collider>().ToList(); }
protected void Start() { Cursor.lockState = CursorLockMode.Locked; // Tell camera to follow transform CharacterCamera.SetFollowTransform(Character.transform); // Ignore the character's collider(s) for camera obstruction checks CharacterCamera.IgnoredColliders.Clear(); CharacterCamera.IgnoredColliders.AddRange(Character.GetComponentsInChildren <Collider>()); }