OpenMoHAA 0.82.0
Loading...
Searching...
No Matches
RecastPather Class Reference

Detour (recastnavigation) based navigation system. More...

#include <navigation_recast_path.h>

Inheritance diagram for RecastPather:
IPather LightClass

Public Member Functions

virtual void FindPath (const Vector &start, const Vector &end, const PathSearchParameter &parameters) override
 Find and set the path from start to end.
 
virtual void FindPathNear (const Vector &start, const Vector &end, float radius, const PathSearchParameter &parameters) override
 Find and set the path from start to end with the specified goal radius.
 
virtual void FindPathAway (const Vector &start, const Vector &avoid, const Vector &preferredDir, float radius, const PathSearchParameter &parameters) override
 Find and set the path away from the specified origin.
 
virtual bool TestPath (const Vector &start, const Vector &end, const PathSearchParameter &parameters) override
 Returns true if the path exists, false otherwise.
 
virtual void UpdatePos (const Vector &origin) override
 Update path movement.
 
virtual void Clear () override
 Clear the path.
 
virtual PathNav GetNode (unsigned int index) const override
 Return the node at the specified index (0 = first node, and nodecount - 1 = last node).
 
virtual int GetNodeCount () const override
 Return the number of nodes.
 
virtual Vector GetCurrentDelta () const override
 Return the current move delta.
 
virtual Vector GetCurrentDirection () const override
 Return the directional vector towards the path.
 
virtual Vector GetDestination () const override
 Return the final destination.
 
virtual bool HasReachedGoal (const Vector &origin) const override
 Return true if the origin is at the end of the goal.
 
virtual bool IsQuerying () const override
 Return true if the path is currently being calculated.
 
- Public Member Functions inherited from LightClass
void * operator new (size_t s)
 
void operator delete (void *ptr)
 
void * operator new (size_t size, void *placement)
 
void operator delete (void *ptr, void *placement)
 
template<typename T>
void * operator new (size_t size, T &placement)
 
template<typename T>
void operator delete (void *ptr, T &placement)
 

Additional Inherited Members

- Static Public Member Functions inherited from IPather
static IPatherCreatePather ()
 Create a new Pather object based on supported navigation features.
 

Detailed Description

Detour (recastnavigation) based navigation system.

Member Function Documentation

◆ Clear()

void RecastPather::Clear ( )
overridevirtual

Clear the path.

Implements IPather.

◆ FindPath()

void RecastPather::FindPath ( const Vector & start,
const Vector & end,
const PathSearchParameter & parameters )
overridevirtual

Find and set the path from start to end.

Parameters
startStart of the path.
endEnd of the path
parameters

Implements IPather.

◆ FindPathAway()

void RecastPather::FindPathAway ( const Vector & start,
const Vector & avoid,
const Vector & preferredDir,
float radius,
const PathSearchParameter & parameters )
overridevirtual

Find and set the path away from the specified origin.

Parameters
startStart of the path
avoidLocation to avoid
preferredDirPreferred direction to use to escape from the location to avoid
radiusMinimum safe distance to avoid
parameters

Implements IPather.

◆ FindPathNear()

void RecastPather::FindPathNear ( const Vector & start,
const Vector & end,
float radius,
const PathSearchParameter & parameters )
overridevirtual

Find and set the path from start to end with the specified goal radius.

Parameters
startStart of the path
endEnd of the path
radiusThe radius at which to stop the path
parameters

Implements IPather.

◆ GetCurrentDelta()

Vector RecastPather::GetCurrentDelta ( ) const
overridevirtual

Return the current move delta.

Returns
Vector with the current move delta.

Implements IPather.

◆ GetCurrentDirection()

Vector RecastPather::GetCurrentDirection ( ) const
overridevirtual

Return the directional vector towards the path.

Returns
Vector with the current directional vector.

Implements IPather.

◆ GetDestination()

Vector RecastPather::GetDestination ( ) const
overridevirtual

Return the final destination.

Returns
Vector the destination.

Implements IPather.

◆ GetNode()

PathNav RecastPather::GetNode ( unsigned int index) const
overridevirtual

Return the node at the specified index (0 = first node, and nodecount - 1 = last node).

Parameters
index
Returns
A copy of the path information.

Implements IPather.

◆ GetNodeCount()

int RecastPather::GetNodeCount ( ) const
overridevirtual

Return the number of nodes.

Returns
The number of nodes. If 0, then there is no path.

Implements IPather.

◆ HasReachedGoal()

bool RecastPather::HasReachedGoal ( const Vector & origin) const
overridevirtual

Return true if the origin is at the end of the goal.

Parameters
originThe current origin to test

Implements IPather.

◆ IsQuerying()

bool RecastPather::IsQuerying ( ) const
overridevirtual

Return true if the path is currently being calculated.

Returns
true
false

Implements IPather.

◆ TestPath()

bool RecastPather::TestPath ( const Vector & start,
const Vector & end,
const PathSearchParameter & parameters )
overridevirtual

Returns true if the path exists, false otherwise.

Parameters
startStart of the path.
endEnd of the path
parameters
Returns
true if the path exists

Implements IPather.

◆ UpdatePos()

void RecastPather::UpdatePos ( const Vector & origin)
overridevirtual

Update path movement.

Parameters
originThe origin to set

Implements IPather.


The documentation for this class was generated from the following files: