Files
minecraft-bedrock-json-schemas/source/resource/sounds.json

206 lines
7.5 KiB
JSON
Raw Normal View History

2020-11-01 17:22:42 +01:00
{
"$schema": "http://json-schema.org/draft-07/schema",
"$id": "blockception.minecraft.resource.sounds.json",
"type": "object",
"title": "Sounds.json",
"description": "Sound definitions",
"additionalProperties": false,
"definitions": {
"pitch": {
"title": "Pitch",
"oneOf": [
2021-03-21 15:18:38 +01:00
{ "default": 1, "type": "number", "description": "A defined pitch" },
2020-11-01 17:22:42 +01:00
{
"description": "A random selection between a minimum and maximum",
"type": "array",
"items": [
2021-03-21 15:18:38 +01:00
{ "type": "number", "minimum": 0, "title": "Minimum" },
{ "type": "number", "minimum": 0, "title": "Maximum" }
2020-11-01 17:22:42 +01:00
]
}
]
},
"volume": {
"title": "Volume",
"oneOf": [
2021-03-21 15:18:38 +01:00
{ "default": 1, "type": "number", "description": "A defined volume" },
2020-11-01 17:22:42 +01:00
{
"description": "A random selection between a minimum and maximum",
"type": "array",
"items": [
2021-03-21 15:18:38 +01:00
{ "type": "number", "minimum": 0, "title": "Minimum" },
{ "type": "number", "minimum": 0, "title": "Maximum" }
2020-11-01 17:22:42 +01:00
]
}
]
},
"sound_event": {
2021-04-04 14:00:43 +02:00
"title": "Sound Event",
2020-11-01 17:22:42 +01:00
"description": "A single sound event definition",
"oneOf": [
2021-03-21 15:18:38 +01:00
{ "type": "string" },
2020-11-01 17:22:42 +01:00
{
"type": "object",
"additionalProperties": false,
"required": ["sound"],
"properties": {
2021-03-21 15:18:38 +01:00
"volume": { "$ref": "#/definitions/volume" },
"sound": { "type": "string", "title": "Sound Event", "description": "The sound event described in sound_definitions.json" },
"pitch": { "$ref": "#/definitions/pitch" }
2020-11-01 17:22:42 +01:00
}
}
]
},
"entity_event": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Sound",
2020-11-01 17:22:42 +01:00
"description": "Entity sound definitions",
"properties": {
2021-03-21 15:18:38 +01:00
"volume": { "$ref": "#/definitions/volume" },
"pitch": { "$ref": "#/definitions/pitch" },
"events": { "type": "object", "title": "Events", "propertyNames": { "pattern": "[a-z\\._]+" }, "additionalProperties": { "$ref": "#/definitions/sound_event" } }
2020-11-01 17:22:42 +01:00
}
}
},
"properties": {
"block_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Block Sounds",
2020-11-01 17:22:42 +01:00
"description": "Block sound definitions",
"additionalProperties": {
"type": "object",
2021-04-04 14:00:43 +02:00
"title": "Block Sound",
2020-11-01 17:22:42 +01:00
"description": "A single block sound definition",
"additionalProperties": false,
"properties": {
2021-03-21 15:18:38 +01:00
"volume": { "$ref": "#/definitions/volume" },
"pitch": { "$ref": "#/definitions/pitch" },
2020-11-01 17:22:42 +01:00
"events": {
"type": "object",
"title": "Events",
2021-03-21 15:18:38 +01:00
"propertyNames": { "enum": ["default", "item.use.on", "break", "hit", "place", "power.on", "power.off"] },
"additionalProperties": { "$ref": "#/definitions/sound_event" }
2020-11-01 17:22:42 +01:00
}
}
}
},
"entity_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Sounds",
2020-11-01 17:22:42 +01:00
"description": "Entity sounds definitions",
"additionalProperties": false,
"properties": {
2021-03-21 15:18:38 +01:00
"defaults": { "$ref": "#/definitions/entity_event" },
"entities": { "type": "object", "title": "Entities", "description": "Entities definitions", "additionalProperties": { "$ref": "#/definitions/entity_event" } }
2020-11-01 17:22:42 +01:00
}
},
"individual_event_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Individual Event Sounds",
2020-11-01 17:22:42 +01:00
"description": "Individual event sounds definitions",
"additionalProperties": false,
2021-03-21 15:18:38 +01:00
"properties": { "events": { "type": "object", "title": "Events", "description": "Events", "additionalProperties": { "$ref": "#/definitions/sound_event" } } }
2020-11-01 17:22:42 +01:00
},
"interactive_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Interactive Sounds",
2020-11-01 17:22:42 +01:00
"description": "Interactive sounds definitions",
"additionalProperties": false,
"properties": {
"block_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Block Sounds",
2020-11-01 17:22:42 +01:00
"description": "Block sound definitions",
"additionalProperties": {
"type": "object",
2021-04-04 14:00:43 +02:00
"title": "Block Sound",
2020-11-01 17:22:42 +01:00
"description": "A single block sound definition",
"additionalProperties": false,
"properties": {
2021-01-10 17:34:21 +01:00
"volume": { "$ref": "#/definitions/volume" },
"pitch": { "$ref": "#/definitions/pitch" },
2020-11-01 17:22:42 +01:00
"events": {
"type": "object",
"title": "Events",
2021-03-21 15:18:38 +01:00
"propertyNames": { "enum": ["default", "fall", "step", "hit", "jump", "land"] },
2020-11-01 17:22:42 +01:00
"additionalProperties": {
2021-04-04 14:00:43 +02:00
"title": "Sound Event",
2020-11-01 17:22:42 +01:00
"description": "A single sound event definition",
"oneOf": [
2021-01-10 17:34:21 +01:00
{ "type": "string" },
2020-11-01 17:22:42 +01:00
{
"type": "object",
"additionalProperties": false,
"minProperties": 1,
"properties": {
2021-01-10 17:34:21 +01:00
"volume": { "$ref": "#/definitions/volume" },
2021-03-21 15:18:38 +01:00
"sound": { "type": "string", "title": "Sound Event", "description": "The sound event described in sound_definitions.json" },
2021-01-10 17:34:21 +01:00
"pitch": { "$ref": "#/definitions/pitch" }
2020-11-01 17:22:42 +01:00
}
}
]
}
}
}
}
},
"entity_sounds": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Sounds",
2020-11-01 17:22:42 +01:00
"description": "Entity sound definitions",
"additionalProperties": false,
"properties": {
"defaults": {
"type": "object",
"title": "Defaults",
"description": "Default sound definitions",
"additionalProperties": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Sounds",
2020-11-01 17:22:42 +01:00
"properties": {
"events": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Events",
"propertyNames": { "pattern": "[a-z0-9\\.]+" },
2020-11-01 17:22:42 +01:00
"additionalProperties": {
"type": "object",
"title": "Entity Event",
"description": "A single entity event",
2021-03-21 15:18:38 +01:00
"additionalProperties": { "type": "string", "title": "A Sound Interaction" }
2020-11-01 17:22:42 +01:00
}
}
}
},
2021-03-21 15:18:38 +01:00
"properties": { "volume": { "$ref": "#/definitions/volume" }, "pitch": { "$ref": "#/definitions/pitch" } }
2020-11-01 17:22:42 +01:00
},
"entities": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entites Sounds",
2020-11-01 17:22:42 +01:00
"description": "Entities sound definitions",
"additionalProperties": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Sounds",
2020-11-01 17:22:42 +01:00
"properties": {
2021-03-21 15:18:38 +01:00
"volume": { "$ref": "#/definitions/volume" },
"pitch": { "$ref": "#/definitions/pitch" },
2020-11-01 17:22:42 +01:00
"events": {
"type": "object",
2021-03-21 15:18:38 +01:00
"title": "Entity Events",
"propertyNames": { "pattern": "[a-z0-9\\.]+" },
2020-11-01 17:22:42 +01:00
"additionalProperties": {
"type": "object",
"title": "Entity Event",
"description": "A single entity event",
2021-03-21 15:18:38 +01:00
"additionalProperties": { "type": "string", "title": "A Sound Interaction" }
2020-11-01 17:22:42 +01:00
}
}
}
}
}
}
}
}
}
}
}