Skip to content

Custom Criteria #4098

Sep 17, 2024 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

You can use the minecraft:location criterion to implement this behavior. The 'Light as a Rabbit' advancement in vanilla Minecraft has a similar requirement to what you describe (walking on powder snow with leather boots) which you can use as an example.

The following is the relevant part of the advancement JSON required for this behavior:

{
	"criteria": {
		"walk_on_<your block name>": {
			"trigger": "minecraft:location",
			"conditions": {
				"player": [
					{
						"condition": "minecraft:entity_properties",
						"entity": "this",
						"predicate": {
							"stepping_on": {
								"block": {
									"blocks": "<your block id here>"
								}
							}
						}
					}
				]
			}
		}…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Leventeand2
Comment options

Answer selected by Leventeand2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
2 participants