-
Notifications
You must be signed in to change notification settings - Fork 120
TileData.json
Properties:
Property | Required | DataType | Description | Default |
---|---|---|---|---|
DataType | Description | Default |
| "author" | yes | String | The author of this item | | | "category": | yes | String | The category this item resides in\. Categories are used for the building menu in\-game and for sorting the items in the editors tree view | | | "description": | yes | String | Description of the item that is shown in it's details | | | "tileType": | yes | [String (to enum)](#tiletype-enum) | The tiletype determines the tiles behaviour. [See below for more details](#tiletype-enum) | DEFAULT | | "RequiredTiles": | no | [Json Array](#requiredtiles-property) | How many tiles this building uses\. - [See documentation below](#requiredtiles-property) | 1x1 | | "isOverPlacable": | no | Boolean | Determines if other tiles can be placed over this one tile\. | no | | "placeOnWater": | no | boolean | Can this building be placed on water only | false | | "id": | yes | String | The ID of this item\. Must be unique and can be referenced in the code\. | | | "power": | no | Int | Power production of this item\. Negative values means power consumption\. | 0 | | "residents" | no | Int | How many residents / workers this building can hold | 0 | | "price": | no | Int | How much it costs to place this building | 0 | | "title": | yes | String | The items title\. It's shown ingame and in the editors tree\-view | | | "upkeep cost" | no | Int | Monthly cost to upkeep this building | 0 | | "water" | no | Int | Water production of this item\. Negative values means power consumption\. | 0 | | "tag" | yes | String Array | Multiple tags for searching this item ingame\. Must be a string array | | | "tiles" | yes | [JSON Array](#tiles--slopetile--shorelines-json-property) | Tile Spritesheet information array \- [see below for detailed description](#tiles--slopetile--shorelines-json-property) | | | "slopeTiles" | no | [JSON Array](#tiles--slopetile--shorelines-json-property) | Slope Tile Spritesheet information array \- [see below for detailed description](#tiles--slopetile--shorelines-json-property) | | | "shoreLine" | no | [JSON Array](#tiles--slopetile--shorelines-json-property) | Shore Tile Spritesheet information array\. This is only applicable for tiles with TileType "terrain" \- [see below for detailed description](#tiles--slopetile--shorelines-json-property) | | | "biomes" | no | String Array | Restrict this building to spawn only in the given biomes\. Must correspond to a biome defined in **resources/data/TerrainGen.json** | "" | | "style" | no | [String Array (to enum)](#style-enum) | Restrict this building to certain Art Styles\. [See enum Style description below](#style-enum) | ALL | | "wealth" | yes | [String (to enum)](#wealth-enum) | Restrict this building to a certain wealth level\. [See enum Wealth description below](#wealth-enum) | NONE | | "zones" | yes | [String Array (to enum)](#zones-enum) | Restrict this building to a zone type\. [See enum Zones description below](#zones-enum) | NONE | | "crimeLevel" | no | Int | Crime rate this building produces or prevents (police station) | 0 | | "pollutionLevel" | no | Int | Pollution rate this building produces or prevents (police station) | 0 | | "fireHazardLevel" | no | Int | Fire hazard rate this building produces or prevents (police station) | 0 |
Property | Required | DataType | Description | Default |
---|---|---|---|---|
"clip_height": | yes | Int | Size of this element or of one tile, if the image contains multiple tiles in a tileset. | auto |
"clip_width": | yes | Int | Size of this element or of one tile, if the image contains multiple tiles in a tileset. | auto |
"count": | no | Int | How many frames / tiles this image contains. One of the items will be randomly chosen per default, except for certain tiletypes. See TileType Enum | 1 |
"offset": | no | Int | If clip_rect / clip_height is used, the offset where the clipping should start | 0 |
"fileName" | yes | String | The filename of the image / spritesheet. | |
"rotations": | no | Int | A number greater than 1 will prevent picking a random tile from the spritesheet if the count is > 1 | 1 |
Property | Required | DataType | Description | Default |
---|---|---|---|---|
width | no | Int | The width of building (how many nodes it'll occupty) | 1 |
height | no | Int | The height of building (how many nodes it'll occupty) | 1 |
BETTER_ENUM(TileType, int,
DEFAULT, // Default is for buildings and practically everything that'll be placed on the TERRAIN layer
TERRAIN, // Terrain itself
WATER, // Water terrain
BLUEPRINT, // Same as terrain, but gets placed on the BLUEPRINT layer
AUTOTILE, // Autotiling to itself, like roads, power lines, etc
ZONE, // Zones (rectangular placement)
UNDERGROUND // same as AUTOTILE, but for the BLUEPRINT layer
)
BETTER_ENUM(Wealth, int,
NONE, // not applicable
LOW, // Low income
MEDIUM, // Medium income
HIGH // High income
)
BETTER_ENUM(Style, int,
ALL, // Default, place the Building in all Styles
ASIAN, // This building will only appear in a game with the Style Asian
EUROPEAN, // This building will only appear in a game with the Style European
US // This building will only appear in a game with the Style US
)
BETTER_ENUM(Zones, int,
NONE, // not applicable
RESIDENTIAL,
INDUSTRIAL,
COMMERCIAL,
AGRICULTURAL
)