mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-24 22:14:36 +02:00
c6cc6e6301
- loading of all objects (including H3 objects) will be directed by mod handlers - common base for all handlers accessible from mod system (IHanderBase) - json format changes: use struct with string ID's instead of vector - fixed some gcc/clang errors and warnings - fixed several cases of memory leaks and invalid memory access (mostly related to usage of bonus system and/or identifiers resolution) Note that right now loading is much slower than before due to excessive json validation (or not fast enough validator)
102 lines
2.6 KiB
JSON
102 lines
2.6 KiB
JSON
{
|
|
"type":"object",
|
|
"$schema": "http://json-schema.org/draft-04/schema",
|
|
"title" : "VCMI hero class format",
|
|
"description" : "Format used to define classes of heroes in VCMI",
|
|
"required" : [
|
|
"animation", "faction", "highLevelChance", "lowLevelChance",
|
|
"name", "primarySkills", "secondarySkills", "tavern"
|
|
],
|
|
|
|
"additionalProperties" : false,
|
|
"properties":{
|
|
"animation": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "Files related to hero animation",
|
|
"required": [ "battle", "map" ],
|
|
"properties":{
|
|
"battle": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "Hero animations for battle",
|
|
"required": [ "female", "male" ],
|
|
"properties":{
|
|
"female": {
|
|
"type":"string",
|
|
"description": "Female version"
|
|
},
|
|
"male": {
|
|
"type":"string",
|
|
"description": "Male version"
|
|
}
|
|
}
|
|
},
|
|
"map": {
|
|
"type":"object",
|
|
"additionalProperties" : false,
|
|
"description": "Hero animations for adventure map",
|
|
"required": [ "female", "male" ],
|
|
"properties":{
|
|
"female": {
|
|
"type":"string",
|
|
"description": "Female version. Warning: not implemented!"
|
|
},
|
|
"male": {
|
|
"type":"string",
|
|
"description": "Male version"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"index" : {
|
|
"type" : "number",
|
|
"description" : "Private field to break things, do not use."
|
|
},
|
|
"faction": {
|
|
"type":"string",
|
|
"description": "Faction this hero class belongs to"
|
|
},
|
|
"highLevelChance": {
|
|
"type":"object",
|
|
"description": "Chance to get specific primary skill on level-up, applicable for levels starting from 10",
|
|
"additionalProperties":{
|
|
"type":"number"
|
|
}
|
|
},
|
|
"lowLevelChance": {
|
|
"type":"object",
|
|
"description": "Chance to get specific primary skill on level-up, applicable for levels less than 10",
|
|
"additionalProperties":{
|
|
"type":"number"
|
|
}
|
|
},
|
|
"name": {
|
|
"type":"string",
|
|
"description": "Translatable name of hero class"
|
|
},
|
|
"primarySkills": {
|
|
"type":"object",
|
|
"description": "Initial primary skills of heroes",
|
|
"additionalProperties":{
|
|
"type":"number"
|
|
}
|
|
},
|
|
"secondarySkills": {
|
|
"type":"object",
|
|
"description": "Chance to get specific secondary skill on level-up. All missing skills are considered to be banned",
|
|
"additionalProperties":{
|
|
"type":"number"
|
|
}
|
|
},
|
|
"tavern": {
|
|
"type":"object",
|
|
"description": "Chance for this hero to appear in tavern of this factions. Reversed version of field \"tavern\" from town format",
|
|
"additionalProperties":{
|
|
"type":"number"
|
|
}
|
|
}
|
|
}
|
|
}
|