DIFF

class AIWorldSource

AIWorld Managed

All members, including inherited

Constructors 2

private void AIWorld()
private void ~AIWorld()

Methods 6

proto native AIGroup CreateGroup(string templateName)

Creates group with group behaviour specified by templateName param. AIGroups lifetime is managed by AIWorld, e.g. empty groups are deleted automatically.

proto native AIGroup CreateDefaultGroup()

Creates group with no group behaviour

proto native void DeleteGroup(notnull AIGroup group)

Destroys group and all AIAgents attached

proto native bool FindPath(vector from, vector to, PGFilter pgFilter, out TVectorArray waypoints)

Finds path on navmesh using path graph filter.

/param [in] from starting position /param [in] to ending position /param [in] pgFilter filter used for searching /param [out] waypoints waypoints array including starting and ending position /returns true - if path has been found

proto native bool RaycastNavMesh(vector from, vector to, PGFilter pgFilter, out vector hitPos, out vector hitNormal)

Raytest in navmesh

/param [in] from starting position /param [in] to ending position /param [in] pgFilter filter used for searching /param [out] hitPos hit position /param [out] hitNormal hit normal /returns true - if ray hits navmesh edge

proto native bool SampleNavmeshPosition(vector position, float maxDistance, PGFilter pgFilter, out vector sampledPosition)

Finds closest point on navmesh within maxDistance radius using path graph filter.

/param [in] position position wanted /param [in] maxDistance search radius /param [in] pgFilter filter used for searching /param [out] sampledPosition closest position on navmesh to position /returns true - function succeedes and found position is written to output paramter "sampledPosition" /returns false - function failed to find position on navmesh within given radius, output paramter is left intact