Skip to content

Physics simulation has issues on high refresh rate monitors #4277

Description

@yaustar

Project: https://playcanvas.com/project/935538/overview/physics-sim-bug

On a 60Hz screen, the box moves between the two cones once the ball reaches the top.

Kapture.2022-05-26.at.19.54.56.mp4

If we reduce the dt by setting the app.timeScale to 0.1, it no longer switches and says on the left.

Kapture.2022-05-26.at.19.57.32.mp4

The code logic teleports the cube (the rigid body) between each cone at the bottom when the ball (a child of the cube) reaches the top.

There's a bit of code at start of the update that checks if the cube has been teleported correctly and it doesn't if the dt is small.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Fields

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions