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

HeuristicWeight should be allowed to be higher than 9 #52

Open
GDennis opened this issue Dec 31, 2023 · 0 comments
Open

HeuristicWeight should be allowed to be higher than 9 #52

GDennis opened this issue Dec 31, 2023 · 0 comments

Comments

@GDennis
Copy link

GDennis commented Dec 31, 2023

let heuristicWeight = Math.min(9, Math.max(1, options.heuristicWeight || 1.2));

There is no reason for the heuristicWeight to be limited to only 9.
Actually this has lead to some unexpected results:
https://screeps.com/forum/topic/2768/pathfinder-using-heuristicweight-to-implement-fractional-costs

I propose to remove that upper limit or choose a very high limit. The user that sets a heuristicWeight that high knows what (s)he's doing and would just be surprised of the high cpu costs that happen because it's actually capped to 9 (undocumented as well).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant