void Start() { cameraTransposer = virtualCamera.GetCinemachineComponent <CinemachineTransposer>(); cameraComposer = virtualCamera.GetCinemachineComponent <CinemachineComposer>(); cameraShaker = new CameraShaker(); cameraShaker.Init(virtualCamera); cameraShaker.SetClamp(0, 1.5f); SetCameraTrack(attributes.composerDefaultY, attributes.defaultXDamp, attributes.defaultYDamp, attributes.defaultZDamp, attributes.defaultPitchDamp, attributes.defaultYawDamp, attributes.defaultRollDamp); }
public void Init(CinemachineVirtualCamera virtualCamera) { cameraShaker = new CameraShaker(); cameraShaker.Init(virtualCamera); }