Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Lisimba

Members
  • Joined

  • Last visited

  1. This code, in an item's onItemRightClick: log.info("onItemRightClick: getPosition {}, getPositionEyes {}, getPositionVector {}, player entity {}", playerIn.getPosition(), playerIn.getPositionEyes(1), playerIn.getPositionVector(), playerIn); Result: [19:38:54] [Client thread/INFO] [PosTest]: onItemRightClick: getPosition BlockPos{x=582, y=4, z=137}, getPositionEyes (581.5160287599339, 5.620000004768372, 136.53055861822787), getPositionVector (581.5160287599339, 4.0, 136.53055861822787), player entity EntityPlayerSP['Player921'/132, l='MpServer', x=581.52, y=4.00, z=136.53] [19:38:54] [server thread/INFO] [PosTest]: onItemRightClick: getPosition BlockPos{x=581, y=4, z=136}, getPositionEyes (581.5160287599339, 5.620000004768372, 136.53055861822787), getPositionVector (581.5160287599339, 4.0, 136.53055861822787), player entity EntityPlayerMP['Player921'/132, l='New World', x=581.52, y=4.00, z=136.53] As you can see with the output of getPositionVector the client and server agree exactly on where the player is. Yet the output of getPosition is off. The implementation in EntityPlayerSP: public BlockPos getPosition() { return new BlockPos(this.posX + 0.5D, this.posY + 0.5D, this.posZ + 0.5D); } And in EntityPlayerMP: public BlockPos getPosition() { return new BlockPos(this.posX, this.posY + 0.5D, this.posZ); } I guess this is a bug in Minecraft itself? Or is there a point to it?

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.