It seems to me that the top layer there is supposed to have more priority than the player, therefore it goes over him. This is because the tile is meant to have the player above the square and rather not on it. I'll go try out something and see if it works, using the Port Town tileset.
That is the intended use. If you don't mind not having players able to go behind a building like this (Such as the early Pokemon games), remove the priority on those tiles and make make it inaccessable left, right, and up, or something like that. The other solution is to make the whole tile inaccessible.
There is a way events can bypass this stupid rule though, as demonstrated.
If you can find a way to get a hero to do this, then you found your solution.