diff --git a/definitions/07-Hiro-Inventory.json b/definitions/07-Hiro-Inventory.json index aa5989c..68cb33a 100644 --- a/definitions/07-Hiro-Inventory.json +++ b/definitions/07-Hiro-Inventory.json @@ -14,7 +14,8 @@ }, "numeric_properties": { "prop2": 123 - } + }, + "keep_zero": true }, "item2": { "name": "name2", diff --git a/inventory.go b/inventory.go index 9c9754a..5e4bd14 100644 --- a/inventory.go +++ b/inventory.go @@ -36,6 +36,7 @@ type InventoryConfigItem struct { StringProperties map[string]string `json:"string_properties,omitempty"` NumericProperties map[string]float64 `json:"numeric_properties,omitempty"` Disabled bool `json:"disabled,omitempty"` + KeepZero bool `json:"keep_zero,omitempty"` } // The InventorySystem provides a gameplay system which can manage a player's inventory. diff --git a/schemas/07-Hiro-Inventory.json b/schemas/07-Hiro-Inventory.json index 83de8dc..09833de 100644 --- a/schemas/07-Hiro-Inventory.json +++ b/schemas/07-Hiro-Inventory.json @@ -30,6 +30,9 @@ }, "type": "array" }, + "keep_zero": { + "type": "boolean" + }, "max_count": { "minimum": 0, "type": "number"