Hello to anyone that still uses these forums for Construct 2. I would greatly appreciate help with an issue I've been trying to solve using my 2.5d system. In short, my 2d game has a z-axis, which works phenomenally. However, the built in pathfinding is completely broken by it.
For starters, setting the obstacles as solids will not work, as the method of detecting if in object is solid is not based on the solid behavior, but on a variable attached to a family.
Setting the obstacles as custom will also not work, as it is impossible to only add picked instances as obstacles, you have to add every instance of the object.
Also, there is one shared "map" used for every object with the pathfinding behavior, meaning that what is an obstacle for pathfinders with 0 as their z-axis might be completely different from pathfinders with 100 as their z-axis.
Finally, the pathfinding algorithm was not designed to account for changing their z-axis. It will attempt to find a way to the target without accounting for layers of verticality at all.
To get around this I have considered using a navigation tilemap with the EasyStar pathfinding plugin, where I can set the availability of certain tiles/nodes by checking any solid sprites over them. However, just like the default pathfinding plugin, EasyStar was not designed for layers of verticality, and won't consider it when pathfinding.
What MAY potentially work is a custom implementation of the A*star algorithm, where the nodes themselves can be given a position on the z-axis. I will attempt to do this, but I would GREATLY APPRECIATE if anyone with existing A* experience or just general pathfinding or 3d construct experience could give me tips or pointers in the right direction. Hell, on the off-chance that anyone has attempted something like this before please link me to where I can see their work.
All help is greatly appreciated.