use of crazypants.enderio.base.init.ModObject in project EnderIO by SleepyTrousers.
the class BlockPaintedSlabManager method create_double.
private static Block create_double(@Nonnull IModObject modObject, @Nonnull Material material, @Nonnull SoundType sound) {
if (modObject instanceof ModObject) {
final ModObject halfSlabObject = ModObject.values()[((ModObject) modObject).ordinal() - 1];
BlockPaintedSlab.BlockPaintedHalfSlab halfSlabBlock = (BlockPaintedSlab.BlockPaintedHalfSlab) halfSlabObject.getBlockNN();
BlockPaintedSlab.BlockPaintedDoubleSlab doubleSlab = new BlockPaintedSlab.BlockPaintedDoubleSlab(modObject, material, halfSlabBlock, sound);
doubleSlab.setHardness(2.0F).setResistance(5.0F);
doubleSlab.init(modObject);
return doubleSlab;
} else {
throw new RuntimeException("Bad block initialization, " + modObject + " is not a ModObject!");
}
}
Aggregations