Adjust bounding box to block offset

Upvotes: 3
Issue description

This option would move the bounding box of a block to match its offset type. Example code (not tested in 1.14)

public VoxelShape getShape(BlockState state, IBlockReader world, BlockPos pos, ISelectionContext context) {
	Vec3d vec3d = state.getOffset(world, pos);
	return VoxelShapes.create(0.25D, 0D, 0.25D, 0.75D, 0.563D, 0.75D).withOffset(vec3d.x, vec3d.y, vec3d.z);
}

 

Issue comments

Should this even be a togglable option or should bounding box just simply always adapt to the offset?

Should this even be a togglable option or should bounding box just simply always adapt to the offset?

In my opinion, it should be by default because I don't really see why users would have a boudning that isn't adjusted to their block/plant, but you can always add the option (but activated by default).

I try to avoid options that do not make sense (to avoid additional clutter of options), hence I asked ;)

Based on the feedback, this can then be considered a bug. Changing ticket type to reflect this.



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.