mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-13 01:08:25 +07:00
Added nations json schema
This commit is contained in:
@ -35,6 +35,12 @@ Tada! Now Android Studio will recognize all Buildings.json files as belonging to
|
||||
"*/Units.json"
|
||||
],
|
||||
"url": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/units.json"
|
||||
},
|
||||
{
|
||||
"fileMatch": [
|
||||
"*/Nations.json"
|
||||
],
|
||||
"url": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/nations.json"
|
||||
}
|
||||
]
|
||||
```
|
||||
|
@ -26,12 +26,12 @@
|
||||
"percentStatBonus": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/stats.json" },
|
||||
"specialistSlots": {
|
||||
"type": "object",
|
||||
"additionalProperties": {"type": "integer"},
|
||||
"additionalProperties": { "type": "integer" },
|
||||
"description": "How many specialists of each type does this building allow for. Key must be name of existing specialist."
|
||||
},
|
||||
"greatPersonPoints": {
|
||||
"type": "object",
|
||||
"additionalProperties": {"type": "integer"},
|
||||
"additionalProperties": { "type": "integer" },
|
||||
"description": "Which Great Person Points this building generates per turn. Key must be name of Great Person unit."
|
||||
},
|
||||
"hurryCostModifier": { "type": "number" },
|
||||
@ -55,7 +55,7 @@
|
||||
"type": "string",
|
||||
"description": "For unique units: the name of the original unit that this unit replaces for the uniqueTo nation."
|
||||
},
|
||||
|
||||
|
||||
"quote": {
|
||||
"type": "string",
|
||||
"description": "Quote that will be displayed for Wonders in the 'construction completed' popup"
|
||||
|
11
docs/Modders/schemas/color.json
Normal file
11
docs/Modders/schemas/color.json
Normal file
@ -0,0 +1,11 @@
|
||||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema",
|
||||
"type": "array",
|
||||
"minLength": 3,
|
||||
"maxLength": 3,
|
||||
"items": {
|
||||
"type": "integer",
|
||||
"minimum": 0,
|
||||
"maximum": 255
|
||||
}
|
||||
}
|
78
docs/Modders/schemas/nations.json
Normal file
78
docs/Modders/schemas/nations.json
Normal file
@ -0,0 +1,78 @@
|
||||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": { "type": "string" },
|
||||
"leaderName": { "type": "string" },
|
||||
"adjective": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" },
|
||||
"uniqueItems": true,
|
||||
"description": "Currently not in use"
|
||||
},
|
||||
"style": { "type": "string" },
|
||||
"cityStateType": { "type": "string" },
|
||||
"outerColor": { "$ref": "#/definitions/color" },
|
||||
"innerColor": { "$ref": "#/definitions/color" },
|
||||
|
||||
"preferredVictoryType": { "type": "string" },
|
||||
"startBias": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" },
|
||||
"uniqueItems": true,
|
||||
"description": "Types of tiles where the civ will be more likely to start"
|
||||
},
|
||||
|
||||
"uniques": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/uniques.json" },
|
||||
|
||||
|
||||
// All of these are cosmetic
|
||||
"introduction": { "type": "string" },
|
||||
"tradeRequest": { "type": "string" },
|
||||
"neutralHello": { "type": "string" },
|
||||
"hateHello": { "type": "string" },
|
||||
|
||||
"declaringWar": { "type": "string" },
|
||||
"attacked": { "type": "string" },
|
||||
"defeated": { "type": "string" },
|
||||
"startIntroPart1": { "type": "string" },
|
||||
"startIntroPart2": { "type": "string" },
|
||||
"cities": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" },
|
||||
"uniqueItems": true,
|
||||
},
|
||||
"spyNames": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" },
|
||||
"uniqueItems": true,
|
||||
},
|
||||
"favoredReligion": { "type": "string" },
|
||||
|
||||
"uniqueName": { "type": "string" },
|
||||
"uniqueText": {
|
||||
"type": "string",
|
||||
"description": "Freeform text that will be shown to users, overriding the list of uniques."
|
||||
},
|
||||
"civilopediaText": { "$ref": "https://raw.githubusercontent.com/yairm210/Unciv/master/docs/Modders/schemas/civilopediaText.json" }
|
||||
},
|
||||
"required": [
|
||||
"name", "outerColor"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"definitions": {
|
||||
"color": {
|
||||
"type": "array",
|
||||
"minLength": 3,
|
||||
"maxLength": 3,
|
||||
"items": {
|
||||
"type": "integer",
|
||||
"minimum": 0,
|
||||
"maximum": 255
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -52,11 +52,5 @@
|
||||
"name", "unitType"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"definitions": {
|
||||
"uniques": {
|
||||
"type": "array",
|
||||
"items": { "type": "string" }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user