python-pathfinding
python-pathfinding copied to clipboard
Flowfields
Implement flowfields, inspired by https://www.youtube.com/watch?v=QCsh_nzF0FY
For visualizing the flow fields we can use UTF-8 arrows:
arrow_map = {
(0, 0): '·', # Target
(1, 0): '→', # Right
(-1, 0): '←', # Left
(0, 1): '↓', # Down
(0, -1): '↑', # Up
(1, 1): '↘', # Down-Right
(-1, 1): '↙', # Down-Left
(1, -1): '↗', # Up-Right
(-1, -1): '↖' # Up-Left
}