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

Hi!

I'm playing around with entities and models and I'm wondering if it is possibile to use multiple textures (from multiple files) to render each parts of the models

 

Let's say I have a ModelZombie (composed by the head, body, two legs and two arms) and I want to apply texture A1.png to the head, B5.png to the body, C3.png on one leg and so on. The actual texture files are chosen randomly (between A1, A2, A3 etc) when the entity is created

 

I known I can return a different texture in the Render class based on the entity data but that is a single texture file for the whole model

 

Don't know the answer but looking at how the new zombie villagers are rendered i think is not possibile. I mean, if it is why mojang didn't use a base texture and then overlay the cloth?

Don't blame me if i always ask for your help. I just want to learn to be better :)

  • Author

I think that they are just kind of lazy.. the zombie villager texture is the normal zombie one with a new head and cloth added below so they could have used only one texture

 

I may be able to pull this off my overriding RenderLivingEntity::renderModel and make it bind a texture / render the model part for each of the parts of the model (so bind+render the head with one texture, bind+render the body with another texture and so on)

 

I'm not sure how this will go performance wise

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.