mojira.dev
MC-58097

Coordinates Are Messed Up

The block that I am "looking at" is not the same as when I stand in the same space. When using /setblock and related commands you have to enter the "looking at" coordinates, which are different than if standing there.

Linked issues

Attachments

Comments 15

Cannot confirm, see screenshots.

Look at the last screenshot. You are apparently at different coordinates than the ones you are looking at.

you stand on the block so your y cord is 1 higher, thats intended.
if this isn't what you mean, please explain it better

No, I'm standing on block -16 / 96 and I'm looking on -16 / 96.
Of yourse my feet are on level 64 - the top of block 63.

What other results do you except from my screenshots ?

In the third screenshot it says you are standing on -15, but looking at -16. I might record a video tomorrow to show what I see when I go in game.

5 more comments

The block coordinates go from -2 -1 0 1 2 etc, but there is no block -0.
Therefore while standing on a block 2 your coordinates are e.g. 2.123 but while standing on a block -2 your coordinates are -1.123.
See MC-4794 and MC-36602

The video does clarify your meaning, thanks. However, this isn't a bug in the game (note that your "Block" and "Looking At" are always the same when looking down at the block at your feet). The XYZ values only appear different due to the way they are counted. Kumasasa explains this well in MC-4794, as quoted below:

Please take a closer look at the coordinates.
The coordinates mark the corners of the blocks.
If you omit the fractional digits, you land always at the center of the nearest block (seen in +x, +z direction):
If you teleport to 1 / y / 1, you land at 1.5 / y /1.5
If you teleport to -1 / y / -1 you land at -0,5 / y / -0.5
but if you specify the fractinonal digits, you land excactly at given coordinates:
If you teleport to 1.0 / y / 1.0, you land at 1.0 / y /1.0
If you teleport to -1.0 / y / -1.0 you land at -1.0 / y / -1.0

And continued:

Think of a coordinate system on graph paper. The axes of the coordinate system go exactly through each one line on the paper, the squares on the paper are the blocks.
--> The integer coordinates mark the corners of the blocks, not the blocks itself.
If you teleport to (0.0/0.0), you land on the exact center of the coordinate system.
If you teleport to (0/0), you land on the middle of the block right of the Z axis and below the X axis (Yellow block), but at the coordinates (0.5/0.5)
If you teleport to (-1/0), you land on the middle of the block left of the Z axis and below the X axis (Green block), but at the coordinates (-0.5/0.5)

Ok, thanks, I see now. Sorry for the waste of time.

Reese Gosain

(Unassigned)

Unconfirmed

Minecraft 14w21b, Minecraft 14w25a, Minecraft 14w25b

Retrieved