Skip to content

Physics is not deterministic when using time scale. #24334

@ghost

Description

Win10 64bit d030c17

Demo Project (Timescale exposed as an export var in the scene root.): 3.1 Timescale Determinism Issue.zip

I have been experimenting with Engine.time_scale and noticed the results in the built-in physics can vary wildly.

It makes me a concerned about using time slowing effects in games, because the way the game will play will change. Maybe there might be points in the game where the character will now just barely never be able to reach a platform if they're using a time slowing powerup.

It would be very hard to identify problems like that and hack in work arounds in script.
I made a small test project. It's RigidBody2Ds with a KinematicBody2D arm, being animated with an AnimationPlayer on the physics process.

They stay deterministic from play to play until the timescale is modified. Below are some animations showing these results at different time scales.

Not clear at least if this is a bug, limitation, or requires a totally different approach.

1X Timescale

1x timescale

4X Timescale

4x timescale

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions