From d0c41a949ea4c247435b8fff642e75af6a8710f5 Mon Sep 17 00:00:00 2001 From: DaanV2 Date: Wed, 27 Jan 2021 01:57:16 +0100 Subject: [PATCH] Fixing loot tables --- .../random_regional_difficulty_chance.json | 5 ++++ .../loot_tables/functions/set_damage.json | 15 +++++----- behaviour/loot_tables/loot_tables.json | 29 ++++++++++++++++++- 3 files changed, 41 insertions(+), 8 deletions(-) diff --git a/behaviour/loot_tables/conditions/random_regional_difficulty_chance.json b/behaviour/loot_tables/conditions/random_regional_difficulty_chance.json index 677d8c1e..19295dea 100644 --- a/behaviour/loot_tables/conditions/random_regional_difficulty_chance.json +++ b/behaviour/loot_tables/conditions/random_regional_difficulty_chance.json @@ -17,6 +17,11 @@ "description": "The default random chance if the level difficulty is not assigned.", "title": "Default chance" }, + "max_chance": { + "title": "Max chance", + "type": "number", + "description": "UNDOCUMENATED" + }, "easy": { "type": "number", "default": 0, diff --git a/behaviour/loot_tables/functions/set_damage.json b/behaviour/loot_tables/functions/set_damage.json index 55c9e572..ac450d9c 100644 --- a/behaviour/loot_tables/functions/set_damage.json +++ b/behaviour/loot_tables/functions/set_damage.json @@ -13,18 +13,19 @@ }, "damage": { "oneOf": [ + { "type": "integer" }, { - "type": "integer" + "type": "object", + "properties": { + "min": { "type": "integer" }, + "max": { "type": "integer" } + } }, { "type": "object", "properties": { - "min": { - "type": "integer" - }, - "max": { - "type": "integer" - } + "min": { "type": "number" }, + "max": { "type": "number" } } } ], diff --git a/behaviour/loot_tables/loot_tables.json b/behaviour/loot_tables/loot_tables.json index 8e1df5c5..624e3919 100644 --- a/behaviour/loot_tables/loot_tables.json +++ b/behaviour/loot_tables/loot_tables.json @@ -31,7 +31,6 @@ "additionalProperties": false, "title": "A single pool", "type": "object", - "required": ["rolls"], "properties": { "rolls": { "title": "Rolls", @@ -86,6 +85,11 @@ "type": "string", "enum": ["item", "empty", "loot_table"] }, + "count": { + "type": "integer", + "title": "Count", + "description": "The amount of the item" + }, "name": { "title": "Name", "type": "string", @@ -117,6 +121,29 @@ } } } + }, + "tiers": { + "title": "Tiers", + "description": "TODO description", + "type": "object", + "additionalProperties": false, + "properties": { + "bonus_chance": { + "title": "Bonus chance", + "description": "TODO description", + "type": "number" + }, + "bonus_rolls": { + "title": "Bonus rolls", + "description": "TODO description", + "type": "integer" + }, + "initial_range": { + "title": "Initial range", + "description": "TODO description", + "type": "integer" + } + } } } }