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

Back in 1.7 an before, I had made a system that assigned textures to blocks with support for their names and having different textures for different sides of the block (the code would handle displaying the relevant side by using metadata based on rotation), but now that metadata has been abandoned and textures have to be designated in a .json file (WHY MOJANG!?!?!?!!?), this system is completely broken. What was great about my old system was that I only had to provide the textures in the resource path and then give each block an unlocalised name and the rest was processed by the mod. How would I achieve a similar system but using the new (annoying) .json system?

"Thinking that coding is the nerdy IT guy at work rebooting your computer is like thinking that music is what happens when the piano tuner comes round." - Ed Rex

One of the exact reasons why I've been advocating people NOT use 'unlocalized' names for shit.

The idea in 1.8 is to move your definition of blocks into json not code. So just make your jsons as needed.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Back in 1.7 an before, I had made a system that assigned textures to blocks with support for their names and having different textures for different sides of the block (the code would handle displaying the relevant side by using metadata based on rotation), but now that metadata has been abandoned and textures have to be designated in a .json file (WHY MOJANG!?!?!?!!?), this system is completely broken. What was great about my old system was that I only had to provide the textures in the resource path and then give each block an unlocalised name and the rest was processed by the mod. How would I achieve a similar system but using the new (annoying) .json system?

 

Personally I think the json is a much better way than before.  All that hardcoded render block switch statements, what a nightmare....  remove as much coding from block customisation as possible, put it back into the hands of folks creating the resourcepacks I reckon.  All "proper" commercial games are written that way- the coders code, the artists create content.

 

But if you really really want to do your autotexture assignment :), you can use ISmartBlockModel to do exactly the same thing as before.

 

-TGG

 

 

 

 

 

 

 

 

 

I think there are legitimate cases where code-based texture assignment makes more sense than JSON. With JSON you have to create properties to map all possibilities to textures, whereas like the OP said with code you could do something like having a large array of textures with file names that are algorithmically deterministic. Something that might take 10 lines of code could take hundreds, even thousands, lines of JSON.

 

The ISmartBlockModel sounds interesting, gotta have a look at that.

Check out my tutorials here: http://jabelarminecraft.blogspot.com/

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.