Stacking items!

Through some testing alchemy magic I have found some interesting things.

This is my custom bunk bed. Or, rather, an attempt to do it. The bed consists of 2 parts:

  • Bed module (below)
  • Columns module (above)
    Bed module has a collision height of 1 block in center and rendering scale 0.2 (meaning every voxel has a height of 0.2 in-game block). Center of the bed is 5 voxels high = 1 block high, matching the collision box.
    There is a layer added on top of the bed (seen as a brown “plaque”). It’s part of the bed model. Considering things I’ve written above it’s situated above collision box, in the 2nd block from the ground.
    If I remove this “plaque” the top “columns” module will not be placeable directly on top of the bed any more. But it still can be placed on top of one of the bed poles.

Suspicion: models stack NOT based on collision boxes and NOT based on their geometry. Models stack if the in-game block below the origin of the “top” model contains at least 1 voxel of the “bottom” model. In my case origins of both top and bottom parts are their centers, so that means the bed should have at least 1 voxel directly below the origin of the top part.

Could anyone prove that? Not exactly the most obvious behaviour, but still quite interesting.

PS. Funny thing: I can place top part on the bed but the ghost is shown incorrectly (lower than expected). The model itself, however, is placed as expected.
PPS. Another bed can NOT be placed on top of the “columns” part straight away. It should be placed on the ground, then “moved” on top. Another strange thing, but I’ve heard about it.


Another observation: if you stack items in following order: bunk bed > bunk columns > bunk bed, then order to “pick up” columns, you get the following:

  • Upper bed vanishes (gets destroyed)
  • Columns return to iconic form but can’t be picked until the lower bunk bed is also picked up.

This may be a bug. I wonder if it also present for vanilla items.

Upd: confirmed for vanilla items. Be careful until it is fixed.

PS. You can get mean bunk bed here.

Magic Ladies and Gentlemen Magic !! :grinning:

Anyone know if this has been fixed? Been hunting around and the best I can find is under the mob area of the ghost.json “allow_vertical_adjacent”: true. As stated elsewhere this used to work, crates as the example, but seems to have stopped.

Actually this seems to be known…
Problems by Placing Crates Above Crates