官术网_书友最值得收藏!

The navigation mesh

We have a complete level that looks perfect. The player is autospawned at runtime and we can run through it. But still there are a few more things that are needed for the level that aren't level design-wise, but it are needed for the game logic itself. One of those missing parts is the navigation mesh.

If you don't know what the navigation mesh is, it is the path finding implementation that is used within Unreal Engine in order to find a point via another point. Alternatively, in another meaning, it is used to let an enemy find what he is seeking for. With that said, it means even if we have enemies, they will not be able to navigate through the world until there is a valid navigation mesh.

Adding a navigation mesh in Unreal Engine is a very simple task. It lets you focus more on creating and pitching your enemies and their behaviors while navigating with one step.

By dragging and dropping Nav Mesh Bounds Volume from the Volumes section of the Modes panel, you have already placed a navigation volume that is responsible for creating the navigation mesh.

By default, this volume will look like a cube volume. You can scale it to fit all the level or you can create several ones; it is up to you. However, the rule is that the walkable area at your level must be covered with the navigation volume, regardless of the several volumes or only one volume. I managed to use only one volume to cover all the walkable areas, and increased its scale to fit my level.

Now, if you want to see your navigation mesh itself, just press P on your keyboard and you'll see all the walkable areas colored in green. It will automatically update any time you move stuff and assets around your level.

主站蜘蛛池模板: 马山县| 杨浦区| 克拉玛依市| 原平市| 喀喇沁旗| 左云县| 咸阳市| 舞钢市| 太保市| 鲁甸县| 霸州市| 南皮县| 远安县| 吉木乃县| 德格县| 上虞市| 日喀则市| 利津县| 会宁县| 乐昌市| 葵青区| 平乡县| 饶平县| 来凤县| 临西县| 阿拉善右旗| 宜州市| 尼勒克县| 积石山| 隆化县| 无锡市| 桐城市| 资兴市| 濮阳县| 汉寿县| 崇州市| 柞水县| 宜川县| 黑龙江省| 兴城市| 安徽省|