An UE4 plugin for grid-based game
- SampleProject
- A more complicated project: SRPGTemplate
- Support square and hexagon grid
- Support multi-level grid
- Grid-based pathfinding and movement
- Multiple grid rendering method: Decal and Outline(XCom2-like)
- Grid sensing component1
- Blueprint support
- Editor integration
- Customizable classes
- PathGuide for rendering path
- Set pawn's default controller to AAIController or its subclass2
- Add UGridNavigationComponent to your pawn3
- Add UGridSensingComponent to your pawn (optional)
- Spawn GridManager at game startup4
- Write game logic
- UGridInfo: inherit from this class to add game-specific information
- USquarePathFinder and UHexagonPathFinder: customize pathfinding logic
- UGridNavigationAgent: inherit from this class to implement special movement, e.g.: jump, climb and so on
- UGridPainter: customize grid rendering5
- Clone this project to ${YourProject}/Plugins/
- Generate project file
- Compile
plus a component visualizer for debug and level design↩
we need it to implement default grid-based movement↩
if you have custom UGridNavigationAgent, add it to Component's 'AgentClasses'↩
if you have custom class, set it properly in spawn parameter↩
Default is UGridDecalPainter which using decal component to rendering grid↩