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.

Featured Replies

Posted

I tried to rendering my chest with BlockRendererDispatcher. But that doesn't work.

 

BlockModelShapes shape = Minecraft.getMinecraft().getBlockRendererDispatcher().getBlockModelShapes();

shape.registerBuiltInBlocks(new Block[] {DionaBlocks.diona_ancient_chest} );

 

747d22a979.png

I don't think I can help, although I question why you're using BlockRendererDispatcher and not something like what worked fro me (for a much simpler block):

 

renderItem.getItemModelMesher().register(Item.getItemFromBlock(brickBlock), 0, new ModelResourceLocation(Testmod01.MODID + ":" + ((BlockBrick)brickBlock).getName(), "brickBlock"));

    Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(Item.getItemFromBlock(brickBlock),0, new ModelResourceLocation(Testmod01.MODID+":"+ ((BlockBrick)brickBlock).getName(), "inventory"));

   

 

But can you share your custom chest code for me to study?  I'm trying to learn to make a shelf and do not know where to start.  PM, email, or post?

 

UPDATE: ok the code I pasted above totally doesn't work for the chest-like item I'm trying to create because I have extended the BlockContainer class instead of the Block class and I'm trying to figure that out now.

hw developer in a sw world

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

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.