Coordinates in commands run by players get shifted up by half a block
Stand on a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing on will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.
This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
Environment
Operating system: OSX 10.9.5
Java Version: 1.6.0_65
Linked Issues
Created Issue:
Coordinates in commands run by players get shifted up by half a block
Stand in a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing in will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.
This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
Environment
Operating system: OSX 10.9.5
Java Version: 1.6.0_65
Dupe of
MC-56253
is duplicated by
duplicates
is duplicated by
Stand
in a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing in will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
Stand on a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing in will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.
This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
Stand on a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing
in will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
Stand on a partial block, like cake, slab, or chest. Run the command "/setblock ~ ~ ~ stone" The block above the one you are standing on will be set to stone. This only occurs if the block is thick enough, if run on a carpet for example, it will work correctly. Interestingly, if run on a 4-layer thick snow cover, it will work correctly, even though that is the same height as cake, which doesn't work correctly. This is because the player sinks 2 pixels into snow.
This bug only occurs when the command is directly run by the player, if you instead run "/execute @p ~ ~ ~ setblock ~ ~ ~ stone", it will work correctly.
duplicates
duplicates
Confirmed for 1.8.2 pre-1. MC-76491 has better information, so I would suggest that become the main post.
Actually this is a dupe ofMC-67515(which based on this report seems to affect all relative coordinates, not just with /summon).While 56253 has command blocks in the background, it talks about /execute from the player, not a command block (notice the command in the chat in the 1st screenshot).Actually, I think both
MC-56253andMC-67515are both describing different aspects of the same bug.Nvm, it seems that I've misread the title. On second thought this seems different than
MC-67515, since that issue doesn't involve partial blocks at all; rather it seems that entities are being summoned from the center of the command block (as opposed to the bottom, as with players). Using either"/summon Creeper ~ ~2 ~ {NoAI:1}"or an execute with it summons a NoAI Creeper exactly 2 blocks above the player's feet, so /summon seems to work differently.
Basically this is the opposite of
MC-56253(execute places the block 1 block higher than just using /setblock).If it is setblock, I think that the Y coordinates will round up instead of down. If for example, if the block you are standing on is 0.850 blocks high, the setblock will round up.
This is actually a dupe of
MC-56253, notMC-67515.This is not a duplicate of
MC-67515. That report is about command blocks executing from their center, this report is about relative coordinates being treated differently depending on whether they are in an execute command or not. This report is actually a dupe ofMC-56253.