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

In my chert craft mod I have a chert sand block that extends the sand block. I am using the unlimited texture file. I don't have internet on the computer im using, so can't post code. Everything works fine, except that when it falls it changes to the wood texture. There's no extra code, just a block that extends sand then code for the drop when destroyed and code for texture file.

 

How do i make it the chert sand texture when falling? And not the wood.

 

It works fine on the ML version.

Thats like almost exactly my problem, I have searched the code and have found that when the "sand" falls an entity is spawned which is called EntityFallingSand and that entity has a renderer which is called RenderFallingSand. In RenderFallingSand there is a line where it loads the normal terrain.png and it combines that with the (yourblock = new BlockYour(230, 0).setStepSound(Block.soundStoneFootstep).setHardness(3F).setResistance(1.0F).setBlockName("Yourblock");) number of the texture in the spreadsheet (where I assume you use one). The problem is obviously that the renderer uses the wrong .png, I have tried to make some sort of extend of RenderFallingSand where I overwrite the path to the texture but I have had no success because when I make such a Renderer I can't find a way to choose that renderer for my falling entity over the normal RenderFallingSand. I have started modding minecraft and coding java only a few days ago so I can't give you a solution, but at least you know what the problem (problably) is.

 

If you find a solution for this problem please inform me about it, it has been busting my head.

(Also I recommend calling this topic entity texture while falling, for it is an entity and not an item.)

  • 2 weeks later...
  • Author

Thats like almost exactly my problem, I have searched the code and have found that when the "sand" falls an entity is spawned which is called EntityFallingSand and that entity has a renderer which is called RenderFallingSand. In RenderFallingSand there is a line where it loads the normal terrain.png and it combines that with the (yourblock = new BlockYour(230, 0).setStepSound(Block.soundStoneFootstep).setHardness(3F).setResistance(1.0F).setBlockName("Yourblock");) number of the texture in the spreadsheet (where I assume you use one). The problem is obviously that the renderer uses the wrong .png, I have tried to make some sort of extend of RenderFallingSand where I overwrite the path to the texture but I have had no success because when I make such a Renderer I can't find a way to choose that renderer for my falling entity over the normal RenderFallingSand. I have started modding minecraft and coding java only a few days ago so I can't give you a solution, but at least you know what the problem (problably) is.

 

If you find a solution for this problem please inform me about it, it has been busting my head.

(Also I recommend calling this topic entity texture while falling, for it is an entity and not an item.)

 

Thanks for the help. I'll be working on this when I get home from work today.

In order to get your custom render called, you must register it with RenderingRegistry.

 

In your client proxy/client side onLoad code:

 

RenderingRegistry.registerEntityRenderingHandler(render_name_here.class, new EntityToBeRendered());

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.