Make 2D Map without tiles?

Hello how can i make a 2D map but without tiles?

Something like this -

http://media.pcgamer.com/files/2013/05/Dust4.jpg

Ignore everything, just look at the ground structure. its not tiles i suppose. actually i don’t even know how its called.
How can i make something like this?

The character can go only left and right.

Its just a mesh. Basically a bunch of triangles that connect together (generally in a triangle strip). Look into heightmaps or mesh generation. There’s no one way to answer your question, so don’t expect a clear cut answer.

There is two ways:

  • Using code
  • Using maps

By using code you have allot easier to make “scripting”. By that I mean that calling methods or actions making the map funner for the player, and more interactive.
By using the map it is easy for other people to export maps and load them into the game.

While both are nice, it is better to use both. For example; making a map with a few trees, ground, and the player gets drawn over it. Then adding elements into your XML map file, that are invisible to the player, make it easy to trigger events from the player interacting with its bounding box.

There is a good tutorial on XML parsers here: http://www.mkyong.com/tutorials/java-xml-tutorials/
PS. Parallax Scrolling is awesome for side-scrollers: http://en.wikipedia.org/wiki/Parallax_scrolling

So the program Tiled will be good to create something like it?

Partly. You could render it half in tiled, then the stuff you want off grid, above the tiled map.
Like this:


public void render(){
     tiledmap.draw(sceneX, sceneY);
     imageIWantOffGrid.draw(imageX, imageY);

     player.draw(playerX, playerY);
     
     imageThatsOverThePlayer.draw(imageX2, imageY2);
}

Cut it into tiles anyway, but make seamless tiles so you cant see the “squares.” I would make a couple seamless tiles of each type you need (sand, grass, water, etc.), You could add things like trees directly on the textures or draw them separately. To make it look especially good you could make transition tiles or put small tiles that overlap the transition with the transition texture on it.

Point is, mess around and see what works. Be creative with it :slight_smile: and look into how to make seamless tiles.

edit-

looking at past posts i may have misunderstood the question. Or the question is just way to broad. Probably both. You should narrow down your question to ask about the certain effect you are trying to achieve.