About Minecraft Durability Shield Texture

Discussion in 'Spigot Discussion' started by peter9545, Jun 5, 2018.

  1. Can i ask is it possible to have different durability shield texture?

    i have done it with sword, bow and axe, but when i start to work on shield i found that shield.json does not have any texture on it.
     
  2. You sure you did everything correctly? I don't see why this would not work for a shield. Can you share us the JSON files?
     
  3. i have tested several ways by changing the parent and multiple tries but i couldn't get it working

    this is how my wood_sword.json looks like

    Code (Text):
    {
        "parent": "item/handheld",
        "textures": {
            "layer0": "items/wood_sword"
        },
        "overrides": [
            { "predicate": { "damage": 0 }, "model": "item/wooden_sword" },
            { "predicate": { "damaged": 0, "damage": 0.016666666666667 }, "model": "custom/sword/wooden_sword1" },
            { "predicate": { "damaged": 0, "damage": 0.033333333333333 }, "model": "custom/sword/wooden_sword2" },
            { "predicate": { "damaged": 0, "damage": 0.05 }, "model": "custom/sword/wooden_sword3" },
            { "predicate": { "damaged": 0, "damage": 0.066666666666667 }, "model": "custom/sword/wooden_sword4" },
            { "predicate": { "damaged": 1 }, "model": "item/wooden_sword" }
        ]
    }
    and this is how shield.json looks like

    Code (Text):
    {
        "parent": "builtin/entity",
        "display": {
            "thirdperson_righthand": {
                "rotation": [ 0, 90, 0 ],
                "translation": [ 10.51, 6, -4 ],
                "scale": [ 1, 1, 1 ]
            },
            "thirdperson_lefthand": {
                "rotation": [ 0, 90, 0 ],
                "translation": [ 10.51, 6, 12 ],
                "scale": [ 1, 1, 1 ]
            },
            "firstperson_righthand": {
                "rotation": [ 0, 180, 5 ],
                "translation": [ -10, 2, -10 ],
                "scale": [ 1.25, 1.25, 1.25 ]
            },
            "firstperson_lefthand": {
                "rotation": [ 0, 180, 5 ],
                "translation": [ 10, 0, -10 ],
                "scale": [ 1.25, 1.25, 1.25 ]
            },
            "gui": {
                "rotation": [ 15, -25, -5 ],
                "translation": [ 2, 3, 0 ],
                "scale": [ 0.65, 0.65, 0.65 ]
            },
            "fixed": {
                "rotation": [ 0, 180, 0 ],
                "translation": [ -2, 4, -5],
                "scale":[ 0.5, 0.5, 0.5]
            },
            "ground": {
                "rotation": [ 0, 0, 0 ],
                "translation": [ 4, 4, 2],
                "scale":[ 0.25, 0.25, 0.25]
            }
        },
        "overrides": [
            {
                "predicate": {
                    "blocking": 1
                },
                "model": "item/shield_blocking"
            }
        ]
    }
     
    As you can see in the shield.json there is no texture variable so im not sure whether can i change the texture of a shield or not.

    Thanks
     
  4. I think you can change any texture. But changing the texture of a shield might be a bit annoying cause it can be customized in the game. But if you open your minecraft versions jar in like 7zip or winrar or something then go to assets\minecraft\textures\entity\ you will see there are two images called shield_base and shield_base_nopattern and a folder called shield.
     
  5. I see. Actually im trying to create a texture pack that give different texture on sword, axe, bow or even shield. Seems like changing shield texture not as direct as changing sword texture.

    Do you know any guidance that i can follow in order to learn how to change the shield texture?

    Thanks for the reply.
     
  6. I've never done it so don't really know the best way. I made this pack quickly for you. Its basically just a template. I would suggest to test what happens when you replace one of the textures.
     
    • Like Like x 1
  7. Alright ill test it out. Thanks