1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-11-25 09:44:02 +00:00

Created tilesets (markdown)

False.Genesis 2018-12-25 01:23:24 +01:00
parent 9983ffae5e
commit 7e333b6f89

46
tilesets.md Normal file

@ -0,0 +1,46 @@
The list of tiles used in a map is called a _tileset_.
To view/modify the tileset used by a map, edit the map xml file, and look for the "tileset" attribute.
```
<Level tileset="mithalas" .../>
```
The tileset file is stored in the tilesets directory as a txt file. It contains the list of the graphics that are available for the maps using this tileset.
Tileset example :
```
0 black
1 veil-tilerock-0001 128 128
2 veil-tilerock-0002 128 128
3 veil-tilerock-0003 128 128
4 veil-tilerock-0004 128 128
5 collectibles/mithala-doll
6 growth-medium
7 growth-heavy
8 bg-light-0001
9 bg-light-0002
10 bg-light-0003
11 healthplant-bush
```
The tiles 1-4 are used to generate the borders when pressing F12 in the editor. Which tile is used is randomly chosen. The two numbers after tiles 1-2 are the size of the tile graphic in pixels, so that the editor knows the spacing when placing borders automatically (Refer to [[Map templates|map-basics]] for the details).
Tile 0 is not used.
To add a new tile, add a new entry in this list with the name of the graphic you want to add.
For example, you could append the following lines at the end:
```
12 my-new-graphic
13 coral-0007
20 plants/my-seaweed
```
Aquaria will first search for the graphic name in your mod (under **graphics/...**), then in Aquaria (**gfx/...**). Always use file names without extension (leave the _.png_ away)!
You can use your own numbering. More precisely, there can be holes in your numbering.
This is useful if you want to categorize tiles for faster access in the editor. You could for example use 10-50 for rock tiles, 50-100 for plants, 100-150 for other decoration. You'll get a feel for this when you repeatedly cycle through tiles in the editor.
Just don't use the same number twice.