Skip to content

Commit fc85a7e

Browse files
authored
1.26.10 (#519)
* - Set min value for "lay_seconds" to be 0 * - Update drop_item_for * - Update fertilize_farm_block * - Update harvest_farm_block * - Update inspect_bookshelf * - Update lay_egg * - Update ram_attack * - Update celebrate * - Add multi_block trait * - Added field held_item_scale * - Add "movement_type" - Remove "simulate_waves" * - Require at least 1 item for detection rules * - Added reset/pause growth fields for ageable * - Split pushable * - Added is_tamed filter * - Fix lack of reference to "is_sprinting" filter * - Update canopy_decorator * - Add culling_shape to geo component * - Added chest_obstruction * - Updated ocelotattack * - Update celebrate_survive * - Update random_search_and_dig
1 parent 70c9f61 commit fc85a7e

25 files changed

Lines changed: 289 additions & 78 deletions
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"$id": "blockception.minecraft.behavior.blocks.minecraft.chest_obstruction",
3+
"title": "Chest Obstruction",
4+
"description": "[EXPERIMENTAL] Defines how a block placed above a chest or ender_chest should obstruct their opening",
5+
"type": "object",
6+
"additionalProperties": false,
7+
"required": [],
8+
"properties": {
9+
"obstruction_rule": {
10+
"title": "Obstruction Rule",
11+
"description": "How the block should be evaluated by a chest during chest opening.",
12+
"type": "string",
13+
"enum": ["always", "never", "shape"]
14+
}
15+
}
16+
}

source/behavior/blocks/format/components/geometry.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,12 @@
3939
"type": "string",
4040
"examples": ["minecraft:culling_layer.undefined", "minecraft:culling_layer.leaves"]
4141
},
42+
"culling_shape": {
43+
"title": "Culling Shape",
44+
"description": "The voxel shape used for culling adjacent block faces.",
45+
"type": "string",
46+
"examples": ["minecraft:empty", "minecraft:unit_cube"]
47+
},
4248
"uv_lock": {
4349
"anyOf": [
4450
{

source/behavior/blocks/format/components/liquid_detection.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
"properties": {
5555
"detection_rules": {
5656
"type": "array",
57+
"minItems": 1,
5758
"items": {
5859
"$ref": "#/definitions/definition_rule"
5960
}

source/behavior/blocks/format/minecraft.block.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
"additionalProperties": true,
1515
"properties": {
1616
//Components
17+
"minecraft:chest_obstruction": { "$ref": "./components/chest_obstruction.json" },
1718
"minecraft:collision_box": { "$ref": "./components/collision_box.json" },
1819
"minecraft:connection_rule": { "$ref": "./components/connection_rule.json" },
1920
"minecraft:crafting_table": { "$ref": "./components/crafting_table.json" },
@@ -96,7 +97,8 @@
9697
"properties": {
9798
"minecraft:connection": { "$ref": "./traits/connection.json" },
9899
"minecraft:placement_direction": { "$ref": "./traits/placement_direction.json" },
99-
"minecraft:placement_position": { "$ref": "./traits/placement_position.json" }
100+
"minecraft:placement_position": { "$ref": "./traits/placement_position.json" },
101+
"minecraft:multi_block": { "$ref": "./traits/multi_block.json" }
100102
}
101103
}
102104
},
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{
2+
"$id": "blockception.minecraft.behavior.blocks.traits.minecraft.multi_block",
3+
"title": "Multi Block",
4+
"description": "Used to define a block composed of multiple block parts. A multi block treats all individual parts as a single block, like Door blocks",
5+
"additionalProperties": false,
6+
"type": "object",
7+
"required": ["enabled_states", "direction"],
8+
"properties": {
9+
"enabled_states": {
10+
"title": "Enabled States",
11+
"description": "Block states you wish to enable",
12+
"type": "array",
13+
"uniqueItems": true,
14+
"minItems": 1,
15+
"items": {
16+
"enum": ["minecraft:multi_block_part"]
17+
}
18+
},
19+
"parts": {
20+
"title": "Parts",
21+
"description": "Optionally used to initialize state 'minecraft:multi_block_part'",
22+
"type": "integer",
23+
"minimum": 2,
24+
"maximum": 4
25+
},
26+
"direction": {
27+
"title": "Direction",
28+
"description": "Property used to define which direction the block parts are placed from 0 to N",
29+
"type": "string",
30+
"enum": ["up", "down"]
31+
}
32+
}
33+
}

source/behavior/entities/filters/filters.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -360,6 +360,14 @@
360360
"if": { "properties": { "test": { "const": "is_snow_covered" } } },
361361
"then": { "$ref": "./filters/is_snow_covered.json" }
362362
},
363+
{
364+
"if": { "properties": { "test": { "const": "is_sprinting" } } },
365+
"then": { "$ref": "./filters/is_sprinting.json" }
366+
},
367+
{
368+
"if": { "properties": { "test": { "const": "is_tamed" } } },
369+
"then": { "$ref": "./filters/is_tamed.json" }
370+
},
363371
{
364372
"if": { "properties": { "test": { "const": "is_sitting" } } },
365373
"then": { "$ref": "./filters/is_sitting.json" }
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"$id": "blockception.minecraft.behavior.entities.filters.is_tamed",
3+
"type": "object",
4+
"title": "Is Tamed",
5+
"description": "Tests whether the Subject is tamed.",
6+
"properties": {
7+
"test": {
8+
"type": "string",
9+
"title": "Test Property",
10+
"description": "The test property."
11+
},
12+
"operator": {
13+
"$ref": "./types/operator.json"
14+
},
15+
"subject": {
16+
"$ref": "./types/subject.json"
17+
},
18+
"value": {
19+
"title": "Value",
20+
"description": "True or false.",
21+
"type": "boolean",
22+
"default": true
23+
}
24+
},
25+
"examples": [
26+
{
27+
"test": "is_tamed",
28+
"value": true
29+
}
30+
]
31+
}

source/behavior/entities/format/behaviors/celebrate.json

Lines changed: 4 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
"additionalProperties": false,
77
"properties": {
88
"priority": { "$ref": "types/priority.json" },
9+
"control_flags": {
10+
"$ref": "./types/control_flags.json"
11+
},
912
"celebration_sound": {
1013
"description": "The sound event to trigger during the celebration.",
1114
"title": "Celebration Sound",
@@ -21,36 +24,7 @@
2124
"default": [1, 3.5],
2225
"description": "Minimum and maximum time between jumping (positive, in seconds).",
2326
"title": "Jump Interval",
24-
"oneOf": [
25-
{
26-
"type": "array",
27-
"items": [
28-
{
29-
"type": "number",
30-
"title": "Maximum"
31-
},
32-
{
33-
"type": "number",
34-
"title": "Maximum"
35-
}
36-
]
37-
},
38-
{
39-
"type": "number"
40-
},
41-
{
42-
"type": "object",
43-
"additionalProperties": false,
44-
"properties": {
45-
"range_min": {
46-
"type": "number"
47-
},
48-
"range_max": {
49-
"type": "number"
50-
}
51-
}
52-
}
53-
]
27+
"$ref": "../../../../general/vectors/number2.json"
5428
},
5529
"on_celebration_end_event": {
5630
"$ref": "../types/trigger.json",

source/behavior/entities/format/behaviors/celebrate_survive.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
"properties": {
88
"priority": { "$ref": "types/priority.json" },
99
"speed_multiplier": { "$ref": "./types/speed_multiplier.json" },
10+
"control_flags": {
11+
"$ref": "./types/control_flags.json"
12+
},
1013
"fireworks_interval": {
1114
"title": "Fireworks Interval",
1215
"$ref": "../types/range_number_type.json",

source/behavior/entities/format/behaviors/drop_item_for.json

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
"properties": {
88
"priority": { "$ref": "types/priority.json" },
99
"speed_multiplier": { "$ref": "types/speed_multiplier.json" },
10+
"control_flags": {
11+
"$ref": "./types/control_flags.json"
12+
},
1013
"entity_types": {
1114
"description": "The list of conditions another entity must meet to be a valid target to drop an item for.",
1215
"title": "Entity Types",
@@ -15,13 +18,16 @@
1518
"cooldown": {
1619
"title": "Cooldown",
1720
"type": "number",
18-
"default": 0.2,
21+
"default": 0.25,
22+
"minimum": 0,
1923
"description": "Total time that the goal is on cooldown before it can be used again."
2024
},
2125
"drop_item_chance": {
2226
"title": "Drop Item Chance",
2327
"type": "number",
2428
"default": 1.0,
29+
"minimum": 0,
30+
"maximum": 1,
2531
"description": "The percent chance the entity will drop an item when using this goal."
2632
},
2733
"goal_radius": {
@@ -39,18 +45,21 @@
3945
"title": "Max Head Look At Height",
4046
"type": "number",
4147
"default": 10.0,
48+
"minimum": 0,
4249
"description": "The maximum height the entities head will look at when dropping the item. The entity will always be looking at its target."
4350
},
4451
"minimum_teleport_distance": {
4552
"title": "Minimum Teleport Distance",
4653
"type": "number",
4754
"default": 2.0,
55+
"minimum": 0,
4856
"description": "If the target position is farther away than this distance on any tick, the entity will teleport to the target position."
4957
},
5058
"offering_distance": {
5159
"title": "Offering Distance",
5260
"type": "number",
5361
"default": 1.0,
62+
"minimum": 0,
5463
"description": "The preferred distance the entity tries to be from the target it is dropping an item for."
5564
},
5665
"on_drop_attempt": {
@@ -62,24 +71,28 @@
6271
"title": "Search Count",
6372
"type": "integer",
6473
"default": 0,
74+
"minimum": 0,
6575
"description": "The number of blocks each tick that the entity will check within its search range and height for a valid block to move to. A value of 0 will have the mob check every block within range in one tick."
6676
},
6777
"search_height": {
6878
"title": "Search Height",
6979
"type": "integer",
7080
"default": 1,
81+
"exclusiveMinimum": 0,
7182
"description": "The Height in blocks the entity will search within to find a valid target position."
7283
},
7384
"search_range": {
7485
"title": "Search Range",
7586
"type": "integer",
7687
"default": 0,
88+
"exclusiveMinimum": 0,
7789
"description": "The distance in blocks the entity will search within to find a valid target position."
7890
},
7991
"seconds_before_pickup": {
8092
"title": "Seconds Before Pickup",
8193
"type": "number",
8294
"default": 0.0,
95+
"minimum": 0,
8396
"description": "The numbers of seconds that will pass before the dropped entity can be picked up from the ground."
8497
},
8598
"target_range": {

0 commit comments

Comments
 (0)