Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collision state of CharacterBody3D is also updated when calling CharacterBody3D#apply_floor_snap() #10636

Open
Togira123 opened this issue Feb 7, 2025 · 0 comments
Labels
area:class reference Issues and PRs about the class reference, which should be addressed on the Godot engine repository topic:physics

Comments

@Togira123
Copy link

Togira123 commented Feb 7, 2025

Your Godot version:
4.4.beta
Issue description:
As the title says, the return value of all is_on_*() methods might change when running apply_floor_snap(), but the documentation says it only changes when calling move_and_slide(). This is because the method that updates the state (_set_collision_direction()) is also called inside of apply_floor_snap(). Not sure if all values realistically can change, perhaps, only is_on_floor() can, but I'd include them regardless since _set_collision_detection() can definitely change them. The documentation of all the is_on_*() methods should be updated to include that extra information.

The same goes for CharacterBody2D.

URL to the documentation page:
https://docs.godotengine.org/en/stable/classes/class_characterbody3d.html#class-characterbody3d-method-is-on-floor and all the other is_on_*() methods in CharacterBody3D.

@AThousandShips AThousandShips added area:class reference Issues and PRs about the class reference, which should be addressed on the Godot engine repository topic:physics labels Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:class reference Issues and PRs about the class reference, which should be addressed on the Godot engine repository topic:physics
Projects
None yet
Development

No branches or pull requests

2 participants