Replies: 1 comment
-
|
I'll be adding here what I see in existing similar games for reference. Stardew Valley: elevation is like ours: a visual aesthetic feature + collisions. Rather than a functional, multi-layered pseudo-3D mechanic. The game actually operates on a flat grid. There are areas initially disconnected by high elevation. The player can't be partially seen behind an elevation. Effects like rain or shadows are an overlay and work regardless of the elevation. The Legend of Zelda: A Link to the Past: . There are bridges that can both be walked under and walked across (the problem depicted above is solved). Link can fall from an upper level to a lower level. While falling, player input is disabled. Also Link can change from a lower level to an upper level by climbing a ladder. While climbing the ladder, the player input is disabled. Levels do not necessarily match with tilemap layers (a bit confusing). Also some tiles in the same layer can be drawn above the sprites and some can be drawn below them (this is how Link can partially go behind the house at the beginning). This can be seen in an emulator by turning layers on/off (the SNES had 4 tilemap layers + one sprite layer). Also note that the perspective of this game is a bit weird: all 4 sides of a cliff or wall are facing the camera. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently Threadbare does not have any real concept of height. Apparently-elevated sections of levels like this:
are in fact flat tiles that have collision shapes that prevent walking through them:
(Actually we can see from the collision debug info that the middle 2 tiles are the wrong ones. They should have collision shapes only at the edges.)
Periodically we run into the limitations of doing this. For some examples:
because:
These problems are not insurmountable. One approach people take is to have different physics layers for walls at different elevations; then they move the player in and out of those layers as they move up and down. Or you can enable and disable collisions on different tilesets based on the player's layer.
Any approach to adding/faking a third dimension in a 2D game adds complexity to the code & more importantly complexity for the level designer. So far we have chosen the path of less complexity, sacrificing the things above.
The question to discuss is, is this the right trade-off? (One example: Minit, which has a couple of special-cases for ladders but otherwise has the same simplification: the world is flat, even if it looks like it's not.)
Beta Was this translation helpful? Give feedback.
All reactions