BlockRegionComponent regionComp = entity.getComponent(BlockRegionComponent.class);
Block bottomBlock = door.bottomBlockFamily.getBlockForPlacement(worldProvider, blockEntityRegistry, regionComp.region.min(), newSide, Side.TOP);
worldProvider.setBlock(regionComp.region.min(), bottomBlock);
Block topBlock = door.topBlockFamily.getBlockForPlacement(worldProvider, blockEntityRegistry, regionComp.region.max(), newSide, Side.TOP);
worldProvider.setBlock(regionComp.region.max(), topBlock);
StaticSound sound = (door.isOpen) ? door.closeSound : door.openSound;
if (sound != null) {
LocationComponent loc = entity.getComponent(LocationComponent.class);
audioManager.playSound(sound, loc.getWorldPosition(), 10, 1);
}