diff --git a/docs/Modders/Type-checking.md b/docs/Modders/Type-checking.md index 84b4c7818a..1c48e030fc 100644 --- a/docs/Modders/Type-checking.md +++ b/docs/Modders/Type-checking.md @@ -42,6 +42,12 @@ Tada! Now Android Studio will recognize all Buildings.json files as belonging to ], "url": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/nations.json" }, + { + "fileMatch": [ + "*/TileImprovements.json" + ], + "url": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/tileImprovements.json" + }, { "fileMatch": [ "*/TileImprovements.json" diff --git a/docs/Modders/schemas/techs.json b/docs/Modders/schemas/techs.json new file mode 100644 index 0000000000..76802656ea --- /dev/null +++ b/docs/Modders/schemas/techs.json @@ -0,0 +1,46 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema", + "type": "array", + "items": { + "type": "object", + "properties": { + "columnNumber": { "type": "integer" }, + "era": { "type": "string" }, + "techCost": { "type": "integer" }, + "buildingCost": { "type": "integer" }, + "wonderCost": { "type": "integer" }, + "techs": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { "type": "string" }, + "row": { "type": "integer" }, + "cost": { + "type": "integer", + "description": "Science cost of this tech - overrides the column techCost" + }, + "uniques": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/uniques.json" }, + "prerequisites": { + "type": "array", + "items": { "type": "string" }, + "uniqueItems": true + }, + "civilopediaText": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/civilopediaText.json" }, + "quote": { "type": "string" } + }, + "required": ["name", "row"], + "additionalProperties": false + } + }, + + "uniques": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/uniques.json" }, + + "civilopediaText": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/civilopediaText.json" } + }, + "required": [ + "columnNumber", "era" + ], + "additionalProperties": false + } +}