Search Unity

Switching cameras - The position of the camera won't update if not moving

Discussion in 'Cinemachine' started by Craze74, Oct 9, 2019.

  1. Craze74

    Craze74

    Joined:
    Nov 19, 2012
    Posts:
    83
    Hello everyone

    I have a simple setup where I am using 2 freelook vCam. One is following my character from a distance and the other one is really close to the character to get a 'aim over the shoulder' look.

    To switch between the 2 I am increasing the priority on the 'over the shoulder one' to make it switch, and it works nicely, however the position of the "over shoulder" one does not correspond to the 'normal' one if I am not moving at all in the game, the 'over shoulder' cam just keeps its original position when switching to it, and only inherit the position of the 'normal' cam when I am moving around with my character.

    I do have the 'inherit' position checked, and I tried many things but can't figure out why it won't correctly inherit the position.

    Does someone encountered a situation like this before ?

    Here is the link to a video showing my issue :


    Cheers
     
    Last edited: Oct 9, 2019
  2. Craze74

    Craze74

    Joined:
    Nov 19, 2012
    Posts:
    83
    I just found a solution for it, I am not sure why It is behaving like this, but just in case someone has a similar issue at some point :

    I set the transform rotation of my player to be at the rotation from my main camera, which is the behavior I am looking for in the end. I thinkby having transformation happening it 'forces' the update of the 'over shoulder' camera, exactly like when I move the character around.

    If you are looking for a different behavior and don't want your character to face the direction you are looking at, you may still encounter this issue though...

    Cheers !
     
    Gregoryl likes this.