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.

Draco18s

Members
  • Joined

  • Last visited

Everything posted by Draco18s

  1. Possibly the parent class, BlockFalling.
  2. Uh...? public class InscriberWrapper { public final ItemStack item1; public final ItemStack item2; public final ItemStack item3; public InscriberWrapper(ItemStack first, ItemStack second, ItemStack third) { item1 = first; item2 = second; item3 = third; } ... private Map<InscriberWrapper, ItemStack> dualList = new HashMap();
  3. if(null) { do one thing } else { do another}
  4. IBlockState state = someBlock.getDefaultState().withProperty(FACING,EnumFacing.WEST).withProperty(SomeOtherProp, Value); world.setBlockState(pos, state, 3); That's up to your blockstate.json file.
  5. #1 your formatting in a couple of places is awful. #2 you do not need a getter method for your static property #3 why are you using an integer to represent direction? Why not use BlockDirectional.FACING? #4 why are you setting the block twice? world.setBlockState(posNumber, ModBlocks.orangegoo.getDefaultState()); world.setBlockState(posNumber, state.withProperty(SDIR, direction), 6); You should only need the second line, but why are you using flags 2,4 and not 1,2? #5 your updateTick method is garbage. EnumFacing.values and pos.offset(facing) exist, not to mention EnumFacing#getOpposite().
  6. You don't need to override the setDefaultState method, you just need to invoke it (which you're already doing).
  7. Put a breakpoint on the canSmeltOn method, and step through line by line to figure out why it's not getting a result.
  8. Hmm. You might have to step through in the debugger.
  9. Use IItemHandler fields and getCapabilities
  10. Oh, by the way. Be aware of the BlockEvent.CropGrowEvent and its two sub events. You should fire these at the appropriate times if you are not using subclassing a class that does, or not calling super.updateTick(). Look at BlockCrops, Reeds, Cactus, Netherwart, CocoPods, and a couple others for examples of useage.
  11. Hmm, thought one of your other threads was....never mind
  12. Your structure is 3 blocks by 3 blocks, there's no....room to shift things about.
  13. You realize that all bounding boxes in Minecraft are cuboid, right?
  14. Do you mean models > block? Depends on which tiddly wink you actually want. He said "texture" in the thread title, I pointed towards the texture folder.
  15. Post your ItemUtil.areItemsEqual method.
  16. Referenced Libraries > forge[...].jar > assets > minecraft > textures > blocks
  17. One of his other threads is about is.
  18. You never register your mob on the server. Also, do not use registerGlobalEntityID, you do not need it. There's a reason registerModEntity exists.
  19. BlockCrops and BlockReeds both use integers. By the way, be aware of the BlockEvent.CropGrowEvent and its two sub events. You should fire these at the appropriate times if you are not using subclassing a class that does, or not calling super.updateTick(). Look at BlockCrops, Reeds, Cactus, Netherwart, CocoPods, and a couple others for examples of useage.
  20. My guess is: public boolean isUseableByPlayer(EntityPlayer player) { return false; } Try returning true.
  21. Show your InventoryResult class.
  22. [me=Draco18s]starts writing the packet info to handle the data transmission only...[/me] Aw fuck. The filter rules can change while the inventory is open (that is how one alters them). Which means that what items are valid for the standard inventory slots also changes. There's no easy way to find all possible rule TileEntities and check every item against all of those TEs for insertion from every side. Complexity comes out to... something in the neighborhood of O(kn2) where k is 3 times a subset of n (does that make it O(n2logn) ?). Heck the packet itself could contain upwards of 5kb(?) worth of data too. Each item would need to be paired with a minimum of 3 bits of information per TileEntity found within that list of 36 items, plus 1 bit for being allowed into the rules slots. So 1 bit per item + 3 bits per item per item. And each itemblock that has a TE could potentially need to check 16 possible states to insure validity, meaning as many as 576 setblock operations (average is probably closer to 18). There's got to be an easier way.

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.