NavMeshComponents - High Level API Components for Runtime NavMesh Building

Status of the project

Development

This project is now developed as part of the AI Navigation package. Please add that package to your project in order to continue building the NavMesh using these components and to get access to newer versions.

The content of this repository remains available for older Unity versions but no further development will be made here.

Questions and feature requests

Please use the AI & Navigation Previews section of the forum to discuss about the AI Navigation package and to stay informed about major releases.

You can learn about the future developments of AI Navigation and also share your feature requests in the Unity Platform Roadmap portal.

Bug Reporting

The Issues section of this repository is closed. Please use the Unity built-in report system to report any bugs that you find in the AI Navigation package.

Using This Repository

Components for Runtime NavMesh Building

Here we introduce four components for the navigation system:

  • NavMeshSurface – for building and enabling a NavMesh surface for one agent type.
  • NavMeshModifier – affects the NavMesh generation of NavMesh area types, based on the transform hierarchy.
  • NavMeshModifierVolume – affects the NavMesh generation of NavMesh area types, based on volume.
  • NavMeshLink – connects same or different NavMesh surfaces for one agent type.

These components comprise the high level controls for building and using NavMeshes at runtime as well as edit time.

Detailed information can be found in the Documentation section or in the NavMesh building components section of the Unity Manual.

How To Get Started

Download and install Unity 5.6 or newer.

Clone or download this repository and open the project in Unity. Alternatively, you can copy the contents of Assets/NavMeshComponents to an existing project.

Make sure to select a branch of the repository that matches the Unity version:

master for 2020.3-LTS, 2019.3 for up to 2019.4-LTS, 2018.3 for up to 2018.4-LTS and 2019.2, 2018.2, 2018.1, 2017.2 for up to 2017.4-LTS, 2017.1, 5.6.

Additional examples are available in the Assets/Examples folder. The examples are provided "as is". They are neither generic nor robust, but serve as inspiration.

Note: During the beta cycle features and API are subject to change.
Make sure to backup an existing project before opening it with a beta build.

FAQ

Q: Can I bake a NavMesh at runtime?
A: Yes.

Q: Can I use NavMesh'es for more than one agent size?
A: Yes.

Q: Can I put a NavMesh in a prefab?
A: Yes - with some limitations.

Q: How do I connect two NavMesh surfaces?
A: Use the NavMeshLink to connect the two sides.

Q: How do I query the NavMesh for one specific size of agent?
A: Use the NavMeshQuery filter when querying the NavMesh.

Q: What's the deal with the 'DefaultExecutionOrder' attribute?
A: It gives a way of controlling the order of execution of scripts - specifically it allows us to build a NavMesh before the (native) NavMeshAgent component is enabled.

Q: What's the use of the new delegate 'NavMesh.onPreUpdate'?
A: It allows you to hook in to controlling the NavMesh data and links set up before the navigation update loop is called on the native side.

Q: Can I do moving NavMesh platforms?
A: No - new API is required for consistently moving platforms carrying agents.

Q: Is OffMeshLink now obsolete?
A: No - you can still use OffMeshLink - however you'll find that NavMeshLink is more flexible and have less overhead.

Q: What happened to HeightMesh and Auto Generated OffMeshLinks?
A: They're not supported in the new NavMesh building feature. HeightMesh will be added at some point. Auto OffMeshLink generation will possibly be replaced with a solution that allows better control of placement.

Comments
  • Move enum ExtrudeMethod inside MeshTool class to avoid name conflicts

    Move enum ExtrudeMethod inside MeshTool class to avoid name conflicts

    ProBuilder (a Unity plugin) also defines ExtrudeMethod inside the ProBuilder2.Common namespace, but since MeshTool is declaring it outside a namespace or class it's throwing errors when present in the same project.

    I can add ProBuilder2.Common.ExtrudeMethod to all the occurrences in ProBuilder, but I just wanted to quickly check if it would be acceptable to move the ExtrudeMethod enum definition inside the MeshTools body.

  • Fix disabling a NavMeshLink component when gizmo are displayed

    Fix disabling a NavMeshLink component when gizmo are displayed

    Purpose of this PR

    Fix: Disabling a NavMeshLink component in the Editor does not correctly remove the link from the NavMesh system

    Testing status

    Manual testing: Enabling/disabling a NavMeshLink component with Gizmo don't display errors in the console anymore

    Technical / Halo risk

    • Tech Risk: 1
    • Halo Risk: 1
  • Examples: Make Bake and Clear buttons visible again

    Examples: Make Bake and Clear buttons visible again

    Fix the Bake and Clear buttons to show up again.

    Bake and Clear buttons were not visible:

    • If you select Tile0 in Project
    • If you open Tile0 in prefab editor
    • If you place Tile0 in a scene (but the instructions are visible in this case)

    So there was no scenario I could find where they were visible.

    To Bake, you must have a scene with the asset open. I think this means you should only bake from the prefab stage. You can Clear from the Project window, but for simplicity we don't allow that.

  • Add option to ignore trigger colliders when collecting sources

    Add option to ignore trigger colliders when collecting sources

    When using Physics Colliders as the geometry source for collecting NavMesh surfaces, there is no distinction between regular and trigger colliders.

    This can have the unforeseen effect of creating surfaces where they are not really desired, possibly blocking building entrances / hallways etc.

    This PR adds a m_IgnoreTriggerColliders bool that, when enabled, excludes trigger colliders from being used in the NavMeshSurface components. This bool will be shown only when Use Geometry is set to Physics Colliders.

  • Make NavMeshSourceTag component support having different area types

    Make NavMeshSourceTag component support having different area types

    Before NavMeshSourceTag didn't support having different area types, and so all nav mesh created using this component was marked as the "Walkable" area by default. Now the NavMeshSourceTag has an inspector field for entering a different navigation area type. This allows for having different navigation areas which different types of agents can travel on (for example, boats on water, humans on land). The default area type will still be Walkable as it was before so upgrading to this new component won't change the behavior in existing projects.

High-level interface for low-level programming

Singeli Singeli is now able to compile useful programs to C, but it's very rough around the edges, with poor error reporting. We are beginning to use

Nov 12, 2022
An eventing framework for building high performance and high scalability systems in C.

NOTE: THIS PROJECT HAS BEEN DEPRECATED AND IS NO LONGER ACTIVELY MAINTAINED As of 2019-03-08, this project will no longer be maintained and will be ar

Nov 20, 2022
An AI for playing NES Tetris at a high level. Based primarily on search & heuristic, with high quality board evaluation through value iteration.

StackRabbit An AI that plays NES Tetris at a high level. Primarily based on search & heuristic, with high-quality board eval through value iteration.

Nov 20, 2022
A water tank level sensor **Built With WisBlock** to detect overflow and low level conditions.
A water tank level sensor **Built With WisBlock** to detect overflow and low level conditions.

RAK12014 Laser TOF sensor coming soon WisBlock Watertank Level Sensor Watertank Overflow detection using the RAKwireless WisBlock modules. It implemen

Feb 3, 2022
Prometheus exporter for ARM® Hardware components using HWCPipe.

ARM® HWCPipe Exporter ARM® HWCPipe Exporter is a Prometheus exporter written in Java and C++ that retrieves metrics from Android devices running on AR

Oct 5, 2022
A collection of my ESPHome components.

ESPHome components A collection of my ESPHome components. To use this repository you should confugure it inside your yaml-configuration: external_comp

Nov 18, 2022
Is this hardware solution the ultimate in switch bounce elimination? Simple PCB, cheap components = final solution!
Is this hardware solution the ultimate in switch bounce elimination? Simple PCB, cheap components = final solution!

#230 Ultimate Switch Bounce Eliminator Direct link to video: https://youtu.be/b2uUYiGrS5Y It's time to try a final, alternative approach to the ubiqui

Nov 7, 2022
Additional components for ESP-IDF, maintained by Espressif

Espressif IDF Extra Components This repository aims to store ESP-IDF extra components which have been seperated and uploaded into IDF Component Manage

Nov 17, 2022
A custom-made 11 key macropad + 2 rotary encoders with minimal components.
A custom-made 11 key macropad + 2 rotary encoders with minimal components.

⌨ Ladispad Ladispad is a custom-made 11 key macropad with 2 rotary encoders designed for the simplicity and the ease of assembly to non technical user

Nov 17, 2022
Compatibility tool for Steam Play based on Wine and additional components

Introduction Proton is a tool for use with the Steam client which allows games which are exclusive to Windows to run on the Linux operating system. It

Nov 26, 2022
Qt based simple SCADA framework, with dashboard, static and dynamic components
Qt based simple SCADA framework, with dashboard, static and dynamic components

QSimpleScada Qt/C++ based simple SCADA library for your IoT projects. We created QSimpleScada to speed up and simplify visualising any data, so we (an

Nov 14, 2022
It's a static library that's provide a way to do hooking (intercepting software components) in native shared object from some Android Packages
It's a static library that's provide a way to do hooking (intercepting software components) in native shared object from some Android Packages

ARM_hook It's a static library that's provide a way to do hooking (intercepting software components) in native shared object from some Android Package

Feb 17, 2022
`lv_lib_100ask` is a reference for various out of the box schemes based on lvgl library or an enhanced interface for various components of lvgl library.

Introduction lv_lib_100ask is a reference for various out of the box schemes based on lvgl library or an enhanced interface for various components of

Nov 26, 2022
rlua -- High level bindings between Rust and Lua

rlua -- High level bindings between Rust and Lua

Nov 26, 2022
DISLIN is a high-level plotting library developed by Helmut Michels at the Max Planck Institute.

Harbour bindings for DISLIN, is a high level library of subroutines and functions that display data graphically.

Dec 10, 2021
Program your micro-controllers in a fast and robust high-level language.

Toit language implementation This repository contains the Toit language implementation. It is fully open source and consists of the compiler, virtual

Nov 24, 2022
A Visual Studio extension that provides enhanced support for editing High Level Shading Language (HLSL) files
A Visual Studio extension that provides enhanced support for editing High Level Shading Language (HLSL) files

HLSL Tools for Visual Studio This extension is for Visual Studio 2017 / 2019. Go here for the Visual Studio Code extension. HLSL Tools is a Visual Stu

Nov 22, 2022
JavaScript runtime for Fastly [email protected]

Fastly [email protected] JS Runtime The JS Compute Runtime for Fastly's [email protected] platform provides the environment JavaScript is executed in when using

Nov 25, 2022
Embedded Flutter runtime targeting Embedded Linux with Wayland

ivi-homescreen IVI Homescreen for Wayland Strongly Typed (C++) Lightweight Clang 11 Release Stripped = 151k GCC 9.3 Release Stripped = 168k Source run

Nov 15, 2022