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.

TheTrollingTrollguy

Forge Modder
  • Joined

  • Last visited

Everything posted by TheTrollingTrollguy

  1. oh, I didn't know that tutorial was there, I'll play with it later because I thought that somebody will reply on this most later... thanks anyways!
  2. Hey guys! Does anyone know how to make my mod load a block ID from a .txt file?
  3. you should override the onBlockPlacedBy method in this method you can get the block ID and the metadata so it would look like this: @Override public void onBlockPlacedBy(World world, int X, int Y, int Z, EntityLivingBase entityLivingBase, ItemStack itemStack) { int metadata = world.getBlockMetadata(X, Y, Z); int playerDirection = MathHelper.floor_double((double)((entityLivingBase.rotationYaw * 4F) / 360F) + 0.5D) & 3; if(metadata == 0) { switch(playerDirection) { // then you put here what metadata will be placed based on where you're pointing at like this case 0: metadata = 2; break; } } world.setBlock(X, Y, Z, blockID, metadata, 2); }
  4. I tried, but it doesn't work. Mybe I should put it in another function's body?
  5. I know that, I just asked that because I thought that he didn't write something at the end of his post. That's all. I have patience.
  6. yes, I am able to figure the half directions, but can you please paste an example code, beacuse I get stuck with some parts...
  7. Hey guys. It's me. Again! Last time I asked for help, I didn't get any help, so once again. I need to make a function that will check where the player is pointing at(south, Southeast, east and so on...) and to check which metadata of the block is placed. I can't explain so well with what do I need help. So here is the thing for one block: first and the second metadata of blocks are regular blocks. They have no special things. So the third metadata has an arrow texture on top of it pointing at north, the fourth should be pointing at Northwest and so on. I have made all these textures. So if the player places the block with the third metadata while his pointing at west, the metadata placed on the world will be fifth one or number 4. Can you help me guys, please! If you don't understand what I just have written then I'll explain it again.
  8. Hey guys! Does anybody know how to make a block fuction that cheks where the player is pointing at and based on that it places a block with different metadata. Example: if the player is facing south and has clicked to place a block with metadata 0, the metadata placed will be 2. Please help!

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.