기술 자료

Unity Engine


User Manual

Script Reference

Unity Engine


SetPath(NavMeshPath)

Assign a new path to this agent.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

  • Type: Method
  • Namespace: UnityEngine.AI
  • Assembly: UnityEngine.AIModule
public bool SetPath(NavMeshPath path)

Parameters

New path to follow.

Returns

Type

Description

boolTrue if the path is succesfully assigned.

Remarks

If the path is succesfully assigned the agent will resume movement toward the new target. If the path cannot be assigned the path will be cleared (see NavMeshAgent.ResetPath).