Search Unity

Question Camera clipping through terrain issue

Discussion in 'Cinemachine' started by Hawk0077, Mar 20, 2023.

  1. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    788
    Hi in this video: collider.mp4

    you can see I am trying to get the camera collider to work and nothing I do seems to get any where near stoping the camera going under the terrainw ehen I move the dragon down hills. I tried being logical about it but that just doesnt seem to work so I just kept trying to move the sliders and again, nothing seems to sole the problem. Any ides where I am going wrong.

    Any help appreciated, thanks.
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,724
    I think you need to be more systematic about it.
    Start by resetting the CM Collider to its default settings. What happens?
    Set the strategy to "Pull Camera Forward". What happens then?
    Next, increase the camera radius a little (5 is huge! Try something like 0.5 or at most 1).
    What happens?
     
  3. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    788
    Thanks Gregory, much appreciated. I will give that a go this evenening and post the result back. Apologies for the delay responding. I appreciate your response.
     
  4. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    788
    Thanks for the response Gregory

    Resetting the collider made little difference. Then setting radius to 0.5 also made just slight difference. I tried taking it up to 0.9 but that made no difference either.

    I tried with and without the Follow Zoom activated, made no difference I could see.

    Heres a video of it. https://1drv.ms/v/s!AqCnWIL3cdjfg7gelGmnBAM3ZiX5gA?e=jrj3Xe
     
  5. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    788
    I believe I fixed it. You pushed me in the right direction and all I did was just lift the Middle Rig height to 3. That solvd it and the colider is visibly bouncing off the terrain now. (jumping forward). Thanks Gregory.
     
    Gregoryl likes this.