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

Fix wrong distance calculation in NavMeshQueries3D::_query_task_build_path_corridor #101968

Merged
merged 1 commit into from
Jan 24, 2025

Conversation

kiroxas
Copy link
Contributor

@kiroxas kiroxas commented Jan 23, 2025

Fixes Issue #101955

Regression introduced (by me) here

For short, we can't take the squared version here, as the final score is a combination of multiple scores, squaring one part bias the whole result.

( the other distance_squared added in the linked PR are fine, only those two needs to be reverted).

Copy link

@greatcoltini greatcoltini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested using 4.4beta1 and the example (#101955) and can confirm the issue with the agent.

Downloaded the Windows client artifact, unzipped and tested using the example issue, and can confirm that the agent paths as expected.

@Repiteo Repiteo merged commit 0d7af5b into godotengine:master Jan 24, 2025
19 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Jan 24, 2025

Thanks!

@kiroxas kiroxas deleted the FixSlightlyWrongPath branch January 24, 2025 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Godot NavigationAgent acting strangely since 4.4beta1. Worked fine in 4.4dev7
5 participants