![JAR search and dependency download from the Maven repository](/logo.png)
cn.nukkit.block.BlockRedSandstone Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of powernukkit Show documentation
Show all versions of powernukkit Show documentation
A Minecraft Bedrock Edition server software implementation made in Java from scratch which supports all new features.
package cn.nukkit.block;
import cn.nukkit.item.Item;
import cn.nukkit.item.ItemBlock;
import cn.nukkit.item.ItemTool;
import cn.nukkit.utils.BlockColor;
/**
* @author CreeperFace
* @since 26. 11. 2016
*/
public class BlockRedSandstone extends BlockSandstone {
public BlockRedSandstone() {
this(0);
}
public BlockRedSandstone(int meta) {
super(meta);
}
@Override
public int getId() {
return RED_SANDSTONE;
}
@Override
public String getName() {
String[] names = new String[]{
"Red Sandstone",
"Chiseled Red Sandstone",
"Smooth Red Sandstone",
""
};
return names[this.getDamage() & 0x03];
}
@Override
public Item toItem() {
return new ItemBlock(this, this.getDamage() & 0x03);
}
@Override
public boolean canHarvestWithHand() {
return false;
}
@Override
public BlockColor getColor() {
return BlockColor.ORANGE_BLOCK_COLOR;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy