I have a timeline when a boss appear. Before playing the timeline I just stop the time setting TimeScale to 0 and play a cutscene to show the boss. In order to make it work the update metod of the Timeline and the animator (on the camera) is set to “unscaled time”. This was working great, but suddenly it stopped to work.
After a lot of search, I found that the “Fixed timestep” also affect the cinemachine camera. So if i change the fixed timestep of my game the behaviour of the camera change.
Is there any way to make the timeline or cinemachine to ignore the fixed timestep? Since I put the Unscaled tme on the update metod, I don’t expect it to be influenced by fixed timestep
There is a setting on the Brain to ignore timescale, so that cameras will keep working in realtime even when time is frozen. Is that what you’re looking for?
Hello, I have the same issue but I found that Ignore time scale does not work when I set Time.timeScale = 0 to pause the game.
Only if I set the Update Method to LateUpdate works,but the player character movement will be very wired becuz I am using rigidbody move…
good to hear that ! so in my case… use smart update?
I update CM to 2.6.0 preview 5, but the issue still exsits…
When I pause the game(time scale = 0)
1、if select smart update with Ignore time scale. the vcam damping will stop when pause.and continue when resume.
2、if select late update with Ignore time scale. the vcam will damping during pause ( that’s what I want), but the player character use rigid body move look like weird…
and…
I found that some problem with the cinemachine impulse.
For example if I want to have a camera impulse during game pause ( like talking with the NPC, I will pause the game, then I need to have a camera shake ), I used cinemachine impulse.I trigger it at pause state, but the impulse will come after the game is resume.(Ignore time scale is checked)
In fact brain.IgnoreTimescale can’t work for vcams that are tracking RigidBodies without producing the juddering effect that you see in LateUpdate.
I think the solution in your case is that when you pause the game, switch the brain to LateUpdate, and when the game is running, switch it back to FixedUpdate.
The Impulse subsystem has its own independent IgnoreTimeScale setting. Use ImpulseManager.Instance.IgnoreTimeScale.
I am currently doing a sort of slow motion where basically nothing is moving but the player!
It does work pretty well expect for the camera
Since it is tracking a rigidbody, switching to LateUpdate does make it work for ignoring timescale but it does look pretty bad then.
Any chance this will be updated in the future to include FixedUpdate as well?
EDIT: After checking the source code, the GetEffectiveDeltaTime has a boolean as a parameter that basically ignores the ignore scaled time parameter using the FixedUpdate or SmartUpdate. Any reason why there is such a parameter?
Cameras following RigidBodies must animate on the physics clock. I’m not quite sure I understand the problem you’re having. If all is slowed down except the player, and the camera is following the player, why would you slow down the camera? Doesn’t it still need to track the player?
Well I might find another option but currently I basically set the timescale to something very low (along with fixedtimescale) and run the player on unscaled deltatime.
I might just actually only impact the enemies: keep the same timescale and just freeze the enemies. Might make more sense
@Gregoryl , you are a life-saver! I used both impulses and manual zooming with timeScale 0, I was totally stuck until I read your answers. The following lines fixed my issues!
I just found out the IgnoreTimeScale setting is not working on Cinemachine 2.6.11 and up when using a Freelook camera with the speed setting set on “MaxSpeed”.
The issue does not happen when using “InputValueGain” (but this setting has a bug which makes it framerate dependant), nor does it happen on 2.6.10.
I think I’m having a similar issue @Gregoryl - previously I had IgnoreTimeScale disabled to make the camera stop moving when the time scale was 0, but changing the FreeLookCamera to use Input Value Gain instead of Max Speed results in the camera ignoring the time scale, despite the setting on the Cinemachine brain.
I’ll think fix this later in my project when I start using the new input system, but there is definitely is a bug there when using the old input system.
Hit the bug with Latest 2.10.3
Issue is in AxisState.Update - There is an if(deltaTime < 0) m_CurrentSpeed = 0 (But the deltaTime can never be below zero but it can be zero if the TimeScale is zero.) Just replacing the < with <= fixes the issue.