|
2 | 2 | "$schema": "http://json-schema.org/draft-07/schema#", |
3 | 3 | "$id": "https://json.schemastore.org/minecraft-pack-mcmeta.json", |
4 | 4 | "additionalProperties": false, |
5 | | - "description": "Minecraft Resource/Data Pack Metadata\nhttps://minecraft.wiki/w/Resource_pack\nhttps://minecraft.wiki/w/Data_pack", |
| 5 | + "description": "Minecraft Resource/Data Pack Metadata\nhttps://minecraft.wiki/w/Pack.mcmeta#Format", |
| 6 | + "definitions": { |
| 7 | + "packFormat": { |
| 8 | + "description": "https://minecraft.wiki/w/Pack_format", |
| 9 | + "type": "integer", |
| 10 | + "minimum": 1, |
| 11 | + "maximum": 81 |
| 12 | + }, |
| 13 | + "packFormatRange": { |
| 14 | + "anyOf": [ |
| 15 | + { |
| 16 | + "type": "array", |
| 17 | + "minItems": 2, |
| 18 | + "maxItems": 2, |
| 19 | + "items": { |
| 20 | + "$ref": "#/definitions/packFormat" |
| 21 | + } |
| 22 | + }, |
| 23 | + { |
| 24 | + "$ref": "#/definitions/packFormat" |
| 25 | + }, |
| 26 | + { |
| 27 | + "type": "object", |
| 28 | + "properties": { |
| 29 | + "min_inclusive": { |
| 30 | + "$ref": "#/definitions/packFormat" |
| 31 | + }, |
| 32 | + "max_inclusive": { |
| 33 | + "$ref": "#/definitions/packFormat" |
| 34 | + } |
| 35 | + }, |
| 36 | + "additionalProperties": false, |
| 37 | + "required": ["min_inclusive", "max_inclusive"] |
| 38 | + } |
| 39 | + ] |
| 40 | + }, |
| 41 | + "resourceLocation": { |
| 42 | + "description": "An identifier of a game object\nhttps://minecraft.wiki/w/Resource_location", |
| 43 | + "type": "string", |
| 44 | + "pattern": "(?:([a-z0-9_\\-.]+:)?|:)[a-z0-9_\\-./]+" |
| 45 | + } |
| 46 | + }, |
6 | 47 | "properties": { |
7 | 48 | "pack": { |
8 | | - "title": "pack options", |
9 | | - "description": "Options for the current pack\nhttps://minecraft.wiki/w/Data_pack#Contents", |
| 49 | + "description": "Holds the pack information.", |
10 | 50 | "type": "object", |
11 | 51 | "properties": { |
12 | 52 | "description": { |
13 | 53 | "title": "description", |
14 | | - "description": "A description for the current pack\nhttps://minecraft.wiki/w/Data_pack#Contents" |
| 54 | + "description": "A text component that appears when hovering over the pack's name in the list given by the `/datapack list` command, or when viewing the pack in the Create World screen.", |
| 55 | + "type": "string" |
15 | 56 | }, |
16 | 57 | "pack_format": { |
17 | | - "description": "A version for the current pack\nhttps://minecraft.wiki/w/Data_pack#Contents", |
18 | | - "type": "integer", |
19 | | - "minimum": 1, |
20 | | - "maximum": 48, |
21 | | - "default": 4 |
| 58 | + "$ref": "#/definitions/packFormat", |
| 59 | + "description": "Determines the version(s) of Minecraft that this pack is compatible with." |
| 60 | + }, |
| 61 | + "supported_formats": { |
| 62 | + "$ref": "#/definitions/packFormatRange", |
| 63 | + "description": "Describes a range for pack formats that this pack supports. The range has to include the value of `pack.pack_format`." |
22 | 64 | } |
23 | 65 | }, |
24 | | - "additionalProperties": false |
| 66 | + "additionalProperties": false, |
| 67 | + "required": ["description", "pack_format"] |
| 68 | + }, |
| 69 | + "features": { |
| 70 | + "description": "Section for selecting experimental features.", |
| 71 | + "type": "object", |
| 72 | + "properties": { |
| 73 | + "enabled": { |
| 74 | + "description": "List of enabled feature flags.", |
| 75 | + "type": "array", |
| 76 | + "items": { |
| 77 | + "$ref": "#/definitions/resourceLocation", |
| 78 | + "description": "Resource location of a feature flag." |
| 79 | + } |
| 80 | + } |
| 81 | + }, |
| 82 | + "additionalProperties": true, |
| 83 | + "required": ["enabled"] |
25 | 84 | }, |
26 | 85 | "filter": { |
27 | | - "title": "filter options", |
28 | | - "description": "Filter options for the current pack\nhttps://minecraft.wiki/w/Data_pack", |
| 86 | + "description": "Section for filtering out files from packs applied below this one. Any file that matches one of the blocked patterns is treated as if it was not present in the pack at all.", |
| 87 | + "type": "object", |
| 88 | + "properties": { |
| 89 | + "block": { |
| 90 | + "type": "array", |
| 91 | + "items": { |
| 92 | + "type": "object", |
| 93 | + "properties": { |
| 94 | + "namespace": { |
| 95 | + "description": "A regular expression for the namespace of files to be filtered out. If unspecified, it applies to every namespace.", |
| 96 | + "type": "string", |
| 97 | + "format": "regex", |
| 98 | + "default": "[a-z0-9_\\-.]+" |
| 99 | + }, |
| 100 | + "path": { |
| 101 | + "description": "A regular expression for the paths of files to be filtered out. If unspecified, it applies to every file.", |
| 102 | + "type": "string", |
| 103 | + "format": "regex", |
| 104 | + "default": "[a-z0-9_\\-./]+" |
| 105 | + } |
| 106 | + }, |
| 107 | + "additionalProperties": false |
| 108 | + } |
| 109 | + } |
| 110 | + }, |
| 111 | + "additionalProperties": false |
| 112 | + }, |
| 113 | + "overlays": { |
| 114 | + "description": "Section for specifying the overlays, which are sub-packs applied over the \"normal\" contents of a pack. Their directories have their own assets and data directories, and are placed in the pack's root directory.", |
| 115 | + "type": "object", |
| 116 | + "properties": { |
| 117 | + "entries": { |
| 118 | + "description": "List of overlays. The order is important, as the first in the list is applied first.", |
| 119 | + "type": "array", |
| 120 | + "items": { |
| 121 | + "description": "An overlay.", |
| 122 | + "type": "object", |
| 123 | + "properties": { |
| 124 | + "formats": { |
| 125 | + "$ref": "#/definitions/packFormatRange", |
| 126 | + "description": "A range of pack formats when this overlay should be active." |
| 127 | + }, |
| 128 | + "overlay": { |
| 129 | + "description": "The directory to overlay for the respective versions.", |
| 130 | + "type": "string", |
| 131 | + "pattern": "[a-z0-9_-]+" |
| 132 | + } |
| 133 | + }, |
| 134 | + "additionalProperties": false, |
| 135 | + "required": ["formats", "overlay"] |
| 136 | + } |
| 137 | + } |
| 138 | + }, |
| 139 | + "additionalProperties": false, |
| 140 | + "required": ["entries"] |
| 141 | + }, |
| 142 | + "language": { |
| 143 | + "description": "Contains additional languages to add to the language menu. Only present in resource packs.", |
29 | 144 | "type": "object", |
30 | 145 | "additionalProperties": { |
31 | | - "title": "pattern", |
32 | | - "description": "A pattern for the current pack\nhttps://minecraft.wiki/w/Data_pack", |
33 | 146 | "type": "object", |
34 | 147 | "properties": { |
35 | | - "namespace": { |
36 | | - "description": "A namespace regular expression for the current pack\nhttps://minecraft.wiki/w/Data_pack", |
| 148 | + "name": { |
| 149 | + "description": "The full name of the language", |
37 | 150 | "type": "string" |
38 | 151 | }, |
39 | | - "path": { |
40 | | - "description": "A path regular expression for the current pack\nhttps://minecraft.wiki/w/Data_pack", |
| 152 | + "region": { |
| 153 | + "description": "The country or region name", |
41 | 154 | "type": "string" |
| 155 | + }, |
| 156 | + "bidirectional": { |
| 157 | + "description": "If true, the language reads right to left.", |
| 158 | + "type": "boolean" |
42 | 159 | } |
43 | 160 | }, |
44 | | - "additionalProperties": false |
| 161 | + "additionalProperties": false, |
| 162 | + "required": ["name", "region"] |
45 | 163 | } |
46 | 164 | }, |
47 | 165 | "fusion": { |
48 | 166 | "$comment": "Fusion properties for Minecraft resource packs", |
49 | 167 | "$ref": "https://json.schemastore.org/partial-fusion-pack-metadata.json#/definitions/fusion-properties" |
50 | 168 | } |
51 | 169 | }, |
52 | | - "title": "pack metadata", |
53 | | - "type": "object" |
| 170 | + "type": "object", |
| 171 | + "required": ["pack"] |
54 | 172 | } |
0 commit comments