2
No Gravity Command unuseable in Version 1.5.2
Im trying to get the Crossbow to fire arrows that go straight forward, ignoring gravity. I found this command that would work in Version 1.12.2 that i tried writing in a command block:
/entityarrow @e[type=arrow] {NoGravity:1}
Is there an alternative command or a tweak that would get this to work in Version 1.15.2?
/entityarrow @e[type=arrow] {NoGravity:1}
Is there an alternative command or a tweak that would get this to work in Version 1.15.2?
Create an account or sign in to comment.
6
2
/execute as @e[type=arrow] run data merge entity @s {NoGravity:1b}
2
Just to explain this a little more:
"/execute as" makes the command after "run" execute for every arrow. This is required, because for some stupid reason the data command only allows targetting one entity.
@s refers to the executing entity, which is the arrow in this case
The "b" in "{NoGravity:1b}" indicates the data type, an integer from -127 to 127. You can find the NBT structure here. And you can find instructions on how to write data types here.
An alternative is:
/execute as @e[type=arrow] run data modify entity @s NoGravity set value 1b
I had exactly the same reaction when 1.13 changed tons of commands, I actually took a break for months if not years. Once I discovered the potential of the new command, I was totally on board.
"/execute as" makes the command after "run" execute for every arrow. This is required, because for some stupid reason the data command only allows targetting one entity.
@s refers to the executing entity, which is the arrow in this case
The "b" in "{NoGravity:1b}" indicates the data type, an integer from -127 to 127. You can find the NBT structure here. And you can find instructions on how to write data types here.
An alternative is:
/execute as @e[type=arrow] run data modify entity @s NoGravity set value 1b
I had exactly the same reaction when 1.13 changed tons of commands, I actually took a break for months if not years. Once I discovered the potential of the new command, I was totally on board.
1
Wh- WHY IS IT THAT NOW?! The command worked fine in 1.12.2 and now they've changed it to this mess, this is why I don't use the new versions I cannot use the ruined commands.
1
/execute is actually so much more powerful now.
Its literally comparing the 1.12 commands to a beginners programming language, like Python to a much more advanced one like C++/Java.
With /execute we can make:
raycasting without tons of command blocks
directional teleportation without tons of command blocks
Homing Missiles using the new /execute store
Pewdiepie/water sheep boss Mainly the teleportation of entity models and entities
And these are the ones I remember
Its literally comparing the 1.12 commands to a beginners programming language, like Python to a much more advanced one like C++/Java.
With /execute we can make:
raycasting without tons of command blocks
directional teleportation without tons of command blocks
Homing Missiles using the new /execute store
Pewdiepie/water sheep boss Mainly the teleportation of entity models and entities
And these are the ones I remember
1
entityarrow is not a command and to my knowledge never was. could possible be a mod. you might mean entitydata which has been somehow changed into part of the /execute command. i dont know how
2
Pretty sure op was talking about /entitydata