Unity study notes to solve the problem that the virtual camera of Cinemachine AutoDolly does not move in the direction of the track on the track

question

When using the Tracked Dolly provided by Cinemachine for path motion, if the drawn tracks are staggered or relatively close, the camera may not move in real time in the direction of the track and jump back to the original track.

solution

The reason for this situation is that in the Body of the virtual camera, the Search Radius parameter in AutoDolly
The explanation of this parameter is: the search radius. The drawing path is connected according to the waypoint segment. The radius refers to how many segments extend to both sides in the current segment where the VirtualCamera is located, as the search range. If it is 0, it means that the entire Path is used as the search range. If the calculated closest point on Path is unstable when the target moves, we can use a smaller value to narrow the range.
In other words, if the above situation occurs, you may wish to set the Search Radius to be smaller, or simply equal to 0
insert image description here

Guess you like

Origin blog.csdn.net/weixin_42358083/article/details/122942865