#Creating new armor textures using Armor Material

5 messages · Page 1 of 1 (latest)

slow lintel
#

I was running wild on the repository searching for how the hell i can add/change textures for armors in 1.21.1, and after a few hours testing and researching wikis, support posts and random music playlists, there is the result.
So, for each new full set of armor you will need to register an armor_material, pass it as material to the items and save the .png as the folder paths of texture packs, here's how i did:

For the images, inside the kubejs assets folder, place the textures in these paths:

<exampleid>/textures/item/<material>_chestplate.png
<exampleid>/textures/models/armor/<material>_layer_1.png
<exampleid>/textures/models/armor/<material>_layer_2.png

Note that the layer_1.png and layer_2.png are just the default images that can easily be found google searching the minecraft armor textures. (seriously, it is the official minecraft wiki)

Now, create a startup script with the following:

StartupEvents.registry('armor_material', event => {
    event.create('<exampleid>:<material>');
});
StartupEvents.registry('item', event => {
    event.create('<material>_chestplate', 'chestplate').displayName('Custom Chestplate')
        .texture('<exampleid>:item/<material>_chestplate').material('<exampleid>:<material>');
});

For the helmet, leggings and boots you can just register with the same material, the example has only the chestplate just to keep it simple, remember that values between <> are meant to be replaced just like emerald_chestplate for example, for more modifications that can be set on the armor just like Tier was used before, you can check yourself in the oficial mod repository inside ArmorMaterialBuilder.java file.

No, i didn't know how to modify the model, i was willing to just create default cosmetic armors.
Yes, i just tested in 1.21.1 NeoForge and don't pretend to check any other version or loader.
Yes, question me if you need help to understand why it somehow do not work for you.

scenic hatch
#

(for reference modifying the model is impossible with just kubejs, you may be able to use geckolib but idk)

slow lintel
#

maybe using EntityJS addon, but never worked with it before to be sure

split pivot
#

Has anyone succeeded in doing this with mods that use Azurelib / Geckolib for 3d models and textures?

trail breach
#

I've been wondering the same question as mega