Customizable Pathfinding

NonStatic - Code Plugins - Oct 20, 2022

Simple but highly customizable plugin for pathfinding. Find paths in free 3D space, on ground, on walls, 2D grid, or even 2D side scrolling with jumping. Easy default setup with examples, core features exposed to blueprints.

  • Supported Platforms
  • Supported Engine Versions
    4.27, 5.0 - 5.1
  • Download Type
    Engine Plugin
    This product contains a code plugin, complete with pre-built binaries and all its source code that integrates with Unreal Engine, which can be installed to an engine version of your choice then enabled on a per-project basis.

BASIC SETUP VIDEO TUTORIAL | SHORT VIDEO SHOWCASING INCLUDED EXAMPLE LEVELS | ADVANCED TUTORIAL


Blueprint exposed customization:

  • Setting box-shaped area of the graph
  • Agent shape (simple shapes)
  • Agent dimensions
  • Octree depth, 0 - grid, 3 - for large open spaces. 2 by default, suitable for most scenarios.
  • Graph resolution (choosing size of the smallest voxel)


C++ customization:

  • Modification of generating phase by overriding a single function. Each voxel can also carry additional user data that can be used during path calculation.
  • Overriding the fitness function used by the pathfinding algorithm, with access to generated data.


Graph is generated at runtime, by default at begin play. Both generation and pathfinding requests are done asynchronously, on up to 32 threads.

Core functionality is a single global Find Path function, that takes two world locations and returns an array of nodes between start and end location.

Supports dynamic obstacles. Making an object affect the graph in real-time is as simple as adding a component.

Path following should be implemented by the user. However, the plugin does include a simple flying pawn, with an example implementation of a "GoTo" function. It is showcased in provided example levels.

Pathfinding is implemented via customized A* algorithm with post-smoothing. It's faster than Theta* while producing very similar results. Implementation details will be included in my thesis (work in progress). The code is also available on GitHub.


Patch Notes

Updated UE 4.27 version to the latest one (1.02).


Version 1.02:

  • Added support for UE 5.1
  • Fixed linker error when statically accessing plugin classes
  • Occupied nodes are now drawn correctly when selected
  • User Data can now be passed to every FindPath call
  • Added new example level with 2D setup and modified pathfinding rules (covered by advanced tutorial on youtube)
  • Many other minor bugfixes and QOL changes


Version 1.01:

  • Added support for UE 4.27. Example levels cannot be degraded, so for proper example levels please download the Unreal Engine 5 version.
  • Added missing dependencies when adding to a blank project
  • Minor bugfixes

Technical Details

Features:

  • Fully dynamic graph generation at runtime
  • Easy setup, one core blueprint function
  • Precision is set by user - works for setups of any size
  • Two example levels provided
  • Well-commented code and example blueprints


Code Modules:

  •  Runtime


Number of Blueprints: 2

Number of C++ Classes: 9

Network Replicated: No

Supported Development Platforms: Windows

Supported Target Build Platforms: Windows*


DOCUMENTATION


Important/Additional Notes:

This plugin is part of my Engineering Thesis and it's the first iteration of it. In future, it will be heavily updated, with even better performance (however it's perfectly usable right now on projects of any scale), will most likely come with a price and a detailed YouTube video, as well as more example levels (2D setup, wall climbing setup, tile-based setup, etc.)

Documentation, detailed instructions and performance guidance will be available in the coming days.


* It should work on all platforms supported by Unreal Engine 5, however it has only been packaged and tested on Windows.