Jump to content

1.14.4 - Create Two blocks with only a different face texture


Maschiaccio72

Recommended Posts

Hello everyone,

I am ABSOLUTELY NEW to minecraft modding (my first day!) and I understand my question could look stupid but I didn't understand one thing...

Is it possible (I assume it SHOULD BE) to create only ONE BLOCK (one class) and register two different copies of the same class changing only the texture face?

I wand to realize a set of simple building blocks.

In all the basic tutorials I found there is always ONE MODEL and ONE predefined TEXTURE each block class....(using json config files that MUST HAVE same name)

Being a programmer I think it's not possible such approach.... there is something I don't know ?

Can someone explain me how this REALLY works?

Thanks alot!

Link to comment
Share on other sites

Just register two separate instances of the same class and use different registry names. Vanilla does this a lot, check the Blocks class.

Edited by imacatlolol
Edited for clarity

I'm eager to learn and am prone to mistakes. Don't hesitate to tell me how I can improve.

Link to comment
Share on other sites

On 3/18/2020 at 5:19 AM, imacatlolol said:

Just register two separate instances of the same class and use different registry names. Vanilla does this a lot, check the Blocks class.

thank you! Now I understood how registering works and how json is "linked" with class :)

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.