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

NPC navigation #11

Open
3 tasks
EIREXE opened this issue Dec 17, 2024 · 0 comments
Open
3 tasks

NPC navigation #11

EIREXE opened this issue Dec 17, 2024 · 0 comments
Labels

Comments

@EIREXE
Copy link
Contributor

EIREXE commented Dec 17, 2024

NPCs need to be able to navigate around the world using the navigation mesh.

The navigation process is the following:

  • Given a target position, a path is calculated that would get us there.
  • The path is simplified, since that will make things like triangulation easier.
  • To reach each point, a series of checks are done to make sure it is possible for us to reach it.

The navigation to each of the points of the path is known as a navigation step.

Movement checks

For each navigation step, we should do a series of checks, these include:

  • Trying a simple hull cast, if we fail, try to change our target position a little bit to the sides to see if we can avoid it (triangulation).
  • If an obstacle is found in the way, check if it's a low obstacle that we can just ignore (this is used for things such as stairs).
  • If at the start of the navigation step we are too close to a wall, see if we can get away from it.

Status

  • Triangulation
  • Stair stepping
  • Initial wall avoidance

References

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

No branches or pull requests

1 participant