Skip to content

Instantly share code, notes, and snippets.

@HexBugOrion
Created July 11, 2026 22:52
Show Gist options
  • Select an option

  • Save HexBugOrion/eb732da3df578f9af1cfcba9ad39a781 to your computer and use it in GitHub Desktop.

Select an option

Save HexBugOrion/eb732da3df578f9af1cfcba9ad39a781 to your computer and use it in GitHub Desktop.
package net.tws.nowhere.common.blocks;
import net.minecraft.core.BlockPos;
import net.minecraft.world.item.DyeColor;
import net.minecraft.world.level.block.BedBlock;
import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.level.block.state.properties.BedPart;
public class MeanBedBlock extends BedBlock {
private final DyeColor color;
public MeanBedBlock(DyeColor color, Properties properties) {
super(color, properties);
this.color = color;
this.registerDefaultState(this.stateDefinition.any().setValue(PART, BedPart.FOOT).setValue(OCCUPIED, Boolean.valueOf(false)));
}
@Override
public BlockEntity newBlockEntity(BlockPos pos, BlockState state) {
return super.newBlockEntity(pos, state);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment