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.

DirtyDan_

Members
  • Joined

  • Last visited

  1. Ok, so I'm updating my mod to 1.8, and I have a custom rendered block that I want to face the player when placed down. The code I was using worked in 1.7, but in 1.8 it has a couple errors that I can't seem to fix. It really boils down to two errors in the block class. Here is where the error is located: public void onBlockPlacedBy(World world, int x, int y, int z, EntityLivingBase entityLiving, ItemStack itemStack) { int facing = MathHelper.floor_double((double) ((entityLiving.rotationYaw * 4F) / 360F) + 0.5D) & 3; TileEntity te = world.getTileEntity(x, y, z); if (te != null && te instanceof TileEntityNameHere) { TileEntityNameHere facedte = (TileEntityNameHere) te; facedte.setFacing(facing); world.markBlockForUpdate(x, y, z); } } More specifically, the two errors: TileEntity te = world.getTileEntity(x, y, z); world.markBlockForUpdate(x, y, z); If anyone knows of a fix for this, that would be great!

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.