-1

I've been trying for the last few hours and I can't get the right values for the scale, rotation, and translation of the custom item in the json file. I want the size, rotation, and location of the items on the screen to be exactly like their parent item.

{
  "parent": "builtin/generated",
  "textures": {
    "layer0": "item/custom_sword"
  },
  "display": {
    "firstperson_righthand": {
      "scale": [ 0, 0, 0 ],
      "rotation": [ 0, 0, 0 ],
      "translation": [ 0, 0, 0 ]
    },
    "firstperson_lefthand": {
      "scale": [ 0, 0, 0 ],
      "rotation": [ 0, 0, 0 ],
      "translation": [ 0, 0, 0 ]
    },
    "thirdperson_righthand": {
      "scale": [ 0, 0, 0 ],
      "rotation": [ 0, 0, 0 ],
      "translation": [ 0, 0, 0 ]
    },
    "thirdperson_lefthand": {
      "scale": [ 0, 0, 0 ],
      "rotation": [ 0, 0, 0 ],
      "translation": [ 0, 0, 0 ]
    }
  }
}

Here are some pictures of what I mean:

Examples of current and desired effect

I need some help for the right values to put in scale, rotation, and translation.

6
  • 1
    What do you mean by "you know the right values?" Do you want someone to provide the values that allow the items to look a certain way? I believe that depends on how your item models are constructed?
    – 54D
    Aug 27, 2019 at 13:09
  • 1
    I edited it now, hoping you could understand it better. Yes, I want someone to provide the values that allow the items to look exactly like their parent item. I did not use any 3D and complex models for the custom items. It's just recolored texture.
    – Robomike
    Aug 28, 2019 at 12:17
  • You're looking for the vanilla values of the vanilla items, then? Can't you find them by disabling alls mods of your Minecraft installation and checking the appropriate .json file?
    – Joachim
    Aug 28, 2019 at 12:51
  • Somewhere you could probably find the rotation, scale, and translation for the diamond sword. Copying the data from the diamond sword, you could probably find the correct values from the sword.
    – Asadefa
    Aug 29, 2019 at 17:07
  • 2
    Why did someone vote to close this as off-topic?
    – Joachim
    Aug 29, 2019 at 19:06

2 Answers 2

1

As this did not have an answer, I had to figure it out myself through trial and error. The values seem to be:

Edit: after like two hours of trying out different values, refreshing my pack, swapping hands to compare it to an existing sword, and repeating... I realized Blockbench has a "default weapon" preset...

Anyways here you go:

"display": {
        "thirdperson_righthand": {
            "rotation": [0, -90, 55],
            "translation": [0, 4, 0.5],
            "scale": [0.85, 0.85, 0.85]
        },
        "thirdperson_lefthand": {
            "rotation": [0, 90, -55],
            "translation": [0, 4, 0.5],
            "scale": [0.85, 0.85, 0.85]
        },
        "firstperson_righthand": {
            "rotation": [0, -90, 25],
            "translation": [1.13, 3.2, 1.13],
            "scale": [0.68, 0.68, 0.68]
        },
        "firstperson_lefthand": {
            "rotation": [0, 90, -25],
            "translation": [1.13, 3.2, 1.13],
            "scale": [0.68, 0.68, 0.68]
        }
    }
-2

Try using Blockbench (https://blockbench.net/), I use it every time for my models.

1
  • So what are the values then?
    – Aceplante
    Jan 24, 2023 at 2:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .