I’ve stumbled upon few issues related to graph tags.
I use tags to restrict navigation in some areas for certain types of characters on Recast Graph.
It works correctly most of the time, but does not in particular conditions so it seems like internal bug rather than configuration problem.
- Tags are not taken into consideration entirely when
RaycastModifieris used along with the
useGraphRaycastingflag set to true. This situation is pretty clearly explained on included screenshot.
This is how enabled tags are applied before path calculation
var path = ABPath.Construct(start, to, callback); path.nnConstraint = nnConstraint; path.calculatePartial = true; path.traversalProvider = null; path.maxGScore = null; path.enabledTags &= ~(1 << prohibitedTags); AstarPath.StartPath(path);
- Tags are cut off from recast graph when part of the graph with marked tags is recalculated, eg. by GraphUpdateScene component (with updatePhysics set to true).
I 've debugged this issue and it worked out that when recalculating tiles, old tags are just not rewritten to new tile. This is fix I’ve made which is working for me so I post it for inspiration, but this issue should be resolved as soon as possible in the main package.