4
\$\begingroup\$

I'd like to create a 2d platformer and I understand that using tiles helps you a lot.

I think many use the map editor "Tiled" but I can't find anywhere how do you make your own tileset from a given image that you created.

I spent most of today searching a reference for this on Google, without much luck.. The only hint comes from a couple of python scripts, but I didn't manage to make them work Am I missing something?

\$\endgroup\$
4
  • \$\begingroup\$ The image that you've created - is it a tileset image where each tile occurs exactly once? Or is it a game screen which may include the same tiles multiple times, and you want to extract only the unique tiles from it? (This latter case is what the python scripts are for. If you already have an image of unique tiles, you can just use Map -> New Tileset...) \$\endgroup\$
    – DMGregory
    Commented Dec 15, 2013 at 0:57
  • \$\begingroup\$ yea I made a tileset image with gimp, my problem was that I was looking for "new tileset" but at installing the program was translated into my language and I thought that to be something else, you made me realize my error! Thanks! How silly of me ^^.. If you care to post this as an answer i'll accept it :) \$\endgroup\$
    – Dix
    Commented Dec 18, 2013 at 8:53
  • \$\begingroup\$ Added it as an answer, thanks! Glad it was of some use. :) You mentioned translation - may I ask what your first language is? I found a Tiled tutorial in German if that's of any use. \$\endgroup\$
    – DMGregory
    Commented Dec 18, 2013 at 19:03
  • \$\begingroup\$ It's italian, and sadly I don't know German yet ^^, but thanks :D \$\endgroup\$
    – Dix
    Commented Dec 19, 2013 at 19:35

4 Answers 4

1
\$\begingroup\$

(Making an answer from an earlier comment...)

From what I can tell, those Python scripts are only used if you have an image of a complete game map, and want to extract from it the set of all unique tiles, then rebuild it from those tiles.

If you already have your tileset as an image, you should be able to import it from the menus using Map -> New Tileset

You'll see a window like this (from this tutorial) and can simply Browse to select the image you want to use.

\$\endgroup\$
4
\$\begingroup\$

To make my tilesets, I use GIMP to make a 32x32 tile (or a set of 32x32 tiles) and make a single image tile and save it. I then open Tiled and add the single image .PNG files as tilesets and then place those tiles into one large tilesheet and use Tiled's built-in "Save as image..." and save it as .png. This then is a spritesheet you can use in tiled to make a tiled map. LIBGDX can also be used with tilepacker2.

\$\endgroup\$
3
\$\begingroup\$

What you can do is create your tiles indiviually and then pack them together using TexturePacker.

From the provided link:

libgdx has a TexturePacker2 class which is a command line application that packs many smaller images on to larger images. It stores the locations of the smaller images so they are easily referenced by name in your application using the TextureAtlas class

If you don't like command line, there is a GUI for TexturePacker.

\$\endgroup\$
0
\$\begingroup\$

You can also use CodeAndWeb's TexturePacker - it comes with a whole bunch of optimizations to reduce artifacts on tile borders etc. Not free but work a try.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .