Answer the question
In order to leave comments, you need to log in
Sprite Atlas: how to upload, mappit?
Complex question. And so, there is a png'shka on which a bunch of tiles 30x30. I cut it all with the Sprite Editor and got an atlas (am I calling the entity correctly?):
Next, I would like to somehow map each element of the atlas to constants:
public class TileMap
{
public const string GROUND_DESERT = "desert";
public const string GROUND_GREEN_GRASS = "green_grass";
public const string GROUND_SANDY_LOAM = "sandy_loam";
// Common roads
public const byte NEW_VERT_ROAD = 1;
public const byte NEW_HORZ_ROAD = 2;
public const byte BRK_VERT_ROAD = 3;
public const byte BRK_HORZ_ROAD = 4;
public const byte RSD_HORZ_ROAD = 6;
public const byte CROSS_ROAD = 8;
// Rotated roads
public const byte RTT_BOTTOM_RIGHT_ROAD = 10;
public const byte RTT_BOTTOM_LEFT_ROAD = 11;
public const byte RTT_TOP_LEFT_ROAD = 12;
public const byte RTT_TOP_RIGHT_ROAD = 13;
// Decor
public const byte GREENERY_BUSH = 15;
public const byte GREENERY_TREE_1 = 16;
public const byte GREENERY_TREE_2 = 17;
public const byte GREENERY_TREE_3 = 18;
// ......
}
Answer the question
In order to leave comments, you need to log in
First you need a tile map editor. You can use this one . And then collect the scene from a text file.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question