mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-26 22:57:00 +02:00
210 lines
5.1 KiB
JSON
210 lines
5.1 KiB
JSON
{
|
|
"type":"object",
|
|
"$schema": "http://json-schema.org/draft-04/schema",
|
|
"title" : "VCMI hero format",
|
|
"description" : "Format used to define new heroes in VCMI",
|
|
"required": [ "army", "class", "skills", "texts" ],
|
|
|
|
"oneOf" : [
|
|
{
|
|
"required" : [ "images" ]
|
|
},
|
|
{
|
|
"required" : [ "index" ]
|
|
}
|
|
],
|
|
|
|
"additionalProperties" : false,
|
|
"properties":{
|
|
"army": {
|
|
"type":"array",
|
|
"description": "Initial hero army when recruited in tavern",
|
|
"minItems" : 1,
|
|
"maxItems" : 3,
|
|
"items": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"required" : [ "creature", "min", "max" ],
|
|
"properties":{
|
|
"creature": {
|
|
"type":"string",
|
|
"description": "creature"
|
|
},
|
|
"max": {
|
|
"type":"number",
|
|
"description": "max",
|
|
"minimum" : 1
|
|
},
|
|
"min": {
|
|
"type":"number",
|
|
"description": "min",
|
|
"minimum" : 1
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"index" : {
|
|
"type" : "number",
|
|
"description" : "Private field to break things, do not use."
|
|
},
|
|
"special": {
|
|
"type":"boolean",
|
|
"description": "Marks this object as special and not available by default"
|
|
},
|
|
"class": {
|
|
"type":"string",
|
|
"description": "Hero class, e.g. knight or battleMage"
|
|
},
|
|
"female": {
|
|
"type":"boolean",
|
|
"description": "This hero is female (changeable via editor)"
|
|
},
|
|
"battleImage": {
|
|
"type":"string",
|
|
"description": "Custom def used on battle",
|
|
"format" : "defFile"
|
|
},
|
|
"images": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "images",
|
|
"required": [ "large", "small", "specialtyLarge", "specialtySmall" ],
|
|
"properties":{
|
|
"large": {
|
|
"type":"string",
|
|
"description": "Large version of portrait for use in hero screen",
|
|
"format" : "imageFile"
|
|
},
|
|
"small": {
|
|
"type":"string",
|
|
"description": "Small version of portrait for use on adventure map",
|
|
"format" : "imageFile"
|
|
},
|
|
"specialtyLarge": {
|
|
"type":"string",
|
|
"description": "Large image of hero specilty, used in hero screen",
|
|
"format" : "imageFile"
|
|
},
|
|
"specialtySmall": {
|
|
"type":"string",
|
|
"description": "Small image of hero specialty for use in exchange screen",
|
|
"format" : "imageFile"
|
|
}
|
|
}
|
|
},
|
|
"skills": {
|
|
"type":"array",
|
|
"description": "List of skills initially known by hero",
|
|
"maxItems" : 8,
|
|
"items": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"required" : [ "level", "skill" ],
|
|
"properties":{
|
|
"level": {
|
|
"type":"string",
|
|
"description": "level",
|
|
"enum" : [ "basic", "advanced", "expert" ]
|
|
},
|
|
"skill": {
|
|
"type":"string",
|
|
"description": "skill"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"specialties" :
|
|
{
|
|
"type" : "array",
|
|
"description" : "Specialty format used for OH3 heroes. Use \"specialty\" instead",
|
|
"additionalItems" : true
|
|
},
|
|
"specialty": {
|
|
"anyOf" : [
|
|
{
|
|
"type":"array",
|
|
"description": "Description of hero specialty using bonus system (deprecated)",
|
|
"items": {
|
|
"type" : "object",
|
|
"additionalProperties" : false,
|
|
"required" : [ "bonuses" ],
|
|
"properties" : {
|
|
"growsWithLevel" : {
|
|
"type" : "boolean",
|
|
"description" : "Specialty growth with level. Deprecated, use bonuses with updaters instead."
|
|
},
|
|
"bonuses" : {
|
|
"type" : "array",
|
|
"description" : "List of bonuses",
|
|
"items" : { "$ref" : "bonus.json" }
|
|
}
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"type" : "object",
|
|
"description": "Description of hero specialty using bonus system",
|
|
"additionalProperties" : false,
|
|
"properties" : {
|
|
"base" : {
|
|
"type" : "object",
|
|
"description" : "Will be merged with all bonuses."
|
|
},
|
|
"bonuses" : {
|
|
"type" : "object",
|
|
"description" : "Set of bonuses",
|
|
"additionalProperties" : { "$ref" : "bonus.json" }
|
|
},
|
|
"creature" : {
|
|
"type" : "string",
|
|
"description" : "Name of base creature to grant standard specialty to."
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"spellbook": {
|
|
"type":"array",
|
|
"description": "List of starting spells, if available. This entry (even empty) will also grant spellbook",
|
|
"items": { "type":"string" }
|
|
},
|
|
"texts": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "All translatable texts related to hero",
|
|
"required" : [ "biography", "name", "specialty" ],
|
|
"properties":{
|
|
"biography": {
|
|
"type":"string",
|
|
"description": "Hero biography"
|
|
},
|
|
"name": {
|
|
"type":"string",
|
|
"description": "Hero name"
|
|
},
|
|
"specialty": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "Hero specialty information",
|
|
"required" : [ "description", "name", "tooltip" ],
|
|
"properties":{
|
|
"description": {
|
|
"type":"string",
|
|
"description": "Description visible when hovering over specialty icon"
|
|
},
|
|
"name": {
|
|
"type":"string",
|
|
"description": "Name of the specialty"
|
|
},
|
|
"tooltip": {
|
|
"type":"string",
|
|
"description": "Tooltip visible on clicking icon."
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|