Smoother: physics interpolation node 1.0.5 Tools 4.0 Community
Submitted by user suikadorobo; MIT; 2024-07-09
A node type that smoothes scene nodes' properties by interpolating _physics_process steps.
IMPORTANT NOTE:
Since Godot 4.3 Beta 1 you can find built-in physics interpolation for 2D in `Project settings > Physics > Common > Physics Interpolation`.
Physics interpolation for 3D is being worked on and should make it into a future release.
See https://godotengine.org/article/dev-snapshot-godot-4-3-beta-1/#2d-physics-interpolation .
If you can use a Godot version with built-in physics interpolation, I highly recommend using that. If you rely on an older Godot 4 version without built-in physics interpolation, please read on.
-----
Godot typically has 60 physics ticks per second but monitors may have different refresh rates. As a result a game may look jittery on some hardware. The Smoother node interpolates between physics process steps to ensure smooth physics animations.
By default the position property is smoothed but the settings allow interpolating any properties, even custom ones, that are of a supported data type, i.e. int, float, Vector2, Vector3, Vector4, Color, Quaternion, Basis.
For usage and detailed documentation please visit the GitHub repository.
The latest changes addresses an issue in case the game FPS drops below the physics ticks per second.
View files Download Submit an issue Recent Edits