Skip to main content
Version: 3.6

class LightshipNavMeshAgent

(Niantic.Lightship.AR.NavigationMesh.LightshipNavMeshAgent)

LightshipNavMeshAgent is an example agent implementation that navigates a LightshipNavMesh based on logic programmed here. You place this MonoBehaviour on a GameObject to have that GameObject navigate autonomously through your real environment. You can create new versions of this to change how your creatures navigate the LightshipNavMesh. For example you may want to use physics/forces or add splines rather than straight lines. This is a basic example that uses linear interpolation and coroutines.

	class LightshipNavMeshAgent: MonoBehaviour {
public:

enumAgentNavigationState;

// properties

AgentNavigationState State;
Path path;

// methods

void StopMoving();
void SetDestination(Vector3 destination);
};