unity3d calculatepath
来源:互联网 发布:免费下载苹果软件 编辑:程序博客网 时间:2024/06/01 09:12
NavMesh.CalculatePath
Parameters
sourcePositionThe initial position of the path requested.targetPositionThe final position of the path requested.areaMaskA bitfield mask specifying which NavMesh areas can be passed when calculating a path.pathThe resulting path.Returns
bool True if a either a complete or partial path is found and false otherwise.
Description
Calculate a path between two points and store the resulting path.
This function can be used to plan a path ahead of time to avoid a delay in gameplay when the path is needed. Another use is to check if a target position is reachable before moving the agent.
In contrast to NavMeshAgent.SetDestination, which is asyncronous call, this function calculates the path immeditely. This can be costly operation for very long paths and can cause hiccup in the frame rate. It is recommended to do only a few path finds per frame, for example when evaluating distances to cover points.
The returned path can be used to set the path for an agent using NavMeshAgent.SetPath. The agent needs to be close the starting point for the set path to work.
NavMeshAgent.CalculatePath
Switch to ManualParameters
targetPositionThe final position of the path requested.pathThe resulting path.Returns
bool True if a path is found.
Description
Calculate a path to a specified point and store the resulting path.
This function can be used to plan a path ahead of time to avoid a delayin gameplay when the path is needed. Another use is to check if a target position is reachable before moving the agent.
- unity3d calculatepath
- 利用 NavMesh.CalculatePath写出更加好的AI移动效果
- Unity3D
- Unity3D
- Unity3D
- Unity3D
- unity3d
- Unity3D
- Unity3D
- Unity3D
- UNITY3D
- Unity3D
- unity3d
- unity3D
- Unity3D
- Unity3d
- Unity3D
- unity3D
- Android-基础复习之工程介绍
- MYSQL_FIELD
- afnetworking设置请求头代码
- 彩色图像灰度化之一 问题提出与国内外研究梗概
- Creating a Physical Standby Database 11g
- unity3d calculatepath
- 近观ArcGIS 10.3.1
- linux下目录的作用
- codeforces 558A. Lala Land and Apple Trees
- CSS3的REM设置字体大小
- HTML5 HybridApp开发上手指引
- 无意搜集到的一个mysql封装函数(php)
- PHP + Memcache 实现多服务器session共享
- 杭电 hdu 1546 Idiomatic Phrases Game (最短路径 + Dijkstra)