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. You have to register your event handler. Your init method, by the way, does nothing, so I'm not sure why you tried that. https://mcforge.readthedocs.io/en/latest/events/intro/
  2. This is only true for creating your own blocks, the OP seems to be looking for something else. Also this is not sufficient. You also have to add the WATERLOGGED property to your block's blockstatecontainer.
  3. Textures basically work the same, but I believe the directory name changed from blocks to block.
  4. What? What are you trying to do? Create your own block or edit vanilla blocks?
  5. What part are you having trouble with? A chest is a block, a tile entity, an ItemStackHandler in that tile entity, and a GUI with GuiContainer.
  6. Depends on what you're doing. Does the client need to know about it?
  7. Unclear, as because you were piping things through commands, it probably got quashed.
  8. Tada, magic. Always use the right properties. And for the record, it was throwing an error, you just couldn't see it.
  9. You can specify multiple textures and Minecraft will grab them at random based on the block's position automatically. I don't remember exactly how to do it though.
  10. ...new? I haven't changed it in forever
  11. Lets go look at the Item class and see what the default looks like, shall we? public ActionResult<ItemStack> onItemRightClick(World worldIn, PlayerEntity playerIn, Hand handIn) { if (this.isFood()) { //... return new ActionResult<>(ActionResultType.SUCCESS, itemstack); //... return new ActionResult<>(ActionResultType.FAIL, itemstack); //... } return new ActionResult<>(ActionResultType.PASS, playerIn.getHeldItem(handIn)); //.. } HMM
  12. https://github.com/Merthew/MerthewTweaks/blob/master/src/main/java/com/example/merthewtweaks/util/ItemRegistry.java#L16 Problematic Code #14
  13. And what does Eclipse say if you hover over it?
  14. OH MAN, guess how many people do that? None. Basically none.
  15. Yes. There are vanilla blocks that utilize similar things, like wool and carpet.
  16. As an example: Wheat returns Items.WHEAT_SEEDS not Items.WHEAT and cake probably returns null or air. I haven't checked 1.12 lately.
  17. That's not you. Well, not your recipe anyway. The problem is that Forge went to replace vanilla recipes with ones that utilize the Ore Dictionary and the OreDict entry was not as expected.
  18. Following what D7 said, its super amazingly easy to inject bytes that mess with other people's code. The crusade against coremods and insuring the events were present in Forge instead is a testament to that. For example, lets say there's a method that you want to exit early (effectively cancelling behavior) and so you insert that code at the top of the method, couple of JVM-bytes for "get value, test against zero, return, else jump." Someone else wants to put functionality at the end of that method and knows that there's only 1 return statement. So they write some ASM code that "finds first return, insert new functionality before it." Guess what? Your patch just messed up theirs (and depending on how you set up your "else jump" their patch might mess up yours). Were they right to find the first return rather than the last? No. But their code in isolation works Just Fine.
  19. for 1.12 you'd have to use getActualState and look for connectivity (adjacent blocks) and update the IBlockState as neccessary. for 1.14 this sort of functionality has been migrated to getExtendedState AFAICT for 1.13, update to 1.14

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.