Handmade Hero»Forums»Code
Tim
13 posts
Tilemap Horizontal Overlap
I noticed that the current tile layout occludes half of a tile on each side of the chambers. I was wondering how in general one handles this occlusion - are the right and left sides supposed to be seamless with the next chamber over (will they be constrained to contain the same tiles in those cells) or is it okay that the player has to move over the unobserved half of the tile before transitioning?

Btw, I am super impressed by the rapid progress. 5 hours of coding the game proper and we are already running between rooms.
Casey Muratori
801 posts / 1 project
Casey Muratori is a programmer at Molly Rocket on the game 1935 and is the host of the educational programming series Handmade Hero.
Tilemap Horizontal Overlap
epsilon
I noticed that the current tile layout occludes half of a tile on each side of the chambers. I was wondering how in general one handles this occlusion - are the right and left sides supposed to be seamless with the next chamber over (will they be constrained to contain the same tiles in those cells) or is it okay that the player has to move over the unobserved half of the tile before transitioning?

Well, I'm not really sure exactly what we're going to do about this in the long run. As I mentioned on the stream, I just kind of put them that way while we're experimenting, but I need to think about the ramifications gameplay-wise before I say definitively that we're going to have it that way. The problem, of course, is that on a 16:9 screen, any set of square tiles that allows for a centered door on all four sides is going to either align properly along the width or along the height, but not both :( If it was a 16:10 screen, we'd be fine :P

That said, it's not really a problem, because there's a variety of things we can do, like making sure that those transition tiles are always neutral, etc. But it's definitely something to think about.

- Casey
Iker Murga
43 posts
Tilemap Horizontal Overlap
Not saying this is the solution, just a possible solution I just thought of. Since as the "chambers" are set up the tiles where only half is seen are transition tiles, as thus:

|_| X X |_|
|_||_||_||_|
|_| X X |_|

I think that gameplay wise, both of the "transition" tiles could be considered as the same tile. This would mean they always have the same properties, and would effectively act this way:

|_| X |_|
|_||_||_|
|_| X |_|

This way when the player reached tile CountX-1 and was moved onto tile 0 in the next TileMap, even though in game logic would consider it as changing tiles, I believe it would be trivial to have tiles in adjacent tilemaps be the same and would to the player look like a tilemap switch without the character changing tiles.

I forsee two complications using this scheme, one would be that any enemies chasing would have to also appear on both tiles at the same time (since only one would be rendered at any one time, as the player), and specially in non dungeon levels, all of the tiles equal to the CountX-1 in a tilemap would have to be equal to the tiles on the 0 on the next tilemap (and of course this scheme would be copied in CountY-1 tiles and 0 tiles on both axis).

Whether these complications would be difficult to overcome would of course be related to how the gameplay is architected, however once Casey creates the architecture I am sure more appropiate solutions will appear so this might very well be a premature idea (but I decided to write about it since it might help someone else with their particular game idea).