m4m.framework.NavMeshLoadManager

@meta4d/engine / Exports / m4m / framework / NavMeshLoadManager

Class: NavMeshLoadManager

m4m.framework.NavMeshLoadManager

Table of contents

Constructors

Methods

Properties

Accessors

Constructors

constructor

new NavMeshLoadManager()

Methods

dispose

dispose(): void

Returns

void

Defined in

framework/navmesh/NavMeshLoadManager.ts:178


loadNavMesh

loadNavMesh(navMeshUrl, app, onstate?): void

加载NavMesh

Parameters

Name
Type
Description

navMeshUrl

string

要加载的navMesh完整路径

onstate?

(state: stateLoad) => void

加载反馈信息

Returns

void

Defined in

framework/navmesh/NavMeshLoadManager.ts:29


loadNavMeshByDate

loadNavMeshByDate(dataStr, app, callback): void

通过数据 装载NavMesh

Parameters

Name
Type
Description

dataStr

string

navmesh 的字符串数据

callback

() => any

完成回调

Returns

void

Defined in

framework/navmesh/NavMeshLoadManager.ts:56


moveToPoints

moveToPoints(startPos, endPos): vector3[]

Parameters

Name
Type

startPos

vector3

endPos

vector3

Returns

vector3[]

Defined in

framework/navmesh/NavMeshLoadManager.ts:196


showNavmesh

showNavmesh(isshow, material?): void

Parameters

Name
Type
Default value

isshow

boolean

undefined

material

null

Returns

void

Defined in

framework/navmesh/NavMeshLoadManager.ts:155


findtriIndex

Static findtriIndex(point, trans): number

获取指定位置的三角形索引

Parameters

Name
Type

point

vector3

Returns

number

Defined in

framework/navmesh/NavMeshLoadManager.ts:222

Properties

navMesh: mesh

场景中的寻路Mesh

Defined in

framework/navmesh/NavMeshLoadManager.ts:13


navTrans: transform

Defined in

framework/navmesh/NavMeshLoadManager.ts:16


navigate: Navigate

Defined in

framework/navmesh/NavMeshLoadManager.ts:15

Accessors

get navmeshJson(): string

导航网格Json数据

Returns

string

Defined in

framework/navmesh/NavMeshLoadManager.ts:20


Instance

Static get Instance(): NavMeshLoadManager

Returns

NavMeshLoadManager

Defined in

framework/navmesh/NavMeshLoadManager.ts:190

Last updated