Block dimensions and bounding box

General information

The block dimensions and bounding box sets the hitbox for the block if its a custom model. It also can resize a regular block size from something that is cube to other dimensions if no custom model is used.

MCreator allows you to make collision blocks for each mesh by getting the minimum and maximum coordinates for the mesh in the model. The bottom-north-west corner of the mesh is the minimum values, and the top-south-east corner is your maximum values. The values are not based on world coordinates but rather based on the coordinates of the position of the mish in the 16x16x16 block space.

The bottom-north-west corner position is exactly [0, 0, 0] and the and the top-south-east corner position is exactly [16, 16, 16]

Obtaining Mesh Dimensions

As counting how many pixels away from axis point of the block can be tedious, there is another method that is easier that list the exact values you need for the program. All you will need is a program to open the .json model such as Notepad++.

When you have a mesh made in your model you can see two object listed as two and from under the elements section of the script, these are your minimum and maximum positions for that mesh. You may also see other values such as faces, name and rotation as well.

The value called from is the minimum position where the values under to are your maximum position of that mesh.

Code Example

{
  "textures": {
    "particle": "crystal_stone",
    "stone": "crystal_stone",
    "ore": "diamond_crystal_node"
  },
  "elements": [
    {
      "name": "crystal_north",
      "from": [7, 1.77, 6.23],
      "to": [9, 8.77, 8.23],
      "rotation": {"angle": -45, "axis": "x", "origin": [8, 0, 8]},
      "faces": {
        "north": {"uv": [0, 0, 2, 7], "texture": "#ore"},
        "east": {"uv": [2, 0, 0, 7], "texture": "#ore"},
        "south": {"uv": [0, 0, 2, 7], "texture": "#ore"},
        "west": {"uv": [2, 0, 0, 7], "texture": "#ore"},
        "up": {"uv": [4, 2, 6, 0], "texture": "#ore"}
      }
    }
  ]
}

From

The values of from are (7, 1.77, 6.23). The values are laid out the same way in mcreator for your minimum position (X, Y, Z).

To

The values of from are (9, 8.77, 8.23). The values are laid out the same way in mcreator for your maximum position (X, Y, Z).



Donate to MCreator

By donating to developers you can speed up development, as with more resources, we can dedicate more time to MCreator. It is a free project made by developers working on it in their free time.