Friday, September 23, 2022
HomeGame DevelopmentVelocity of Physics2D simulations are dependant on frameRate in Creator 3.5.2 -...

Velocity of Physics2D simulations are dependant on frameRate in Creator 3.5.2 – Cocos Creator


Hello,

We’re utilizing DistanceJoint2D to simulate a easy pendulum. Now we have noticed that at any time when the body price falls under a sure level on some units, the physics simulations decelerate considerably.

To make certain, we performed an experiment by setting the fixedTimeStep and the sport frameRate. Now we have noticed that the physics simulation slows down when the body price falls under (1/fixedTimeStep).
For instance if the body price is 29.99 fps and the physics fixedTimeStep is 1/15, then it really works high-quality so long as the fps stays above 15 fps. However, if fixedTimeStep is about to 1/60, then the pace of physics simulation drops to virtually half and if we additional lower the mounted time step to 1/120, the pace lower to the quarter whereas the body price stays at roughly 30. This behaviour can’t be blamed on the computing energy of the machine as a result of it really works high-quality when fixedTimeStep is about to 1/120 and body price is about to 144.

How can we stabilise the physics behaviour as a way to get the identical outcomes no matter the body price? Am I lacking one thing?

Edit: The identical behaviour is noticed in Creator 5.6.0 additionally.


RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments