I'm very new so, please be kind :)
Is it possible to have pathfinding work successfully within tilemaps?
I have the following set-up, when you right click a tile it removes it so, should no longer be an obstacle but, when you left click to add a path where a tile was previously removed it doesn't work as expected. If however you click in the open area and around the orange tiles it works fine.
I'm guessing it might be due to setting regenerate map but, have tried a few places with no luck.
Hope that makes sense, thanks in advance.
I played around with the cell size & border and have it moving around now however;
If I click on the tiles as soon as the level loads the pathfinding ignores the tiles and creates nodes over them. Probably something to do with regeneration of the map in the correct place.
If I hollow out an area by right clicking the tiles then, left click to start pathfinding it doesn't find it the first time but, if I click again it finds it.
Develop games in your browser. Powerful, performant & highly capable.
LazyBassTurd, Erasing tiles from tilemap is tile based so you could use something like this.
On right mouse released cannot be triggered under mouse pressed.
Also I think it should only regenerate obstacle maps when they are modified and not every pathfind.