2
Do you see a problem with this command? i don't, but minecraft does. help?
the command is this:
"/execute as @e[tag=sportal] at @s positioned ~-2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2] positioned ~2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2] run..."
the if parameters are both met, and i know that for a fact because when i use
"positioned ~-2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2]"
and
"positioned ~2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2]"
individualy it works.
so what wrong here?
"/execute as @e[tag=sportal] at @s positioned ~-2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2] positioned ~2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2] run..."
the if parameters are both met, and i know that for a fact because when i use
"positioned ~-2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2]"
and
"positioned ~2.5 ~6 ~8.5 if entity @e[type=minecraft:zombie,distance=..2]"
individualy it works.
so what wrong here?
Create an account or sign in to comment.
5
1
wtf is a sportal ? xD
2
it's a portal, but i have multiple, so this one is an s portal, a sportal
2
If you run the parameters individually, each one will be based off the context from the at @s. If you combine them into one command one after the other, the last positioned will add on to the previous positioned, so effectively at the end of your command it acts as ~0 ~12 ~17.
It looks like you're trying to check ~-2.5 and ~2.5 of a position. You already set one coordinate with the first positioned, so to get from -2.5 to 2.5 for the second, you need to add 5, making it positioned ~5 ~ ~. Think of it like you're moving from place to place.
Hopefully that is what you're trying to do. Out of curiosity, what's the goal of this?
It looks like you're trying to check ~-2.5 and ~2.5 of a position. You already set one coordinate with the first positioned, so to get from -2.5 to 2.5 for the second, you need to add 5, making it positioned ~5 ~ ~. Think of it like you're moving from place to place.
Hopefully that is what you're trying to do. Out of curiosity, what's the goal of this?
1
thank you, this actualy makes a lot of sense, i feel kinda stupid for not realizing it.
2
No problem, I've also done the exact same thing!