Search Unity

  1. Unity 2019.4 has been released.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  3. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

Third Person Camera follow behind character

Discussion in 'Cinemachine' started by jdscogin, May 26, 2020.

  1. jdscogin

    jdscogin

    Joined:
    Oct 26, 2014
    Posts:
    68
    I would like a camera to follow behind a character. If the player turns left, the camera would stay behind. I am sure this is simple, but I can't figure it out. Using CineMachine.
     
  2. gaborkb

    gaborkb

    Unity Technologies

    Joined:
    Nov 7, 2019
    Posts:
    144
    We have a few third person camera examples. Update your cinemachine version to preview version 2.6, and then import our samples.
    Check these scenes: 3rdPersonWithAim, DualTarget, and AimingRig.
     

    Attached Files:

  3. jdscogin

    jdscogin

    Joined:
    Oct 26, 2014
    Posts:
    68
    Thanks!
     
  4. Devsagi

    Devsagi

    Joined:
    Sep 28, 2019
    Posts:
    24
    Hello there,

    I have installed the update 2.6 and imported the samples. I tested the Scene 3rdPersonWithAim and AimingRig, but the camera movement there stutters a lot, especially when the frame rate varies.
    I remember the Cinemachine Free Look camera having the same problem before it got improved with the "Input Value Gain" setting recently.
    How can I achieve a similar smoothness improvement for the 3rd Person Follow mode?

    Best regards
     
  5. jdscogin

    jdscogin

    Joined:
    Oct 26, 2014
    Posts:
    68
    This worked, but now I have a problem. The character I use (mixamo) must wobble back and forth when he is walking. This causes the camera to wobble.Does not look right. I can't figure out how to keep this from happening. Can you help? See the video link.
     
  6. jdscogin

    jdscogin

    Joined:
    Oct 26, 2014
    Posts:
    68
    I found a different walk animation that works ok. It is from Macamin Ethan.
     
    gaborkb likes this.
  7. gaborkb

    gaborkb

    Unity Technologies

    Joined:
    Nov 7, 2019
    Posts:
    144
    The third person camera does not have a built-in input control. This camera tracks the follow object's orientation to determine the aim, whereas the FreeLook camera has a built-in input control which determines aim based on input.

    If you experience stutter on the camera, then it may be because your follow target stutters.
     
  8. jdscogin

    jdscogin

    Joined:
    Oct 26, 2014
    Posts:
    68
    Yes, that is the problem. The character moves to the left and right as he walks.
     
    gaborkb likes this.
  9. gaborkb

    gaborkb

    Unity Technologies

    Joined:
    Nov 7, 2019
    Posts:
    144
    In this case, separate the animation from the transform.
    For example, you could have an empty gameObject that tracks position and orientation based on your inputs. Then have your character with animation as a child of this empty gameObject.
     
    jdscogin likes this.
unityunity