• Advertisement
Sign in to follow this  

2D world without the use of tiles

This topic is 3310 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey guys, I was thinking of trying to create a 2D platformer world where the maps aren't defined with a tile-grid. That is, all of the surfaces are defined as line segments and then some sort of an algorithm draws in the rest of the world. This is going to be mostly an outdoor world and there are going to be very few floating platforms (as opposed to mario which has floating bricks,etc). I decided on this kind of map format because I figured it probably would be easiest to do collision checking and I wanted the surfaces of the world to be deformable -- it sounds like it would be easy to "deform" the terrain by changing several points in the line defining the surface and then the algorithm would simply redraw the map with a hole or a hill in it. Does this sound like it would be too much work and a regular tilemap would be far far easier (considering how I want to be able to deform into the side of terrain -- not just straight down). This is also probably not a very novel concept -- can anyone point me in the direction of an article on someone's attempt?

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Original post by InsideTheAsylum
This is also probably not a very novel concept -- can anyone point me in the direction of an article on someone's attempt?


It almost sounds like you're mixing two concepts. It's possible to generate a 2d tilemap based on the 'shape' of the terrain; Warcraft 2 used something similar. I would separate out the map generation from the map rendering.

Share this post


Link to post
Share on other sites
How complex do you want the graphics to be? You could use the line segments to create a mask (draw them and fill the area below them) and then apply that to a ground texture. It wouldn't look that great though...

Share this post


Link to post
Share on other sites
Quote:
Original post by InsideTheAsylum
Hey guys, I was thinking of trying to create a 2D platformer world where the maps aren't defined with a tile-grid. That is, all of the surfaces are defined as line segments and then some sort of an algorithm draws in the rest of the world. This is going to be mostly an outdoor world and there are going to be very few floating platforms (as opposed to mario which has floating bricks,etc). I decided on this kind of map format because I figured it probably would be easiest to do collision checking and I wanted the surfaces of the world to be deformable -- it sounds like it would be easy to "deform" the terrain by changing several points in the line defining the surface and then the algorithm would simply redraw the map with a hole or a hill in it.

Does this sound like it would be too much work and a regular tilemap would be far far easier (considering how I want to be able to deform into the side of terrain -- not just straight down).

This is also probably not a very novel concept -- can anyone point me in the direction of an article on someone's attempt?
Deformable vector terrain worked great in this case. Technical details belong on another forum, but it's doable and I don't think it will be that hard technically.
http://en.wikipedia.org/wiki/Worms_(series)

Worms is not really a platformer. In comparison to tile-based games, deformable vectors will make it harder to make typical, context-dependent platforming moves work right. I mean this from design standpoint, not technical. For instance, defining a wall slide becomes more difficult. Suppose the player previously shot a tiny nick into a wall. As he's sliding over it, he presses jump expecting a wall jump to occur, gets a different (air) jump instead since for a fraction of a second he's falling and not sliding, and dies. Now the player is frustrated, which is bad. Design measures taken against that unpredictability - various tolerances, "autopilot" moves etc. - might result in less direct and crisp control, necessitate removal of some context-dependent stuff that would have worked with a more static and orthogonal world, etc. This stuff is something you'll mostly just have to test, of course.

Share this post


Link to post
Share on other sites
With 2D worlds, the technique I'd use depends enormously on the functionality of the elements within each level. Is the world large or small? Rough pixelly surfaces or smooth vector curves? Large numbers of moving platforms/walls, or mostly static?

Even if the graphics aren't rigidly based on square tiles, tile-grids are very useful. They're very easy to use as a first pass on collision checks. They start getting less useful if you've got lots of objects that are larger than a tile.

For deformation, it will depend on how the other elements in your game (players, enemies, projectiles) interact with the deformed objects. You'll need an approach that will allow you to do the design that you want to do.

Regardless of what you choose, you'll need to prototype your approach to see that it works. For 2D games often very simple techniques are all that is needed; no need to go overboard if something works fine on today's hardware. Jot down the functionality your design needs, figure out an approach that allows you to do it, and code up a quick prototype to check that it works. If it fails, try something else.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement