๐๏ธ tryashtar ยท 4 points ยท Posted at 02:42:44 on May 22, 2016 ยท (Permalink)
In previous versions of Minecraft, the command /tp @e[type=Pig] ~ ~5~ would teleport every pig up five blocks.
As of the 1.10 snapshots (at least, this is where I first noticed it), this is no longer the case. A command block with that command will indeed teleport every pig up five blocks.
However, if an entity executes that command, something else happens. /execute @e[type=Cow] ~ ~ ~ tp @e[type=Pig,r=3] ~ ~5 ~
That command (pre-1.10) would tell every cow to teleport nearby pigs up by five blocks. In 1.10, it tells every cow to teleport nearby pigs five blocks above the cow.
The distinction is that previously, /tp always teleported entities relative to themselves. The sender's coordinates were ignored. Now, /tp first brings the entity to the sender, then teleports them relative to it. Again, this only happens with /execute or with commands typed in the chat--not command blocks.
This means, to get the old behavior, you'd have to type execute @e[type=Cow] ~ ~ ~ execute @e[type=Pig,r=3] ~ ~ ~ tp @e[type=Pig,c=1] ~ ~5 ~.
It's longer, uglier, and has nested executes.
The new behavior IS quite nice sometimes, but the old behavior was helpful too. This is why I suggest another argument to /tp.
I have no idea where this argument will go (especially because /tp has many different syntaxes), but the gist is that it has two options:
teleport the selected entity relative to the sender (new)
teleport the selected entity relative to itself (old)
Maybe something like /tp @e[type=Pig] ~ ~5 ~ sender vs /tp @e[type=Pig] ~ ~5 ~ relative.
Thanks for reading <3
[deleted] ยท 2 points ยท Posted at 10:05:04 on May 22, 2016 ยท (Permalink)
/execute