Open elvisish opened 11 months ago
This is a problem with how the collision margins in Godot work. When you run into the bottom step, you're actually a few fractions of a unit away from it, because of the collision margins. Then, when it looks for the stair step, it only advances by the velocity times delta, which can be less than the collision margin, so there's no floor underneath it.
The current workaround for this is enabling the "Skipping Hack", which tries moving by a fixed distance if moving by the velocity distance fails.
This is a problem with how the collision margins in Godot work. When you run into the bottom step, you're actually a few fractions of a unit away from it, because of the collision margins. Then, when it looks for the stair step, it only advances by the velocity times delta, which can be less than the collision margin, so there's no floor underneath it.
The current workaround for this is enabling the "Skipping Hack", which tries moving by a fixed distance if moving by the velocity distance fails.
Thanks, I should mention this actually doesn't happen really with Godot Physics, it seems to mainly happen with Jolt, which is weird as Jolt should be more precise
It happens with Godot Physics too but only if you increase the collision margins.
It happens with Godot Physics too but only if you increase the collision margins.
Ah, I haven't adjusted those, I wonder if Jolt can be adjusted so it works similarly? (I haven't worked much with Jolt tbh, though it seems like a good alternative to GP even at this stage)
I've had this trouble with other stair-stepping solutions, for some reason if the movement vector is too short the stair-stepping kinda misses and just slides along the slope:
https://github.com/wareya/GodotStairTester/assets/16231628/4e4da3e6-b927-47c1-bd57-72c9ed47e580