1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

loading secondary skill bonuses from config/skills.json works (kind of)

This commit is contained in:
Henning Koehler
2017-08-22 21:40:10 +12:00
parent 9811fbe02c
commit 05cf95400c
4 changed files with 68 additions and 0 deletions

View File

@@ -76,5 +76,9 @@
"config/spells/other.json",
"config/spells/timed.json",
"config/spells/ability.json"
],
"skills" :
[
"config/skills.json"
]
}

33
config/schemas/skill.json Normal file
View File

@@ -0,0 +1,33 @@
{
"type":"object",
"$schema": "http://json-schema.org/draft-04/schema",
"title" : "VCMI skill format",
"description" : "Format used to replace bonuses provided by secondary skills in VCMI",
"definitions" : {
"skillBonus":{
"description": "Set of bonuses provided by skill at given level",
"type": "array",
"items":{
"$ref" : "vcmi:bonus"
}
},
"required" : ["basic", "advanced", "expert"],
"properties": {
"basic":{
"$ref" : "#/definitions/skillBonus"
},
"advanced":{
"$ref" : "#/definitions/skillBonus"
},
"expert":{
"$ref" : "#/definitions/skillBonus"
},
}
}
}

29
config/skills.json Normal file
View File

@@ -0,0 +1,29 @@
{
"estates" : {
"index" : 13,
"basic" : [
{
"subtype" : 13,
"type" : "SECONDARY_SKILL_PREMY",
"val" : 250,
"valueType" : "BASE_NUMBER"
}
],
"advanced" : [
{
"subtype" : 13,
"type" : "SECONDARY_SKILL_PREMY",
"val" : 500,
"valueType" : "BASE_NUMBER"
}
],
"expert" : [
{
"subtype" : 13,
"type" : "SECONDARY_SKILL_PREMY",
"val" : 1000,
"valueType" : "BASE_NUMBER"
}
]
}
}