Why won't my location predicate run?
By Mia Morrison •
I have followed several tutorials to the letter, and got the "player is_sprinting:true" predicate to work. So I know my fresh new datapack is working.
There are no examples of location predicates anywhere. Videos, wiki, nothing.
I go to a generator and generate the whole predicate, export the whole file, put it in the proper folder, and when I type the path in my tick.mcfunction, visual studio code properly links to it (finally after having to create a new project AND restart my computer to not have the new project auto-fill paths to my old project- for some reason).
It does not detect when a player is within 100 of 0 0 0. It does nothing. Here's what I've tried:
{ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { "type": "minecraft:player", "location": { "position": { "x": 0, "y": 0, "z": 0 } }, "distance": { "absolute": { "min": 0, "max": 100 } } }
}And...
{ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { "type": "minecraft:player", "distance": { "absolute": { "min": 0, "max": 100 } } }
}And...
{ "condition": "minecraft:location_check", "predicate": { "position": { "x": { "min": -100, "max": 100 }, "y": { "min": -100, "max": 100 }, "z": { "min": -100, "max": 100 } } }
}All combined with:
execute as @a if predicate test:homezone run say hiOr:
execute as @a[predicate=homezone] run say hiWhat's my problem?
2 Reset to default