jonathanredeker / flood-fill

A Flood Fill pathfinding algorithm for 2D and 3D spaces

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Flood Fill

A Flood Fill pathfinding algorithm for 2D and 3D spaces.

alt text

Requirements

flood_fill.py:

N/A

flood_fill_3d.py:

N/A

3d_model.py

- Matplotlib
- NumPy

flood_fill.py

To-do

  • Solve bug that allows the Node to traverse between two diagonally adjacent obstacles:
P - Player
O - Obstacle

[P][O]    [ ][O]
[O][ ] => [O][P]
  • Allow the algorithm to check a non-rectangular/uneven map

🚀 flood_fill_3d.py

Let's visit another dimension! How about 3D space?

To-do

  • 🐛 Solve bug in method Pathfinder.check_for_obstacle() that allows the Node to make illegal moves
  • Create a 3D graphing model to aid debugging
  • Export Map.collision_map and Pathfinder.path to be imported by 3d_model.py
  • Cleaned up the code and comments of flood_fill_3d.py and 3d_model.py
  • Find a way to make Pathfinder.node_look() less bloated and more efficient

About

A Flood Fill pathfinding algorithm for 2D and 3D spaces

License:MIT License


Languages

Language:Python 100.0%