So Im making this isometric click to move game, I’ve hit a problem when moving trough walls per say, so from the screen shot below the white tiles are walls, the tile at the end of the arrow is a wakable tile, the walls have colliders and I managed to make the player collide with it and move back to its original position if the player tries to click move trough the wall, problem is the character flicks back from the collided position to the original position very weirdly, what I really was trying to do is it appear as if the player hadn’t moved at all when trying to walk trough the wall, not sure if colliders is the way to do this, or if I should try to get all the tiles between current player position and the destination tile and check for an invalid tile in between, if that’s the case any tips on how to accomplish that? The walkable and wall tiles are in different layers by the way and the character doesn’t move diagonally
You probably want to use A* pathfinding. There are free assets to get the hang of it on the Asset Store.
When the player clicks, the A* will construct a path to follow avoiding the obstacles. That is probably what the player expects the character to do too.
