Merge two paths into a single path

Hello :smile:

Is it possible to combine two paths into a larger one? where the last node of the first path the starting node for the 2nd path. something like ABPath a,b; ABPath c = a+b;

The Problem

local avoidance for agents, but we cannot afford the RVO Simulator, so the hypothesized solution is to use ray casting to detect objects then construct a path that avoids them. this rings another bell, can we create a path to a target point that explicitly avoids a point or graph node?

if none of these are possible please let me know the best starting point ^^

Cheers,
Mohamed

update: i was just reading on modifiers, is it possible to write a modifier that modify’s the vector Path? like for example adding a vector to all the vectors in a path so the resulting path essentially avoids the dynamic obstacle?

so something like:

var obstacleAvoidanceVector = Calculate();
var vectorPath = path.vectorPath

foreach(Vector3 v in vectorPath) {

v+= obstacleAvoidanceVector;
}

Cheers,
Mohamed

Hi

If you want avoidance, usually it is better to do it in the movement script directly. But yeah, it can definitely be done in a modifier as well. You can take a look at the existing modifiers (for example the SimpleSmoothModifier) to see how it is done.