Skip to content

[1.12] Other Mods' Items

Alberto Del Villano edited this page Feb 10, 2022 · 2 revisions

Adding Other mods Items as equipment

You can add any item from any mod to the equipment ... the problem is that some mods use NBT, like TConstruct that uses NBT to know which material is the item made of. In this tutorial I'll show how to use CraftTweaker to get items NBT and as an example mod I'll use Tinker's Contruct.

  • First off get your TConstruct (or whatever other mod) item in your hand. TConstruct item in your hotbar

  • Run the command /ct hand, you'll get something like this: /ct hand

  • You can now click on the NBT to copy it (if it doesn't work properly get into the game log, located in the logs folder in the minecraft folder, and copy that text from there).

  • The content of the string copied is now <modid:item_id>.withTag({all_the_tags_we_need}). Now get the item_id and put it in the id of the item (in this case tconstruct:pickaxe) and the content of the method withTag (in this case {StatsOriginal: etc.}) in the "nbt" tag of the json. Now the most important parts: you may find things like as float or as byte in the nbt, you need to remove those, just delete them. Then remember that you need to escape double quotes (with Notepad++ is simple, just select all the content of the curly brackets and do a replace (Ctrl+H) " -> \". And now you're done!

This should be the final result of the JSON

{
    "mob_id": "minecraft:zombie",
    "equipment": {
        "main_hand": {
            "chance": {
                "amount": 100
            },
            "items": [
                {
                    "id": "tconstruct:pickaxe",
                    "nbt": "{StatsOriginal: {AttackSpeedMultiplier: 1.0, MiningSpeed: 5.0, FreeModifiers: 3, Durability: 240, HarvestLevel: 1, Attack: 2.9}, Stats: {AttackSpeedMultiplier: 1.0, MiningSpeed: 5.0, FreeModifiers: 3, Durability: 240, HarvestLevel: 1, Attack: 4.4}, Special: {Categories: [\"harvest\", \"aoe\", \"tool\"]}, TinkerData: {Materials: [\"wood\", \"flint\", \"bone\"], Modifiers: [\"toolleveling\"]}, Modifiers: [{identifier: \"ecological\", color: -7444965, level: 1}, {identifier: \"crude\", color: -9868951, level: 2, crude2: 1}, {identifier: \"fractured\", color: -1186113, level: 1}, {identifier: \"toolleveling\", color: 16777215, level: 1}], Traits: [\"ecological\", \"crude2\", \"fractured\", \"toolleveling\"]}",
                    "weight": 1
                }
            ]
        }
    }
}

And the Zombies spawning.

Clone this wiki locally