rule#
A rule block defines a conversion rule for the BMP to TMX conversion process in the mapping tools. It is used to associate a color on the BMP for the vegetation or main image to a list of tiles to apply on a specific layer in the TMX.
For example:
rule
{
label = Sand
bitmap = 0
color = 210 200 160
tiles = sand
layer = 0_Floor
}
Hierarchy#
Valid Parent Blocks:
ID Properties#
This block should not have an ID.
Parameters#
- bitmap 🔗
Type:
integerA value of
1will have this rule used for the vegetation image, while a value of0will have it used for the main tiles image. Trees will for example use1while ground tiles will use0.
- color 🔗
Type:
arrayThe RGB color to replace with the tiles in the
tilesparameter. This is the color you painted in your image file to associate to this rule.
- label 🔗
Type:
stringNo description
- layer 🔗
Type:
stringThe layer to apply the tiles on.
- tiles 🔗
Type:
AnyA list of tiles to apply randomly for this color. You can also use an alias block here to reference a list of tiles.
For example:
tiles = vegetation_farm_01_35
tiles = [ vegetation_farm_01_32 vegetation_farm_01_33 vegetation_farm_01_34 vegetation_farm_01_35 vegetation_farm_01_36 vegetation_farm_01_37 vegetation_farm_01_38 vegetation_farm_01_39 ]
Or with one or more alias blocks:
alias { name = treez1 tiles = [ vegetation_trees_01_13 vegetation_trees_01_14 vegetation_trees_01_15 vegetation_trees_01_8 vegetation_trees_01_9 vegetation_trees_01_10 vegetation_trees_01_11 vegetation_trees_01_17 ] }
tiles = [ treez1 ]