What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Adding freaking blackspots support to Navigator class

cowdude

Active Member
Joined
Feb 17, 2010
Messages
337
Reaction score
27
Hey,

I actually need a 'cheap' way to improve the current detour/recast-based pathing algorithm by blacklisting every solid game object.

I believe there are three ways to achieve this:
1. set a huge area cost on gameobjects locations
2. remove mesh polys around these gameobjects (ouch)
3. use high-level helpers like the HotspotManager class
4. write my own pathfinding algo

Current goal: Avoid walking into given areas while using Navigator.MoveTo.

I tried playing with the hotspotmanager from a dummy profile, which did not work at all when you're using the Navigator to compute paths instead of a roaming behavior (like the default levelbot one).

Solution 2:
<img src="http://img101.imageshack.us/img101/2584/fffuuuu.jpg" width=120 height=90 />
Well, no.

Solution 4: See solution 2.

Now, I guess that solution 1 should be the way to go. I've found some stuff called 'query filters', and it seems that this is the only way to change some area's cost.

Alright then, I just need to find an instance of that query filter and add my own 'black zones', sounds easy enough! And bang, that's where I'm stuck.

I saw that many botbase classes (like the bg bot and the levelbot) have a SetDefaultQueryFilter method, which sounds like there's a solution. But still, I don't know what this method is doing, nor how to get a query filter instance.

Then I looked at the WoWNavigator class that has a QueryFilter property. It could even be overrided, looks perfect! But once again, it seems there's no freaking way to get an instance of this class either.

Damn, I'm getting tired of it... Does anyone got a clue about how to achieve this? :confused:

If you're wondering why on earth would I need that: try running HB inside Orgrimmar.

Thanks you for any clues or advices :)
 
I may be falling into a trap but whats solution 3???

Edit: On a more on topic note wouldnt it be possible to somehow utilize wows own wireframe.
Im not much of a dev myself but i know from playing around with other games that you can export the wireframe this may take a while but it would lead to a much more accurate meshing system in the long run.
 
Last edited:
The levelbot (grind bot) already supports adding blackspots in your profiles, but these are not taken in account when you're generating a path using the navigator class.
 
I see where your coming from but wasnt the initial purpose of blackspotting designed to avoid certain area's due to high level mobs e.t.c?

IMO i believe with time the meshing will have to be drastically improved for flying capabilities so hb should be able to recognise objects infront of it and work out how to navigate around them.
The only way i can see this being utilized is to somehow create the mesh around wows own wireframe unfortunatly this is just theoretical and i dont have the slightest clue where one would begin.
 
The current algorithm uses area weights to compute the fastest path. A blackspot is basically an area with a higher travelling cost just like moving in water is slower than on ground.

There can be many ways to justify why a given area has a high cost, including the case where you just don't want to walk there because you'll get stuck, which would slow you down while travelling.
 
A BlackspotManager class is coming with an upcoming release, as its needed for the new stuck logic.

Lastly; demanding API to be created isn't a good way to get your point across.

The problem I can see you introducing already; is completely abusing the way blackspots work, and ending up causing more issues, which as usual, will get pushed on us as a bug. Your idea is 'nice' in the general idea; but I don't think you've thought about many of the issues that it'll bring up.
 
Check if the current NavigationProvider (Navigator.NavigationProvider) is a MeshNavigator. If it is, cast is to a MeshNavigator and the whole mesh/query filter is free to be used. If you use 'Mesh' or 'MeshQuery' directly, be sure to check out the 'NavHelper' class.
 
The current algorithm uses area weights to compute the fastest path. A blackspot is basically an area with a higher travelling cost just like moving in water is slower than on ground.

There can be many ways to justify why a given area has a high cost, including the case where you just don't want to walk there because you'll get stuck, which would slow you down while travelling.

Mate you completelly lost me at this point :) im only good at theorycrafting im absolutely useless when it comes to the technical stuff :)
 
Thanks for the answers!

Apoc: yeah, that's why I call that 'cheap'. That's greedy, not really accurate and will mostly get you stuck in some exceptional cases.... but it can't be worse than the current version. It's all about finding a quick'n dirty temp fix.

MaiN: Yay, that's it!!
 
Last edited:
Back
Top