Recenter Wait Time inconsistent on FreeLook

I am on Unity 2021.3.8f1 with Cinemachine 2.8.9

I am using a custom Input provider and am successfully passing input through GetAxisValue(). I would expect that Recentering would stop and begin again after Wait Time has elapsed but that is not what is happening. However, when I set Wait Time to something high, Recentering is delayed for some inconsistent amount of time (e.g. 3 second delay when Wait Time is set to 10). This delay to recenter varies from play to play.

Here is my FreeLook setup

And here is my custom input provider

public class CinemachineCameraInput : MonoBehaviour, AxisState.IInputAxisProvider
{
    private float _xAxis;
    private float _yAxis;

    public float GetAxisValue(int axis)
    {
        switch (axis)
        {
            case 0: return _xAxis;
            case 1: return _yAxis;
            default: return 0;
        }
    }

    public void Rotate(Vector2 input)
    {
        _xAxis = input.x;
        _yAxis = input.y;
    }
}
1 Like

Recentering waits the specified amount of time when I try it. Can you make a test project that demonstrates this problem?

@Gregoryl I’ll DM you the project.

Theres 2 issues it will demonstrate.

  1. The Recentering starts immediately when wait time is set to 4 or less.
  2. With everything set to FixedUpdate (Brian, character controller, etc) camera movement on the Y axis is very jittery compared to movement on the X axis. The lower the framerate the more choppy the movement so I’ve set framerate to 30 for the project.

I can get the Y axis movement to work smoothly when set to LateUpdate but the project benefits the most from the CharacterController operating in FixedUpdate.

1 Like

I have the same problem with Cinemachine 2.8.9 (Unity 2021.3.14). It seems that actual Wait Time becomes on five seconds shorter than specified. For ecample, if I specify 7 secons it will wait 2 seconds. So if I specify 3, it becomes 0.

After some time of debugging I installed Cinemachine 2.9.4 and it doesn’t have this problem. Wait Time works as it should. But I have some concerns about this version because it not verified yet for Unity 2021.3

Don’t worry about the verification, it’s fine. Everyone should use 2.9.4 instead of 2.8.X.

Ah, great. Then I will do so. Thank you)