查看: 1652|回复: 0
打印 上一主题 下一主题

分离网格链接

[复制链接]
.    

3797

主题

11

听众

5万

积分

首席设计师

Rank: 8Rank: 8

纳金币
32328
精华
41

活跃会员 优秀版主 荣誉管理 论坛元老

跳转到指定楼层
楼主
发表于 2013-1-31 22:31:15 |只看该作者 |倒序浏览
Note that this section is primarily about the manual off-mesh links, namely those that are set up by the user via the OffMeshLink component. For automatically generated off-mesh links, see the the Navmesh intro请注意,本部分主要是讲关于手动进行分离网格的链接,即用户通过OffMeshLink 组件创建的。对于自动生成分离网格的链接,参见Navmesh intro导航网格介绍It is possible that the navmesh static geometry in the scene is disconnected, thus making it impossible for agents to get from one part of the world to the other.有时,场景中的静态几何体的导航网格不是全部相连在一起的,从而使代理不能从世界场景的这一部分移动到另外的部分。To remedy this, Unity has a system of Off-mesh links为了解决这个问题,Unity有分离网格连接系统The OffMeshLink component 分离网格连接组件An off-mesh link is a component that can be placed on any object, and it has the following properties分离网格的连接,是一个可以放置任何物体上的组件,它具有以下属性    Start 开始
    The start object of the off-mesh link.
    分离网格链接的开始点物体
    End 结束
    The end object of the off-mesh link.
    分离网格链接的结束点物体
    Cost Override
    开销覆盖
    If value is positive, use it when calculating path cost on processing a path request. Otherwise, we use the default cost (cost of the layer to which this game object belongs). If the Cost Override is set to the value 3.0, moving over the off-mesh link will be three times more expensive than moving the same distance on a default NavMesh area. This property is&nbsp***ntime-editable and does not require a re-bake
    如果值为正数,计算处理路径的请求时,路径开销。否则,我们使用默认开销成本(这个游戏对象所属的层的开销)。如果Cost Override的值设置为3.0,在分离网格的链接移动相同的距离的开销,是在默认的导航网的三倍。此属性是运行时可编辑,不需要重新烘焙。
    Bi Directional 双向定向
    If this is on, the link can be traversed both ways, if it's off, the link can only be traversed in the direction from Start to End.
    如果勾上这个选项,链接的两个方向都可以通过,如果取消勾选的话,只能从开始点到结束点这样的链接方向通过。
    Activated 激活
    Specifies if this link is actually used by the pathfinder. When this property is false, the off-mesh link will be disregarded. This property is&nbsp***ntime-editable, and does not require a re-bake.
    指定这个链接实际上是否由寻路者使用。当此属性为false,分离网格的链接将被不予理会。此属性是实时可编辑的,不需要重新烘焙。 Special notes on OffMeshLink properties
分离网格链接OffMeshLink属性的特别注意事项The "Activated" and "Cost Override" properties can be changed at&nbsp***ntime and have immediate effect. All other properties require a Navmesh re-bake before they effect."激活"和"Cost Override"的属性可以在运行时改变,有立竿见影的效果(值一改变,马上就产生效果)。其他所有属性改变需要重新烘焙导航网格才会起作用。If the start or end transforms are unassigned when baking, or if the position of either the start or end transforms is too far away from the NavMesh to find valid positions, the off-mesh links will not be generated. In this case, an error is displayed in the Console window.在烘焙时,如果未分配开始或结束的变换(transforms)的位置,或者是跟导航网格离得太远,而无法找到有效的位置,分离网格链接将不会产生。在这种情况下,在控制台窗口(Console window)中显示一个错误。【来源:互联网】
更多精彩教程,尽在web3D纳金网http://www.narkii.com/college/
分享到: QQ好友和群QQ好友和群 腾讯微博腾讯微博 腾讯朋友腾讯朋友 微信微信
转播转播0 分享淘帖0 收藏收藏0 支持支持0 反对反对0
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

关闭

站长推荐上一条 /1 下一条

手机版|纳金网 ( 闽ICP备08008928号

GMT+8, 2024-5-15 17:50 , Processed in 0.097490 second(s), 33 queries .

Powered by Discuz!-创意设计 X2.5

© 2008-2019 Narkii Inc.

回顶部