Oh, oh, and another, way more general question. The levels are built as 3D ones, but the game itself is 2D.
The levels will look like this technically [this is just a mock-up]
But on-screen end up result is 2D with perspective so to speak [Zaxis used only to get perspective on things visually:
What would be the best way to use the A*, so the point-and-click movement can be implemented?What’s your take on this?
2D platformer pathfinding is not something this package supports natively, however you may be able to use a 1xN grid graph or a point graph to get something working.
Hee, was not expecting an answer till Monday, to be honest, but we live in a weird times
So, let me tell you one quick fact more. For prototype I used an asset called PolyNav - 2D Pathfinding - there you defined the walkable area and even when clicked outside if it, the script calculated the nearest point of walkable area and my badly animated Hero stumbled there slowly, but surely. Unfortunately I cannot use it in 3d environment, as walkable path in some places move further or closer on Zaxis:
Maybe there could be a way, that we get these two assets together? Or achieve similar result - wherever the click is made, the A* finds the nearest coordinate on walkable area and sends the guy there? It would read X an Y axis, only, obviously and Z would be just, let’s say, closest to 0 possible…
Ah, I see. It is not a purely 2D world.
In that case I would recommend either the grid graph or the recast graph. A recast graph would probably work best for this case.
If you set the destination for an agent it will always try to move to the closest point that it can reach.