Hello all, I have a theoretical question in regards to tile based game engines:
Lets say in theory I was making a 2D RPG with a top-down view. I can also move in eight directions (forward, backward, left, right, and the diagonals).
Now lets say our player is in a typical peaceful village at the start of our journey. The player leaves north into the Forest and comes across a narrow Y in the road, narrow enough for a man to walk through but only just. He finds he can travel diagonally forward to the left or diagonally forward to the right.
Our hero can't travel through the forest, he must stay on the path. The problem is the tile that makes up the path also contains part of the forest. When our hero tries to walk on the tile that is half path half forest he cannot progress due to the forest half being present.
Is there a way to allow the player to pass through specific parts of a tile while stopping if he hits any other part? I'm not asking for specific code just the process of how someone would go about fixing this.
Perhaps an easier to explain example is this: Lets say we have a signpost tile sticking out of some ground similar to the ones you find in the Zelda games. In Zelda you can read the sign from only the front, you can bump into it from all sides but you can walk through part of the tile as long as you approach it from the back as the sign realistically isn't going to be ridiculously thick. How is that done? To my knowledge you can have tiles that the player can walk through and tiles that they cannot but not a mixture of the two. This is how it was in RPG Maker VX Ace (at least as far as I know).
I've attached a horribly drawn visual of the forest description above and also a screenshot from the amazing Zelda: A Link Between Worlds that contains a signpost to help visualize my question.
Thanks so much for the help I appreciate it!