forgottenserver
forgottenserver copied to clipboard
Optimize pathfinding
Pull Request Prelude
- [x] I have followed proper The Forgotten Server code styling.
- [x] I have read and understood the contribution guidelines before making this PR.
- [x] I am aware that this PR may be closed if the above-mentioned criteria are not fulfilled.
Changes Proposed
This is a overhaul of when and how pathfinding is done. I did attempt this before but I closed the pull request due to congestion. I believe all problems from the original pull request have been fixed.
This will change the pathfinding to work as A* algorithm rather than djikstra's. It will also add more pathfinding calls as needed fixing monster moving around slowly due to 1 second pathfinding interval. This PR also includes separation of when creatures will update their path from creatures onThink. Lastly it includes some fixes for bugs which were not detectable until pathfinding was able to be called more often.
Issues addressed: Might fix: #4617