[Bug] CinemachineSpringExtension breaks Cinemachine Collider

DarkLiKally

New member
1. Character controller variant: Ultimate Character Controller, Using Third Person RPG Movement and Third Person Cinemachine Camera
2. Unity version: 2021.1.20f1 HDRP
3. Bug description

When you use the described third person setup with Cinemachine FreeLook Camera, and then apply the Spring Extension like described in the docs, you can't use the Cinemachine Collider Extension anymore - it can be added but it is doing nothing then.
Disabling the spring extension make it work again.
I want to use Cinemachine Collider extension to prevent the camera from moving into walls and objects in my scene.

4. Steps to reproduce

a) Setup UCC with third person RPG movement and Third Person Cinemachine Camera using the Cinemachine integration package
b) Configure your cinemachine freelook camera
c) Add spring extension
d) add Cinemachine Collider extension
e) play
f) collider extension is not working at all
g) disable spring extension component
h) collider extension is working like it should
 
Thanks for letting me know. I haven't used the Cinemachine Collider Extension but if you change the Spring Extension to the following does it work?

Code:
        protected override void PostPipelineStageCallback(CinemachineVirtualCameraBase vcam, CinemachineCore.Stage stage, ref CameraState state, float deltaTime)
        {
            state.PositionCorrection += m_PositionCorrection;
            state.OrientationCorrection *= m_OrientationCorrection;
        }
 
Hello,

yes that adjustment is fixing the problem basically. But when the spring is applying some changes, depending on the situation and how the camera is placed at this moment (against a corner, wall or something) when the spring adjustments are applied the camera could peek a bit through the wall again. But in general it's again making the Cinemachine Collider work again.
 
Top