#A* Pathfinding 2D Isometric

1 messages · Page 1 of 1 (latest)

weak surge
#

So I'm working on a dungeon crawler demo for my course and it's procedurally generated using the binary space partition algorithm.

Isometric Miniature Dungeon · Kenney https://share.google/uDAcHdop2HdWKThB3
Character Creator 2D - Fantasy by SmallScaleInt https://share.google/5JTzGt1lPsL1bqzTK

These are the two asset packs that I'm using which are both isometric by design. I've made an enemy which has 3 states (idle, patrol and chase). I use the algorithm to get the enemies that spawn in the dungeon to navigate it and they do so but the main issue that when navigating via corridors they stick to the edges or they try to move across areas which have no tiles. Which from my debugs showcase that the pathfinding says they can move there.

I get an offer of the algorithm not picking up all the floor tiles correctly

Download this package (70 assets) for free, CC0 licensed!

itch.io

Build top-down 2D fantasy characters with customizable gear, colors, and spritesheets.

#

If anyone has used A* Pathfinding or any sort of pathfinding for a 2d Isometric game then I'd like to know how they got their AI to pathfind and if they used similar methods or better methods.

stable python
#

I'd start just figuring out how to do A* doing it by grid coordinates, then looking how to warp those coordinates in 2D space (just a little extra bit of logic)

weak surge
#

I will go ahead with that

#

And give an update on my progress

lethal cedar
#

fwiw, A* does not need a grid, it just needs a connectivity graph (nodes and edges) and a position for each node. an iso grid is functionally identical to an ortho grid (same topology), all you need is a transformation of the iso-projection into the ortho projection while calculating the heuristic function, which you could derive from the cell index you probably already have.

weak surge