Skip to content

Commit 4aa9cec

Browse files
committed
More 1.21.100 entity components
1 parent 2e85292 commit 4aa9cec

5 files changed

Lines changed: 114 additions & 26 deletions

File tree

packages/minecraftBedrock/schema/entity/v1.21.100/behaviors/behavior.place_block.json

Lines changed: 38 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -41,28 +41,53 @@
4141
"description": "Weighted block descriptors for which blocks should be randomly placed, if empty the entity will try to place its carried block from placeable_carried_blocks.",
4242
"type": "array",
4343
"items": {
44-
"$ref": "../../../general/blockDescriptor.json"
44+
"type": "object",
45+
"properties": {
46+
"block": {
47+
"title": "Block",
48+
"$ref": "../../../general/blockReference.json"
49+
},
50+
"weight": {
51+
"title": "Weight",
52+
"type": "number"
53+
}
54+
},
55+
"additionalProperties": false
4556
}
4657
},
4758
"xz_range": {
4859
"title": "XZ Range",
4960
"description": "XZ range from which the entity will try and place blocks in.",
50-
"type": "array",
51-
"items": {
52-
"type": "integer"
53-
},
54-
"minItems": 2,
55-
"maxItems": 2
61+
"anyOf": [
62+
{
63+
"type": "integer"
64+
},
65+
{
66+
"type": "array",
67+
"items": {
68+
"type": "integer"
69+
},
70+
"minItems": 2,
71+
"maxItems": 2
72+
}
73+
]
5674
},
5775
"y_range": {
5876
"title": "Y Range",
5977
"description": "Y Range from which the entity will try and place blocks in.",
60-
"type": "array",
61-
"items": {
62-
"type": "integer"
63-
},
64-
"minItems": 2,
65-
"maxItems": 2
78+
"anyOf": [
79+
{
80+
"type": "integer"
81+
},
82+
{
83+
"type": "array",
84+
"items": {
85+
"type": "integer"
86+
},
87+
"minItems": 2,
88+
"maxItems": 2
89+
}
90+
]
6691
}
6792
},
6893
"additionalProperties": false

packages/minecraftBedrock/schema/entity/v1.21.100/behaviors/behavior.take_block.json

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -44,22 +44,36 @@
4444
"xz_range": {
4545
"title": "XZ Range",
4646
"description": "XZ range from which the entity will try and take blocks from.",
47-
"type": "array",
48-
"items": {
49-
"type": "integer"
50-
},
51-
"minItems": 2,
52-
"maxItems": 2
47+
"anyOf": [
48+
{
49+
"type": "integer"
50+
},
51+
{
52+
"type": "array",
53+
"items": {
54+
"type": "integer"
55+
},
56+
"minItems": 2,
57+
"maxItems": 2
58+
}
59+
]
5360
},
5461
"y_range": {
5562
"title": "Y Range",
5663
"description": "Y Range from which the entity will try and take blocks from.",
57-
"type": "array",
58-
"items": {
59-
"type": "integer"
60-
},
61-
"minItems": 2,
62-
"maxItems": 2
64+
"anyOf": [
65+
{
66+
"type": "integer"
67+
},
68+
{
69+
"type": "array",
70+
"items": {
71+
"type": "integer"
72+
},
73+
"minItems": 2,
74+
"maxItems": 2
75+
}
76+
]
6377
}
6478
},
6579
"additionalProperties": false

packages/minecraftBedrock/schema/entity/v1.21.100/components/_main.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@
216216
"$ref": "../../v1.16.0/components/equipment.json"
217217
},
218218
"minecraft:equip_item": {
219-
"$ref": "../../v1.16.0/components/equip_item.json"
219+
"$ref": "../../v1.21.100/components/equip_item.json"
220220
},
221221
"minecraft:experience_reward": {
222222
"$ref": "../../v1.16.0/components/experience_reward.json"
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema",
3+
"additionalProperties": false,
4+
"description": "The entity puts on the desired equipment.",
5+
"type": "object",
6+
"title": "Equip Item",
7+
"properties": {
8+
"can_wear_armor": {
9+
"title": "Can Wear Armor",
10+
"description": "Specifies if equipped armor should be added to the armor slot or hand slot",
11+
"type": "boolean",
12+
"default": true
13+
},
14+
"excluded_items": {
15+
"title": "Excluded Items",
16+
"description": "List of items that the entity should not equip.",
17+
"type": "array",
18+
"items": {
19+
"type": "object",
20+
"properties": {
21+
"item": {
22+
"$ref": "../../../general/reference/identifiers.json#/definitions/item_identifiers"
23+
}
24+
}
25+
}
26+
}
27+
}
28+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"$schema": "https://json-schema.org/draft-07/schema",
3+
"anyOf": [
4+
{
5+
"$ref": "./reference/identifiers.json#/definitions/block_identifiers"
6+
},
7+
{
8+
"type": "object",
9+
"properties": {
10+
"name": {
11+
"title": "Name",
12+
"$ref": "./reference/identifiers.json#/definitions/block_identifiers"
13+
},
14+
"states": {
15+
"title": "States",
16+
"$ref": "./blockState.json"
17+
}
18+
}
19+
}
20+
]
21+
}

0 commit comments

Comments
 (0)