Slow down time for the physic engine only.

Hi all,

I’m making a game where the object got knocked off by the player will be sent into a space where time is slower than usual.

I’m using the physic engine on the object falling only and I’m controlling everything else with my own script.

Using Time.timeScale will create more work for me and changing the gravity just make everything less believable.

Is there a way to change the time for the physic engine only?

Cheers!

Set the timeScale to whatever you want for the physics. And use the unscaledTime as the time that doesn’t scale down (anything that moves normal when the physics is slowed).

Personally I created my own ITimeSupplier interface and various timesupliers including a CustomTimeSupplier to facilitate this in an OOP manner:

Thanks, that would work.