godotengine / godot-demo-projects

Demonstration and Template Projects
https://godotengine.org
MIT License
5.44k stars 1.52k forks source link

[3.x] Enable physics interpolation in all demos that use physics #1069

Open Calinou opened 1 month ago

Calinou commented 1 month ago

This also improves visuals in the Voxel and Dynamic Split Screen demos, and fixes splitscreen mode in the Platformer 2D demo.

Most demos (other than physics tests) have also had their physics FPS increased to 120. This is done consistency with 4.x, but also for the benefits it still provides when interpolation are enabled (lower input lag, more stable simulation).

This can be cherry-picked to 3.5, but the benefits of 2D physics interpolation will only be seen in 3.6. This PR also benefits from https://github.com/godotengine/godot/pull/92469, as it relies on that PR to reduce glitching when a 3D project starts (although it's hardly visible at 120 TPS in the first place).

Edit: Physics interpolation is no longer enabled in the 2D Skeleton demo due to https://github.com/godotengine/godot/issues/92872.

lawnjelly commented 1 month ago

Just looking through some of the physics interpolation warnings:

3D platformer

Calinou commented 1 month ago
  • In the coin scene, you should change the Animation playback process mode to physics.

Done.

lawnjelly commented 2 weeks ago

This PR also benefits from https://github.com/godotengine/godot/pull/92469, as it relies on that PR to reduce glitching when a 3D project starts (although it's hardly visible at 120 TPS in the first place).

The auto-resets is now merged as part of https://github.com/godotengine/godot/pull/92784 so afaik all the functionality should be good now for the demos. :+1:

It also might be worth having at least one slow moving demo at a lower tick rate, just to demo that way of working, which can be good for e.g. RPGs where responsiveness is not critical.

Also as an aside, even with 120tps, bear in mind that if rendering at 60fps, I'm not sure the input gets sampled more than 60fps (without agile input) on most platforms, so the responsiveness may only be seen with high refresh monitors.