From 36866067ca4d646c60af1194d127fc9f1f1ebf35 Mon Sep 17 00:00:00 2001 From: DaanV2 Date: Wed, 20 Apr 2022 12:11:11 +0200 Subject: [PATCH] Added has_silk_touch --- source/behavior/entities/filters/filters.json | 1 + .../filters/filters/has_silk_touch.json | 32 +++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 source/behavior/entities/filters/filters/has_silk_touch.json diff --git a/source/behavior/entities/filters/filters.json b/source/behavior/entities/filters/filters.json index 66a22cb7..60d336b5 100644 --- a/source/behavior/entities/filters/filters.json +++ b/source/behavior/entities/filters/filters.json @@ -91,6 +91,7 @@ { "if": { "properties": { "test": { "const": "has_mob_effect" } } }, "then": { "$ref": "./filters/has_mob_effect.json" } }, { "if": { "properties": { "test": { "const": "has_nametag" } } }, "then": { "$ref": "./filters/has_nametag.json" } }, { "if": { "properties": { "test": { "const": "has_ranged_weapon" } } }, "then": { "$ref": "./filters/has_ranged_weapon.json" } }, + { "if": { "properties": { "test": { "const": "has_silk_touch" } } }, "then": { "$ref": "./filters/has_silk_touch.json" } }, { "if": { "properties": { "test": { "const": "has_tag" } } }, "then": { "$ref": "./filters/has_tag.json" } }, { "if": { "properties": { "test": { "const": "has_target" } } }, "then": { "$ref": "./filters/has_target.json" } }, { "if": { "properties": { "test": { "const": "has_trade_supply" } } }, "then": { "$ref": "./filters/has_trade_supply.json" } }, diff --git a/source/behavior/entities/filters/filters/has_silk_touch.json b/source/behavior/entities/filters/filters/has_silk_touch.json new file mode 100644 index 00000000..e64caafa --- /dev/null +++ b/source/behavior/entities/filters/filters/has_silk_touch.json @@ -0,0 +1,32 @@ +{ + "$id": "blockception.minecraft.behavior.entities.filters.has_silk_touch", + "type": "object", + "title": "Has Silk Touch", + "description": "Tests if the subject is holding an item with silk touch.", + "properties": { + "test": { + "type": "string", + "title": "Test", + "description": "The test property" + }, + "operator": { + "$ref": "./types/operator.json" + }, + "subject": { + "$ref": "./types/subject.json" + }, + "value": { + "description": "True or false.", + "type": "boolean", + "default": true, + "title": "Value" + } + }, + "examples": [ + { + "test": "has_silk_touch", + "subject": "other", + "value": true + } + ] +}