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

Sometimes bot follows the mob for too long and too far away from the waypoints/route provided #634

Open
lionaneesh opened this issue Dec 8, 2024 · 1 comment
Labels
feature request This is a request for a new feature, or an expansion of an existing feature.

Comments

@lionaneesh
Copy link

Is your feature request related to a problem? Please describe.
Hello, sometimes if there are series of mobs around a point the bot can get baited into following one mob after the other and ending up inside a cave or somewhere unsafe. Is it possible to cut off more targeting after bot has moved away > X distance from the route/waypoints.

Describe the solution you'd like
I think we need to change how the bot reacts after killing a mob, we should check if we are very far off from the route and go back. I already tried to change the pullgoal MAX_PULL_DURATION and in approachgoal MAX_APPROACH_DURATION but seems like they dont work well for this usecase.
Describe alternatives you've considered
N/A
Additional context
Example if my route is to farm mobs around a jungle and there is a cave X distance away from my route, bot can end up getting pulled there by constantly chasing targets.

@lionaneesh lionaneesh added the feature request This is a request for a new feature, or an expansion of an existing feature. label Dec 8, 2024
@Xian55
Copy link
Owner

Xian55 commented Dec 12, 2024

Gooday.

There could be multiple ways to tackle the mentioned issue. Here are some ideas:


Whitelist all the NpcId's which are allowed to engage with.

  • Pro: it only attacks mentioned NpcId's
  • Con: User has to mention mobs NpcId's
  • Alternative: instead of using NpcIds use FactionMasks(Humanoid, Beast, etc). However obtaining FactionMasks would be challenging from the client.

Instead of using a recorded path, use a polygon mesh to define the bounding box where the player would be allowed to engage mobs.

  • Pro: only attacks mobs inside the polygon
  • Con: player movement relies on the navigation which might be inaccurate.

Upon obtaining the target, can check the estimated a distance (min-max) range, if the distance is to higher from the closest point to the path and the target, discard the target.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request This is a request for a new feature, or an expansion of an existing feature.
Projects
None yet
Development

No branches or pull requests

2 participants