Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: Hugo111 on July 25, 2017, 10:19:30 AM
-
Hi all, is there a FSM to change a fixed timestep at the load of a level, as I have particular heavy physics needs in one level only, which I don't want to effect the rest of my game! Any ideas would be useful, thanks .
-
Hi,
I think you mean a Action instead of FSM :)
I made a 'Set Fixed Time Step' Action for you. (in the attachment below)
I tested it a bit and it seems to work.
Can you let me know if it works so i can add this to the Ecosystem (https://hutonggames.fogbugz.com/default.asp?W1181) :)
-
Thank you soooo much that works brilliantly !!! Problem solved !!
-
Ok! Thats 10 dollar!!
Joke!! i am happy to help 8) 8) 8)
-
Hi
Kurt, can you put this on the Ecosystem? thanks :)
Bye,
Jean
-
Hi jean.
Done! :)
-
hi hugo please what's the purpose of this fixed time step, i'd like to know how it can also help me,
thanks
-
The purpose of the time step is to speed up in my case is the number of time the physics engine sees collisions, so better for very fast collisions . But you pay a price on cpu performance !!
-
Hey, this action still works good, BUT.
Can anyone make "Set Maximum Allowed Timestep" Action? Or modify the Set Fixed Timestep Action to also set the Maximum Allowed Timestep.
The Action "Scale Time" resets the Maximum Allowed Timestep to value: 0,2. This makes my game jitter after I turn on slomo. I need a Set Maximum Allowed Timestep Action to set it back to my preferred value.
-
Hi.
I tried to google for some code sample to change this in code, but could not find anything.
if you can find a sample script i can make an action for it.
-
Hi, I found this:
Time.fixedDeltaTime = 1.0f/(float)PhysicsFrameRate;
Time.maximumDeltaTime = Time.fixedDeltaTime * 2.0f;
Application.targetFrameRate = TargetFrameRate;
from this forum post: https://forum.unity.com/threads/cannot-seem-to-set-maximum-allowed-timestep-from-script.432147/
Is this helpful in any way? I don't know much about coding but maybe it's the "Time.maximumDeltaTime" that refers to Maximum Allowed Timestep.
-
Nevermind! I managed to "hack" the original Action and it works :)
I attach the "Set Maximum Allowed Time Step" Action.