Jo Engine Forum

Sega Saturn Development => Jo Map Editor => Topic started by: mindslight on August 31, 2017, 09:13:07 pm

Title: [TUTORIAL] How to create a tileset with Jo Map Editor 6.0
Post by: mindslight on August 31, 2017, 09:13:07 pm
1) Update Jo Map Editor : http://jo-engine.org/mapeditor/

2) Launch Jo Map Editor and select the folder where your sprites are located:

(http://www.jo-engine.org/upload/images/tileset_tutorial/1.png)

3) Drag & Drop an image on the editor

(http://www.jo-engine.org/upload/images/tileset_tutorial/2.png)

4) Explode your image in tiles

(http://www.jo-engine.org/upload/images/tileset_tutorial/3.png)

Warning: width must be a multiple of 8 in the Sega Saturn

(http://www.jo-engine.org/upload/images/tileset_tutorial/4.png)

5) Now you can move each tile and also drag & drop another image or re-explode one tile

(http://www.jo-engine.org/upload/images/tileset_tutorial/5.png)

6) Export the tileset for the Jo Engine

(http://www.jo-engine.org/upload/images/tileset_tutorial/6.png)

(http://www.jo-engine.org/upload/images/tileset_tutorial/7.png)

This will generate a file with the coordinate of each tile (to include in your project):

Code: [Select]
/*
   Tileset generated by Jo Map Editor v6.0
*/

#ifndef __TILESETNEWMAP1_H__
# define __TILESETNEWMAP1_H__

/* 36 tiles */
static const jo_tile    TilesetNewmap1[] =
{
{0, 0, 32, 32},
{0, 32, 32, 32},
{0, 64, 32, 32},
{0, 96, 32, 32},
{0, 128, 32, 32},
{0, 160, 32, 32},
...

7) Export the whole image in TGA, BIN format or C source file (in our example, we use TGA)

(http://www.jo-engine.org/upload/images/tileset_tutorial/10.png)

This image must be saved in the "cd" directory of your project in order to be load later

(http://www.jo-engine.org/upload/images/tileset_tutorial/9.png)

That's it ! Now you can follow the code inside the tileset demo ("demo - tileset" folder) in the Jo Engine source code

Hope the will help you 8)