Caution and Hazard signs added. Water Freezer added. Ladder/Hatch handling improved. Metal Bar ingredient added, recipes adapted accordingly. Roof Chimney added.
This commit is contained in:
parent
bde1dab5a8
commit
a4cdac34de
146 changed files with 2311 additions and 1275 deletions
|
@ -17,6 +17,7 @@ import wile.engineersdecor.blocks.EdFurnace.FurnaceBlock;
|
|||
import wile.engineersdecor.blocks.EdFurnace.FurnaceContainer;
|
||||
import wile.engineersdecor.blocks.EdFurnace.FurnaceGui;
|
||||
import wile.engineersdecor.blocks.EdFurnace.FurnaceTileEntity;
|
||||
import wile.engineersdecor.items.EdItem;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks.IStandardBlock;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
|
@ -57,6 +58,8 @@ import javax.annotation.Nonnull;
|
|||
@SuppressWarnings("unused")
|
||||
public class ModContent
|
||||
{
|
||||
private static final String MODID = ModEngineersDecor.MODID;
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Blocks
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -64,255 +67,263 @@ public class ModContent
|
|||
public static final DecorBlock.Normal CLINKER_BRICK_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_block"));
|
||||
|
||||
public static final EdSlabBlock CLINKER_BRICK_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_slab"));
|
||||
|
||||
public static final EdStairsBlock CLINKER_BRICK_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
CLINKER_BRICK_BLOCK.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_stairs"));
|
||||
|
||||
public static final EdWallBlock CLINKER_BRICK_WALL = (EdWallBlock)(new EdWallBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_wall"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_wall"));
|
||||
|
||||
public static final DecorBlock.Normal CLINKER_BRICK_STAINED_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_stained_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_stained_block"));
|
||||
|
||||
public static final EdSlabBlock CLINKER_BRICK_STAINED_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_stained_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_stained_slab"));
|
||||
|
||||
public static final EdStairsBlock CLINKER_BRICK_STAINED_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
CLINKER_BRICK_BLOCK.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_stained_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_stained_stairs"));
|
||||
|
||||
public static final EdCornerOrnamentedBlock CLINKER_BRICK_SASTOR_CORNER = (EdCornerOrnamentedBlock)(new EdCornerOrnamentedBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE),
|
||||
new Block[]{CLINKER_BRICK_BLOCK, CLINKER_BRICK_STAINED_BLOCK, CLINKER_BRICK_SLAB, CLINKER_BRICK_STAIRS, CLINKER_BRICK_STAINED_SLAB, CLINKER_BRICK_STAINED_STAIRS}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "clinker_brick_sastor_corner_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "clinker_brick_sastor_corner_block"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final DecorBlock.Normal SLAG_BRICK_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "slag_brick_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "slag_brick_block"));
|
||||
|
||||
public static final EdSlabBlock SLAG_BRICK_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "slag_brick_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "slag_brick_slab"));
|
||||
|
||||
public static final EdStairsBlock SLAG_BRICK_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
SLAG_BRICK_BLOCK.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "slag_brick_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "slag_brick_stairs"));
|
||||
|
||||
public static final EdWallBlock SLAG_BRICK_WALL = (EdWallBlock)(new EdWallBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(3f, 50f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "slag_brick_wall"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "slag_brick_wall"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final DecorBlock.Normal REBAR_CONCRETE_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete"));
|
||||
|
||||
public static final EdSlabBlock REBAR_CONCRETE_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_slab"));
|
||||
|
||||
public static final EdStairsBlock REBAR_CONCRETE_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
REBAR_CONCRETE_BLOCK.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_stairs"));
|
||||
|
||||
public static final EdWallBlock REBAR_CONCRETE_WALL = (EdWallBlock)(new EdWallBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_wall"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_wall"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_REBARCONCRETE = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_rebar_concrete"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_rebar_concrete"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final DecorBlock.Normal GAS_CONCRETE_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(1.5f, 10f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "gas_concrete"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "gas_concrete"));
|
||||
|
||||
public static final EdSlabBlock GAS_CONCRETE_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(1.5f, 10f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "gas_concrete_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "gas_concrete_slab"));
|
||||
|
||||
public static final EdStairsBlock GAS_CONCRETE_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
REBAR_CONCRETE_BLOCK.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(1.5f, 10f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "gas_concrete_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "gas_concrete_stairs"));
|
||||
|
||||
public static final EdWallBlock GAS_CONCRETE_WALL = (EdWallBlock)(new EdWallBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(1.5f, 10f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "gas_concrete_wall"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "gas_concrete_wall"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_GASCONCRETE = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(1.5f, 10f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_gas_concrete"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_gas_concrete"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final DecorBlock.Normal REBAR_CONCRETE_TILE = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_tile"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_tile"));
|
||||
|
||||
public static final EdSlabBlock REBAR_CONCRETE_TILE_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_tile_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_tile_slab"));
|
||||
|
||||
public static final EdStairsBlock REBAR_CONCRETE_TILE_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
REBAR_CONCRETE_TILE.getDefaultState(),
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "rebar_concrete_tile_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "rebar_concrete_tile_stairs"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final EdGlassBlock PANZERGLASS_BLOCK = (EdGlassBlock)(new EdGlassBlock(
|
||||
DecorBlock.CFG_TRANSLUCENT,
|
||||
Block.Properties.create(Material.GLASS, MaterialColor.AIR).hardnessAndResistance(0.7f, 2000f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "panzerglass_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "panzerglass_block"));
|
||||
|
||||
public static final EdSlabBlock PANZERGLASS_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_TRANSLUCENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(0.7f, 2000f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "panzerglass_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "panzerglass_slab"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final EdRoofBlock DARK_CERAMIC_SHINGLE_ROOF = (EdRoofBlock)(new EdRoofBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof"));
|
||||
|
||||
public static final DecorBlock.Normal DARK_CERAMIC_SHINGLE_ROOF_BLOCK = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_block"));
|
||||
|
||||
public static final EdSlabBlock DARK_CERAMIC_SHINGLE_ROOF_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_slab"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_DARK_CERAMIC_SHINGLE_ROOF = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_slabslice"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_slabslice"));
|
||||
|
||||
public static final EdRoofBlock DARK_CERAMIC_SHINGLE_ROOF_METALIZED = (EdRoofBlock)(new EdRoofBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_metallized"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_metallized"));
|
||||
|
||||
public static final EdRoofBlock DARK_CERAMIC_SHINGLE_ROOF_SKYLIGHT = (EdRoofBlock)(new EdRoofBlock(
|
||||
DecorBlock.CFG_TRANSLUCENT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_skylight"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_skylight"));
|
||||
|
||||
public static final EdRoofBlock DARK_CERAMIC_SHINGLE_ROOF_CHIMNEYTRUNK = (EdRoofBlock)(new EdRoofBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dark_shingle_roof_chimneytrunk"));
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(2f, 15f).sound(SoundType.STONE),
|
||||
VoxelShapes.create(Auxiliaries.getPixeledAABB(3, 0, 3, 13, 16, 13)),
|
||||
VoxelShapes.create(Auxiliaries.getPixeledAABB(5, 0, 5, 11, 16, 11))
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_chimneytrunk"));
|
||||
|
||||
public static final EdChimneyBlock DARK_CERAMIC_SHINGLE_ROOF_CHIMNEY = (EdChimneyBlock)(new EdChimneyBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.ROCK, MaterialColor.STONE).hardnessAndResistance(5f, 2000f).sound(SoundType.STONE),
|
||||
Auxiliaries.getPixeledAABB(3, 0, 3, 13, 6, 13)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dark_shingle_roof_chimney"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final EdGroundBlock DENSE_GRIT_SAND = (EdGroundBlock)(new EdGroundBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.EARTH, MaterialColor.DIRT).hardnessAndResistance(0.5f, 3f).sound(SoundType.GROUND).harvestTool(ToolType.SHOVEL)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dense_grit_sand_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dense_grit_sand_block"));
|
||||
|
||||
public static final EdGroundBlock DENSE_GRIT_DIRT = (EdGroundBlock)(new EdGroundBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.EARTH, MaterialColor.DIRT).hardnessAndResistance(0.5f, 3f).sound(SoundType.GROUND).harvestTool(ToolType.SHOVEL)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "dense_grit_dirt_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "dense_grit_dirt_block"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final EdLadderBlock METAL_RUNG_LADDER = (EdLadderBlock)(new EdLadderBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1.0f, 25f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "metal_rung_ladder"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "metal_rung_ladder"));
|
||||
|
||||
public static final EdLadderBlock METAL_RUNG_STEPS = (EdLadderBlock)(new EdLadderBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1.0f, 25f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "metal_rung_steps"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "metal_rung_steps"));
|
||||
|
||||
public static final EdLadderBlock TREATED_WOOD_LADDER = (EdLadderBlock)(new EdLadderBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.0f, 25f).sound(SoundType.WOOD).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_ladder"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_ladder"));
|
||||
|
||||
public static final EdHatchBlock IRON_HATCH = (EdHatchBlock)(new EdHatchBlock(
|
||||
DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 2000f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0.5,1,0, 15.5,3,14),
|
||||
Auxiliaries.getPixeledAABB(0.5,1,0, 15.5,14.,2)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "iron_hatch"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "iron_hatch"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final DecorBlock.Normal OLD_INDUSTRIAL_PLANKS = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.5f, 8f).sound(SoundType.WOOD)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "old_industrial_wood_planks"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "old_industrial_wood_planks"));
|
||||
|
||||
public static final EdSlabBlock OLD_INDUSTRIAL_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.5f, 8f).sound(SoundType.WOOD)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "old_industrial_wood_slab"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "old_industrial_wood_slab"));
|
||||
|
||||
public static final EdStairsBlock OLD_INDUSTRIAL_STAIRS = (EdStairsBlock)(new EdStairsBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
OLD_INDUSTRIAL_PLANKS.getDefaultState(),
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.5f, 8f).sound(SoundType.WOOD)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "old_industrial_wood_stairs"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "old_industrial_wood_stairs"));
|
||||
|
||||
public static final EdSlabSliceBlock OLD_INDUSTRIAL_SLABSLICE = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.5f, 8f).sound(SoundType.WOOD).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "old_industrial_wood_slabslice"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "old_industrial_wood_slabslice"));
|
||||
|
||||
public static final EdDoorBlock OLD_INDUSTRIAL_WOOD_DOOR = (EdDoorBlock)(new EdDoorBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1.5f, 12f).sound(SoundType.WOOD).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "old_industrial_wood_door"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "old_industrial_wood_door"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -320,7 +331,7 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(1,0,1, 15,15.9,15)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_table"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_table"));
|
||||
|
||||
public static final EdChair.ChairBlock TREATED_WOOD_STOOL = (EdChair.ChairBlock)(new EdChair.ChairBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
|
@ -331,7 +342,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(4,0,7, 12,1,9),
|
||||
Auxiliaries.getPixeledAABB(7,0,4, 9,1,12),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_stool"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_stool"));
|
||||
|
||||
public static final DecorBlock.WaterLoggable TREATED_WOOD_SIDE_TABLE = (DecorBlock.WaterLoggable)(new DecorBlock.WaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
|
@ -347,19 +358,19 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB( 2, 0, 7, 14, 1, 9),
|
||||
Auxiliaries.getPixeledAABB( 7, 0, 2, 9, 1,14)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_side_table"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_side_table"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable TREATED_WOOD_WINDOWSILL = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0.5,15,10.5, 15.5,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_windowsill"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_windowsill"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable TREATED_WOOD_BROAD_WINDOWSILL = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_FACING_PLACEMENT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,14.5,4, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_broad_windowsill"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_broad_windowsill"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -367,13 +378,13 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).setLightLevel((state)->15).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5.2,5.2,0, 10.8,10.8,0.3)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "iron_inset_light"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "iron_inset_light"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable FLOOR_EDGE_LIGHT_IRON = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).setLightLevel((state)->15).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5,0,0, 11,2,0.5)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "iron_floor_edge_light"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "iron_floor_edge_light"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable CEILING_EDGE_LIGHT_IRON = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
|
@ -384,7 +395,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB( 0,14.0,0, 1,16,2.0),
|
||||
Auxiliaries.getPixeledAABB(15,14.0,0, 16,16,2.0),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "iron_ceiling_edge_light"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "iron_ceiling_edge_light"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable BULB_LIGHT_IRON = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT|DecorBlock.CFG_AI_PASSABLE,
|
||||
|
@ -393,7 +404,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(6.5,6.5,1, 9.5,9.5,4),
|
||||
Auxiliaries.getPixeledAABB(6.0,6.0,0, 10.0,10.0,1.0)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "iron_bulb_light"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "iron_bulb_light"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -401,13 +412,13 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,0, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_table"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_table"));
|
||||
|
||||
public static final EdFloorGratingBlock STEEL_FLOOR_GRATING = (EdFloorGratingBlock)(new EdFloorGratingBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,14,0, 16,15.5,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_floor_grating"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_floor_grating"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -415,13 +426,13 @@ public class ModContent
|
|||
DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.GLASS).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,7, 16,16,9)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_window"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_window"));
|
||||
|
||||
public static final EdWindowBlock STEEL_FRAMED_WINDOW = (EdWindowBlock)(new EdWindowBlock(
|
||||
DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.GLASS).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,7.5, 16,16,8.5)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_framed_window"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_framed_window"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -429,49 +440,49 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_IF_SAME,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5.8,5.8,0, 10.2,10.2,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_pole"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_pole"));
|
||||
|
||||
public static final EdStraightPoleBlock TREATED_WOOD_POLE_HEAD = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_IF_SAME,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5.8,5.8,0, 10.2,10.2,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_pole_head"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_pole_head"));
|
||||
|
||||
public static final EdStraightPoleBlock TREATED_WOOD_POLE_SUPPORT = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_IF_SAME,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(2f, 15f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5.8,5.8,0, 10.2,10.2,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "treated_wood_pole_support"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "treated_wood_pole_support"));
|
||||
|
||||
public static final EdStraightPoleBlock THIN_STEEL_POLE = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(6,6,0, 10,10,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "thin_steel_pole"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "thin_steel_pole"));
|
||||
|
||||
public static final EdStraightPoleBlock THIN_STEEL_POLE_HEAD = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_IF_SAME,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(6,6,0, 10,10,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "thin_steel_pole_head"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "thin_steel_pole_head"));
|
||||
|
||||
public static final EdStraightPoleBlock THICK_STEEL_POLE = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5,5,0, 11,11,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "thick_steel_pole"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "thick_steel_pole"));
|
||||
|
||||
public static final EdStraightPoleBlock THICK_STEEL_POLE_HEAD = (EdStraightPoleBlock)(new EdStraightPoleBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_IF_SAME,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5,5,0, 11,11,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "thick_steel_pole_head"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "thick_steel_pole_head"));
|
||||
|
||||
public static final EdHorizontalSupportBlock STEEL_DOUBLE_T_SUPPORT = (EdHorizontalSupportBlock)(new EdHorizontalSupportBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(5,11,0, 11,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_double_t_support"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_double_t_support"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -479,37 +490,85 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1000f).sound(SoundType.WOOD).setLightLevel((state)->1).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,15.6, 16,16,16.0)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_decor"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_decor"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_HOTWIRE = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_hotwire"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_hotwire"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_DANGER = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_danger"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_danger"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_DEFENSE = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_defense"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_defense"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_FACTORY_AREA = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_factoryarea"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_factoryarea"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_EXIT = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(3,7,15.6, 13,13,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "sign_exit"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_exit"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_RADIOACTIVE = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_radioactive"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_LASER = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_laser"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_CAUTION = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_caution"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_MAGIC_HAZARD = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_magichazard"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_FIRE_HAZARD = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_firehazard"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_HOT_SURFACE = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_hotsurface"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_MAGNETIC_FIELD = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_magneticfield"));
|
||||
|
||||
public static final DecorBlock.DirectedWaterLoggable SIGN_FROST_WARNING = (DecorBlock.DirectedWaterLoggable)(new DecorBlock.DirectedWaterLoggable(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_AI_PASSABLE,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 1f).sound(SoundType.WOOD).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(2,2,15.6, 14,14,16)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "sign_frost"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -520,7 +579,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(0,15,0, 16,16,16),
|
||||
Auxiliaries.getPixeledAABB(1, 0,1, 15,16,15)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "metal_crafting_table"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "metal_crafting_table"));
|
||||
|
||||
public static final FurnaceBlock SMALL_LAB_FURNACE = (FurnaceBlock)(new FurnaceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -529,7 +588,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(1,0,1, 15, 1,15),
|
||||
Auxiliaries.getPixeledAABB(0,1,1, 16,16,16),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_lab_furnace"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_lab_furnace"));
|
||||
|
||||
public static final EdElectricalFurnace.ElectricalFurnaceBlock SMALL_ELECTRICAL_FURNACE = (EdElectricalFurnace.ElectricalFurnaceBlock)(new EdElectricalFurnace.ElectricalFurnaceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -541,13 +600,13 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(3,13,0, 13,14,16),
|
||||
Auxiliaries.getPixeledAABB(4,14,0, 12,16,16),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_electrical_furnace"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_electrical_furnace"));
|
||||
|
||||
public static final EdDropper.DropperBlock FACTORY_DROPPER = (EdDropper.DropperBlock)(new EdDropper.DropperBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,1, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "factory_dropper"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "factory_dropper"));
|
||||
|
||||
public static final EdPlacer.PlacerBlock FACTORY_PLACER = (EdPlacer.PlacerBlock)(new EdPlacer.PlacerBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_SHIFTCLICK|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -557,7 +616,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB( 0,0,0, 1,16, 2),
|
||||
Auxiliaries.getPixeledAABB(15,0,0,16,16, 2)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "factory_placer"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "factory_placer"));
|
||||
|
||||
public static final EdBreaker.BreakerBlock SMALL_BLOCK_BREAKER = (EdBreaker.BreakerBlock)(new EdBreaker.BreakerBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_SHIFTCLICK,
|
||||
|
@ -570,7 +629,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(15,0,0, 16, 5, 4),
|
||||
Auxiliaries.getPixeledAABB(15,0,4, 16,12,16)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_block_breaker"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_block_breaker"));
|
||||
|
||||
public static final EdHopper.HopperBlock FACTORY_HOPPER = (EdHopper.HopperBlock)(new EdHopper.HopperBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -616,19 +675,25 @@ public class ModContent
|
|||
VoxelShapes.fullCube()
|
||||
));
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "factory_hopper"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "factory_hopper"));
|
||||
|
||||
public static final EdWasteIncinerator.WasteIncineratorBlock SMALL_WASTE_INCINERATOR = (EdWasteIncinerator.WasteIncineratorBlock)(new EdWasteIncinerator.WasteIncineratorBlock(
|
||||
DecorBlock.CFG_DEFAULT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL),
|
||||
Auxiliaries.getPixeledAABB(0,0,0, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_waste_incinerator"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_waste_incinerator"));
|
||||
|
||||
public static final EdMineralSmelter.MineralSmelterBlock SMALL_MINERAL_SMELTER = (EdMineralSmelter.MineralSmelterBlock)(new EdMineralSmelter.MineralSmelterBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(1.1,0,1.1, 14.9,16,14.9)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_mineral_smelter"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_mineral_smelter"));
|
||||
|
||||
public static final EdFreezer.FreezerBlock SMALL_FREEZER = (EdFreezer.FreezerBlock)(new EdFreezer.FreezerBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(1.1,0,1.1, 14.9,16,14.9)
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_freezer"));
|
||||
|
||||
public static final EdSolarPanel.SolarPanelBlock SMALL_SOLAR_PANEL = (EdSolarPanel.SolarPanelBlock)(new EdSolarPanel.SolarPanelBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
|
@ -637,7 +702,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(0,0,0, 16,2,16),
|
||||
Auxiliaries.getPixeledAABB(6,1.5,3, 10,10.5,13),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_solar_panel"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_solar_panel"));
|
||||
|
||||
public static final EdMilker.MilkerBlock SMALL_MILKING_MACHINE = (EdMilker.MilkerBlock)(new EdMilker.MilkerBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT,
|
||||
|
@ -649,7 +714,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB( 0, 1,1, 1,14,11),
|
||||
Auxiliaries.getPixeledAABB(15, 1,1, 16,14,11)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_milking_machine"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_milking_machine"));
|
||||
|
||||
public static final EdTreeCutter.TreeCutterBlock SMALL_TREE_CUTTER = (EdTreeCutter.TreeCutterBlock)(new EdTreeCutter.TreeCutterBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_SHIFTCLICK,
|
||||
|
@ -662,7 +727,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB( 0,0,13, 16,8,16),
|
||||
Auxiliaries.getPixeledAABB( 5,6,12, 16,8,13),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_tree_cutter"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_tree_cutter"));
|
||||
|
||||
public static final EdPipeValve.PipeValveBlock STRAIGHT_CHECK_VALVE = (EdPipeValve.PipeValveBlock)(new EdPipeValve.PipeValveBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_SHIFTCLICK,
|
||||
|
@ -674,7 +739,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(3,3, 5, 13,13,11),
|
||||
Auxiliaries.getPixeledAABB(4,4, 2, 12,12,14),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "straight_pipe_valve"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "straight_pipe_valve"));
|
||||
|
||||
public static final EdPipeValve.PipeValveBlock STRAIGHT_REDSTONE_VALVE = (EdPipeValve.PipeValveBlock)(new EdPipeValve.PipeValveBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -686,7 +751,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(3,3, 5, 13,13,11),
|
||||
Auxiliaries.getPixeledAABB(4,4, 2, 12,12,14),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "straight_pipe_valve_redstone"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "straight_pipe_valve_redstone"));
|
||||
|
||||
public static final EdPipeValve.PipeValveBlock STRAIGHT_REDSTONE_ANALOG_VALVE = (EdPipeValve.PipeValveBlock)(new EdPipeValve.PipeValveBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_FACING_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -698,13 +763,13 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(3,3, 5, 13,13,11),
|
||||
Auxiliaries.getPixeledAABB(4,4, 2, 12,12,14),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "straight_pipe_valve_redstone_analog"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "straight_pipe_valve_redstone_analog"));
|
||||
|
||||
@Deprecated // remove in 1.17/1.16.3, not needed by anyone
|
||||
public static final DecorBlock.Normal PASSIVE_FLUID_ACCUMULATOR = (DecorBlock.Normal)(new DecorBlock.Normal(
|
||||
DecorBlock.CFG_EXPERIMENTAL,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "passive_fluid_accumulator"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "passive_fluid_accumulator"));
|
||||
|
||||
public static final EdFluidBarrel.FluidBarrelBlock FLUID_BARREL = (EdFluidBarrel.FluidBarrelBlock)(new EdFluidBarrel.FluidBarrelBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
|
@ -716,7 +781,7 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(1,14,0, 15,15,16),
|
||||
Auxiliaries.getPixeledAABB(2,15,0, 14,16,16),
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "fluid_barrel"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "fluid_barrel"));
|
||||
|
||||
public static final EdFluidFunnel.FluidFunnelBlock SMALL_FLUID_FUNNEL = (EdFluidFunnel.FluidFunnelBlock)(new EdFluidFunnel.FluidFunnelBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
|
@ -726,45 +791,45 @@ public class ModContent
|
|||
Auxiliaries.getPixeledAABB(1,14,1, 15,15,15),
|
||||
Auxiliaries.getPixeledAABB(0,15,0, 16,16,16)
|
||||
}
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "small_fluid_funnel"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "small_fluid_funnel"));
|
||||
|
||||
public static final EdLabeledCrate.LabeledCrateBlock LABELED_CRATE = (EdLabeledCrate.LabeledCrateBlock)(new EdLabeledCrate.LabeledCrateBlock(
|
||||
DecorBlock.CFG_HORIZIONTAL|DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_OPPOSITE_PLACEMENT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(0.5f, 128f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,0, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "labeled_crate"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "labeled_crate"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_TREATEDWOOD = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.WOOD, MaterialColor.WOOD).hardnessAndResistance(1f, 4f).sound(SoundType.WOOD).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_treated_wood"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_treated_wood"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_SHEETMETALIRON = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1f, 10f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_sheetmetal_iron"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_sheetmetal_iron"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_SHEETMETALSTEEL = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1f, 10f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_sheetmetal_steel"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_sheetmetal_steel"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_SHEETMETALCOPPER = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1f, 10f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_sheetmetal_copper"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_sheetmetal_copper"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_SHEETMETALGOLD = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1f, 10f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_sheetmetal_gold"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_sheetmetal_gold"));
|
||||
|
||||
public static final EdSlabSliceBlock HALFSLAB_SHEETMETALALUMINIUM = (EdSlabSliceBlock)(new EdSlabSliceBlock(
|
||||
DecorBlock.CFG_CUTOUT|DecorBlock.CFG_HARD_IE_DEPENDENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(1f, 10f).sound(SoundType.METAL).notSolid()
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "halfslab_sheetmetal_aluminum"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "halfslab_sheetmetal_aluminum"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -772,13 +837,13 @@ public class ModContent
|
|||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
1.5, 16, 0.25, 0, 16, 16
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_mesh_fence"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_mesh_fence"));
|
||||
|
||||
public static final EdDoubleGateBlock STEEL_MESH_FENCE_GATE = (EdDoubleGateBlock)(new EdDoubleGateBlock(
|
||||
DecorBlock.CFG_CUTOUT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(2f, 15f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,6.5, 16,16,9.5)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "steel_mesh_fence_gate"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "steel_mesh_fence_gate"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -786,7 +851,7 @@ public class ModContent
|
|||
DecorBlock.CFG_LOOK_PLACEMENT|DecorBlock.CFG_FLIP_PLACEMENT_SHIFTCLICK,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(0f, 32000f).sound(SoundType.METAL).notSolid(),
|
||||
Auxiliaries.getPixeledAABB(0,0,0, 16,16,16)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "test_block"));
|
||||
)).setRegistryName(new ResourceLocation(MODID, "test_block"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
@ -803,6 +868,7 @@ public class ModContent
|
|||
SMALL_SOLAR_PANEL,
|
||||
SMALL_WASTE_INCINERATOR,
|
||||
SMALL_MINERAL_SMELTER,
|
||||
SMALL_FREEZER,
|
||||
SMALL_MILKING_MACHINE,
|
||||
FLUID_BARREL,
|
||||
STRAIGHT_CHECK_VALVE,
|
||||
|
@ -852,6 +918,7 @@ public class ModContent
|
|||
DARK_CERAMIC_SHINGLE_ROOF_BLOCK,
|
||||
DARK_CERAMIC_SHINGLE_ROOF_SLAB,
|
||||
HALFSLAB_DARK_CERAMIC_SHINGLE_ROOF,
|
||||
DARK_CERAMIC_SHINGLE_ROOF_CHIMNEY,
|
||||
METAL_RUNG_LADDER,
|
||||
METAL_RUNG_STEPS,
|
||||
TREATED_WOOD_LADDER,
|
||||
|
@ -889,6 +956,14 @@ public class ModContent
|
|||
SIGN_DEFENSE,
|
||||
SIGN_FACTORY_AREA,
|
||||
SIGN_EXIT,
|
||||
SIGN_RADIOACTIVE,
|
||||
SIGN_LASER,
|
||||
SIGN_CAUTION,
|
||||
SIGN_MAGIC_HAZARD,
|
||||
SIGN_FIRE_HAZARD,
|
||||
SIGN_HOT_SURFACE,
|
||||
SIGN_MAGNETIC_FIELD,
|
||||
SIGN_FROST_WARNING,
|
||||
SIGN_MODLOGO,
|
||||
};
|
||||
|
||||
|
@ -903,87 +978,92 @@ public class ModContent
|
|||
public static final TileEntityType<?> TET_CRAFTING_TABLE = TileEntityType.Builder
|
||||
.create(EdCraftingTable.CraftingTableTileEntity::new, CRAFTING_TABLE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_treated_wood_crafting_table");
|
||||
.setRegistryName(MODID, "te_treated_wood_crafting_table");
|
||||
|
||||
public static final TileEntityType<?> TET_LABELED_CRATE = TileEntityType.Builder
|
||||
.create(EdLabeledCrate.LabeledCrateTileEntity::new, LABELED_CRATE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_labeled_crate");
|
||||
.setRegistryName(MODID, "te_labeled_crate");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_LAB_FURNACE = TileEntityType.Builder
|
||||
.create(FurnaceTileEntity::new, SMALL_LAB_FURNACE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_lab_furnace");
|
||||
.setRegistryName(MODID, "te_small_lab_furnace");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_ELECTRICAL_FURNACE = TileEntityType.Builder
|
||||
.create(EdElectricalFurnace.ElectricalFurnaceTileEntity::new, SMALL_ELECTRICAL_FURNACE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_electrical_furnace");
|
||||
.setRegistryName(MODID, "te_small_electrical_furnace");
|
||||
|
||||
public static final TileEntityType<?> TET_FACTORY_DROPPER = TileEntityType.Builder
|
||||
.create(EdDropper.DropperTileEntity::new, FACTORY_DROPPER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_factory_dropper");
|
||||
.setRegistryName(MODID, "te_factory_dropper");
|
||||
|
||||
public static final TileEntityType<?> TET_FACTORY_PLACER = TileEntityType.Builder
|
||||
.create(EdPlacer.PlacerTileEntity::new, FACTORY_PLACER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_factory_placer");
|
||||
.setRegistryName(MODID, "te_factory_placer");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_BLOCK_BREAKER = TileEntityType.Builder
|
||||
.create(EdBreaker.BreakerTileEntity::new, SMALL_BLOCK_BREAKER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_block_breaker");
|
||||
.setRegistryName(MODID, "te_small_block_breaker");
|
||||
|
||||
public static final TileEntityType<?> TET_FACTORY_HOPPER = TileEntityType.Builder
|
||||
.create(EdHopper.HopperTileEntity::new, FACTORY_HOPPER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_factory_hopper");
|
||||
.setRegistryName(MODID, "te_factory_hopper");
|
||||
|
||||
public static final TileEntityType<?> TET_WASTE_INCINERATOR = TileEntityType.Builder
|
||||
.create(EdWasteIncinerator.WasteIncineratorTileEntity::new, SMALL_WASTE_INCINERATOR)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_waste_incinerator");
|
||||
.setRegistryName(MODID, "te_small_waste_incinerator");
|
||||
|
||||
public static final TileEntityType<?> TET_STRAIGHT_PIPE_VALVE = TileEntityType.Builder
|
||||
.create(EdPipeValve.PipeValveTileEntity::new, STRAIGHT_CHECK_VALVE, STRAIGHT_REDSTONE_VALVE, STRAIGHT_REDSTONE_ANALOG_VALVE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_pipe_valve");
|
||||
.setRegistryName(MODID, "te_pipe_valve");
|
||||
|
||||
public static final TileEntityType<?> TET_FLUID_BARREL = TileEntityType.Builder
|
||||
.create(EdFluidBarrel.FluidBarrelTileEntity::new, FLUID_BARREL)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_fluid_barrel");
|
||||
.setRegistryName(MODID, "te_fluid_barrel");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_FLUID_FUNNEL = TileEntityType.Builder
|
||||
.create(EdFluidFunnel.FluidFunnelTileEntity::new, SMALL_FLUID_FUNNEL)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_fluid_funnel");
|
||||
.setRegistryName(MODID, "te_small_fluid_funnel");
|
||||
|
||||
public static final TileEntityType<?> TET_MINERAL_SMELTER = TileEntityType.Builder
|
||||
.create(EdMineralSmelter.MineralSmelterTileEntity::new, SMALL_MINERAL_SMELTER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_mineral_smelter");
|
||||
.setRegistryName(MODID, "te_small_mineral_smelter");
|
||||
|
||||
public static final TileEntityType<?> TET_FREEZER = TileEntityType.Builder
|
||||
.create(EdFreezer.FreezerTileEntity::new, SMALL_FREEZER)
|
||||
.build(null)
|
||||
.setRegistryName(MODID, "te_small_freezer");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_SOLAR_PANEL = TileEntityType.Builder
|
||||
.create(EdSolarPanel.SolarPanelTileEntity::new, SMALL_SOLAR_PANEL)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_solar_panel");
|
||||
.setRegistryName(MODID, "te_small_solar_panel");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_MILKING_MACHINE = TileEntityType.Builder
|
||||
.create(EdMilker.MilkerTileEntity::new, SMALL_MILKING_MACHINE)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_milking_machine");
|
||||
.setRegistryName(MODID, "te_small_milking_machine");
|
||||
|
||||
public static final TileEntityType<?> TET_SMALL_TREE_CUTTER = TileEntityType.Builder
|
||||
.create(EdTreeCutter.TreeCutterTileEntity::new, SMALL_TREE_CUTTER)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_small_tree_cutter");
|
||||
.setRegistryName(MODID, "te_small_tree_cutter");
|
||||
|
||||
public static final TileEntityType<?> TET_TEST_BLOCK = TileEntityType.Builder
|
||||
.create(EdTestBlock.TestTileEntity::new, TEST_BLOCK)
|
||||
.build(null)
|
||||
.setRegistryName(ModEngineersDecor.MODID, "te_test_block");
|
||||
.setRegistryName(MODID, "te_test_block");
|
||||
|
||||
private static final TileEntityType<?> tile_entity_types[] = {
|
||||
TET_CRAFTING_TABLE,
|
||||
|
@ -997,6 +1077,7 @@ public class ModContent
|
|||
TET_SMALL_TREE_CUTTER,
|
||||
TET_WASTE_INCINERATOR,
|
||||
TET_MINERAL_SMELTER,
|
||||
TET_FREEZER,
|
||||
TET_SMALL_SOLAR_PANEL,
|
||||
TET_SMALL_MILKING_MACHINE,
|
||||
TET_STRAIGHT_PIPE_VALVE,
|
||||
|
@ -1005,6 +1086,19 @@ public class ModContent
|
|||
TET_TEST_BLOCK
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Items
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
private static Item.Properties default_item_properties()
|
||||
{ return (new Item.Properties()).group(ModEngineersDecor.ITEMGROUP); }
|
||||
|
||||
public static final EdItem METAL_BAR_ITEM = (EdItem)((new EdItem(default_item_properties()).setRegistryName(MODID, "metal_bar")));
|
||||
|
||||
private static final EdItem modItems[] = {
|
||||
METAL_BAR_ITEM
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Entities bound exclusively to the blocks above
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -1016,8 +1110,8 @@ public class ModContent
|
|||
.immuneToFire().size(1e-3f, 1e-3f).disableSerialization()
|
||||
.setShouldReceiveVelocityUpdates(false).setUpdateInterval(4)
|
||||
.setCustomClientFactory(EdChair.EntityChair::customClientFactory)
|
||||
.build(new ResourceLocation(ModEngineersDecor.MODID, "et_chair").toString())
|
||||
.setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "et_chair"))
|
||||
.build(new ResourceLocation(MODID, "et_chair").toString())
|
||||
.setRegistryName(new ResourceLocation(MODID, "et_chair"))
|
||||
);
|
||||
|
||||
private static final EntityType<?> entity_types[] = {
|
||||
|
@ -1039,21 +1133,21 @@ public class ModContent
|
|||
|
||||
static {
|
||||
CT_TREATED_WOOD_CRAFTING_TABLE = (new ContainerType<EdCraftingTable.CraftingTableContainer>(EdCraftingTable.CraftingTableContainer::new));
|
||||
CT_TREATED_WOOD_CRAFTING_TABLE.setRegistryName(ModEngineersDecor.MODID,"ct_treated_wood_crafting_table");
|
||||
CT_TREATED_WOOD_CRAFTING_TABLE.setRegistryName(MODID,"ct_treated_wood_crafting_table");
|
||||
CT_FACTORY_DROPPER = (new ContainerType<EdDropper.DropperContainer>(EdDropper.DropperContainer::new));
|
||||
CT_FACTORY_DROPPER.setRegistryName(ModEngineersDecor.MODID,"ct_factory_dropper");
|
||||
CT_FACTORY_DROPPER.setRegistryName(MODID,"ct_factory_dropper");
|
||||
CT_FACTORY_PLACER = (new ContainerType<EdPlacer.PlacerContainer>(EdPlacer.PlacerContainer::new));
|
||||
CT_FACTORY_PLACER.setRegistryName(ModEngineersDecor.MODID,"ct_factory_placer");
|
||||
CT_FACTORY_PLACER.setRegistryName(MODID,"ct_factory_placer");
|
||||
CT_FACTORY_HOPPER = (new ContainerType<EdHopper.HopperContainer>(EdHopper.HopperContainer::new));
|
||||
CT_FACTORY_HOPPER.setRegistryName(ModEngineersDecor.MODID,"ct_factory_hopper");
|
||||
CT_FACTORY_HOPPER.setRegistryName(MODID,"ct_factory_hopper");
|
||||
CT_SMALL_LAB_FURNACE = (new ContainerType<FurnaceContainer>(FurnaceContainer::new));
|
||||
CT_SMALL_LAB_FURNACE.setRegistryName(ModEngineersDecor.MODID,"ct_small_lab_furnace");
|
||||
CT_SMALL_LAB_FURNACE.setRegistryName(MODID,"ct_small_lab_furnace");
|
||||
CT_SMALL_ELECTRICAL_FURNACE = (new ContainerType<EdElectricalFurnace.ElectricalFurnaceContainer>(EdElectricalFurnace.ElectricalFurnaceContainer::new));
|
||||
CT_SMALL_ELECTRICAL_FURNACE.setRegistryName(ModEngineersDecor.MODID,"ct_small_electrical_furnace");
|
||||
CT_SMALL_ELECTRICAL_FURNACE.setRegistryName(MODID,"ct_small_electrical_furnace");
|
||||
CT_WASTE_INCINERATOR = (new ContainerType<EdWasteIncinerator.WasteIncineratorContainer>(EdWasteIncinerator.WasteIncineratorContainer::new));
|
||||
CT_WASTE_INCINERATOR.setRegistryName(ModEngineersDecor.MODID,"ct_small_waste_incinerator");
|
||||
CT_WASTE_INCINERATOR.setRegistryName(MODID,"ct_small_waste_incinerator");
|
||||
CT_LABELED_CRATE = (new ContainerType<EdLabeledCrate.LabeledCrateContainer>(EdLabeledCrate.LabeledCrateContainer::new));
|
||||
CT_LABELED_CRATE.setRegistryName(ModEngineersDecor.MODID,"ct_labeled_crate");
|
||||
CT_LABELED_CRATE.setRegistryName(MODID,"ct_labeled_crate");
|
||||
}
|
||||
|
||||
// DON'T FORGET TO REGISTER THE GUI in registerContainerGuis(), no list/map format found yet for that.
|
||||
|
@ -1127,6 +1221,9 @@ public class ModContent
|
|||
}
|
||||
}
|
||||
|
||||
public static final void registerItems(final RegistryEvent.Register<Item> event)
|
||||
{ for(Item e:modItems) event.getRegistry().register(e); }
|
||||
|
||||
public static final void registerTileEntities(final RegistryEvent.Register<TileEntityType<?>> event)
|
||||
{
|
||||
int n_registered = 0;
|
||||
|
|
|
@ -103,7 +103,7 @@ public class ModEngineersDecor
|
|||
|
||||
@SubscribeEvent
|
||||
public static void onItemRegistry(final RegistryEvent.Register<Item> event)
|
||||
{ ModContent.registerBlockItems(event); }
|
||||
{ ModContent.registerItems(event); ModContent.registerBlockItems(event); }
|
||||
|
||||
@SubscribeEvent
|
||||
public static void onTileEntityRegistry(final RegistryEvent.Register<TileEntityType<?>> event)
|
||||
|
|
92
src/main/java/wile/engineersdecor/blocks/EdChimneyBlock.java
Normal file
92
src/main/java/wile/engineersdecor/blocks/EdChimneyBlock.java
Normal file
|
@ -0,0 +1,92 @@
|
|||
/*
|
||||
* @file EdChimneyBlock.java
|
||||
* @author Stefan Wilhelm (wile)
|
||||
* @copyright (C) 2019 Stefan Wilhelm
|
||||
* @license MIT (see https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Block type for smoking chimneys.
|
||||
*/
|
||||
package wile.engineersdecor.blocks;
|
||||
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.BlockItemUseContext;
|
||||
import net.minecraft.particles.ParticleTypes;
|
||||
import net.minecraft.state.IntegerProperty;
|
||||
import net.minecraft.state.StateContainer;
|
||||
import net.minecraft.state.properties.BlockStateProperties;
|
||||
import net.minecraft.util.ActionResultType;
|
||||
import net.minecraft.util.Hand;
|
||||
import net.minecraft.util.SoundCategory;
|
||||
import net.minecraft.util.SoundEvents;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.BlockRayTraceResult;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.Random;
|
||||
|
||||
public class EdChimneyBlock extends DecorBlock.Normal implements IDecorBlock
|
||||
{
|
||||
public static final IntegerProperty POWER = BlockStateProperties.POWER_0_15;
|
||||
|
||||
public EdChimneyBlock(long config, Block.Properties properties, AxisAlignedBB aabb)
|
||||
{ super(config, properties, aabb); }
|
||||
|
||||
public EdChimneyBlock(long config, Block.Properties builder)
|
||||
{
|
||||
this(config, builder, new AxisAlignedBB(0,0,0,1,1,1));
|
||||
setDefaultState(super.getDefaultState().with(POWER, 0)); // no smoke in JEI
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void fillStateContainer(StateContainer.Builder<Block, BlockState> builder)
|
||||
{ super.fillStateContainer(builder); builder.add(POWER); }
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public BlockState getStateForPlacement(BlockItemUseContext context)
|
||||
{
|
||||
int p = context.getWorld().getRedstonePowerFromNeighbors(context.getPos());
|
||||
return super.getStateForPlacement(context).with(POWER, p==0 ? 5 : p);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public ActionResultType onBlockActivated(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockRayTraceResult rayTraceResult)
|
||||
{ world.setBlockState(pos, state.with(POWER, (state.get(POWER)+1) & 0xf), 1|2); return ActionResultType.SUCCESS; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public void neighborChanged(BlockState state, World world, BlockPos pos, Block block, BlockPos fromPos, boolean unused)
|
||||
{
|
||||
int p = world.getRedstonePowerFromNeighbors(pos);
|
||||
if(p != state.get(POWER)) world.setBlockState(pos, state.with(POWER, p), 2);
|
||||
}
|
||||
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public void animateTick(BlockState state, World world, BlockPos pos, Random rnd)
|
||||
{
|
||||
if(state.getBlock() != this) return;
|
||||
final int p = state.get(POWER);
|
||||
if(p==0) return;
|
||||
int end = 1+rnd.nextInt(10) * p / 15;
|
||||
for(int i=0; i<end; ++i) {
|
||||
double rv = rnd.nextDouble() * p / 5;
|
||||
world.addParticle(
|
||||
(rv > 0.7 ? ParticleTypes.LARGE_SMOKE : (rv>0.4 ? ParticleTypes.SMOKE : ParticleTypes.CAMPFIRE_COSY_SMOKE)),
|
||||
0.5+pos.getX()+(rnd.nextDouble()*0.2),
|
||||
0.9+pos.getY()+(rnd.nextDouble()*0.1),
|
||||
0.5+pos.getZ()+(rnd.nextDouble()*0.2),
|
||||
-0.02 + rnd.nextDouble()*0.04,
|
||||
+0.05 + rnd.nextDouble()*0.1,
|
||||
-0.02 + rnd.nextDouble()*0.04
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
385
src/main/java/wile/engineersdecor/blocks/EdFreezer.java
Normal file
385
src/main/java/wile/engineersdecor/blocks/EdFreezer.java
Normal file
|
@ -0,0 +1,385 @@
|
|||
/*
|
||||
* @file EdFreezer.java
|
||||
* @author Stefan Wilhelm (wile)
|
||||
* @copyright (C) 2019 Stefan Wilhelm
|
||||
* @license MIT (see https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Small highly insulated stone liquification furnace
|
||||
* (magmatic phase).
|
||||
*/
|
||||
package wile.engineersdecor.blocks;
|
||||
|
||||
import net.minecraftforge.common.util.Constants;
|
||||
import wile.engineersdecor.ModContent;
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.tileentity.ITickableTileEntity;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
import net.minecraft.item.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.BlockItemUseContext;
|
||||
import net.minecraft.nbt.CompoundNBT;
|
||||
import net.minecraft.entity.LivingEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.util.*;
|
||||
import net.minecraft.util.math.*;
|
||||
import net.minecraft.state.IntegerProperty;
|
||||
import net.minecraft.state.StateContainer;
|
||||
import net.minecraft.fluid.Fluids;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.common.util.LazyOptional;
|
||||
import net.minecraftforge.energy.CapabilityEnergy;
|
||||
import net.minecraftforge.energy.IEnergyStorage;
|
||||
import net.minecraftforge.fluids.capability.CapabilityFluidHandler;
|
||||
import net.minecraftforge.fluids.capability.IFluidHandler;
|
||||
import net.minecraftforge.items.CapabilityItemHandler;
|
||||
import net.minecraftforge.items.IItemHandler;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import wile.engineersdecor.libmc.detail.Fluidics;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.*;
|
||||
|
||||
public class EdFreezer
|
||||
{
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Block
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static class FreezerBlock extends DecorBlock.Horizontal implements IDecorBlock
|
||||
{
|
||||
public static final int PHASE_MAX = 4;
|
||||
public static final IntegerProperty PHASE = IntegerProperty.create("phase", 0, PHASE_MAX);
|
||||
|
||||
public FreezerBlock(long config, Block.Properties builder, final AxisAlignedBB unrotatedAABB)
|
||||
{ super(config, builder, unrotatedAABB); }
|
||||
|
||||
@Override
|
||||
protected void fillStateContainer(StateContainer.Builder<Block, BlockState> builder)
|
||||
{ super.fillStateContainer(builder); builder.add(PHASE); }
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public BlockState getStateForPlacement(BlockItemUseContext context)
|
||||
{ return super.getStateForPlacement(context).with(PHASE, 0); }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public boolean hasComparatorInputOverride(BlockState state)
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public int getComparatorInputOverride(BlockState state, World world, BlockPos pos)
|
||||
{ return MathHelper.clamp((state.get(PHASE)*4), 0, 15); }
|
||||
|
||||
@Override
|
||||
public boolean hasTileEntity(BlockState state)
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public TileEntity createTileEntity(BlockState state, IBlockReader world)
|
||||
{ return new EdFreezer.FreezerTileEntity(); }
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack stack)
|
||||
{}
|
||||
|
||||
@Override
|
||||
public boolean hasDynamicDropList()
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
public List<ItemStack> dropList(BlockState state, World world, TileEntity te, boolean explosion)
|
||||
{
|
||||
final List<ItemStack> stacks = new ArrayList<ItemStack>();
|
||||
if(world.isRemote) return stacks;
|
||||
if(!(te instanceof FreezerTileEntity)) return stacks;
|
||||
((FreezerTileEntity)te).reset_process();
|
||||
stacks.add(new ItemStack(this, 1));
|
||||
return stacks;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ActionResultType onBlockActivated(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockRayTraceResult rayTraceResult)
|
||||
{
|
||||
if(player.isSneaking()) return ActionResultType.PASS;
|
||||
if(world.isRemote) return ActionResultType.SUCCESS;
|
||||
FreezerTileEntity te = getTe(world, pos);
|
||||
if(te==null) return ActionResultType.FAIL;
|
||||
final ItemStack stack = player.getHeldItem(hand);
|
||||
boolean dirty = false;
|
||||
if(Fluidics.manualFluidHandlerInteraction(world, pos, null, player, hand)) {
|
||||
world.playSound(null, pos, SoundEvents.ITEM_BUCKET_EMPTY, SoundCategory.BLOCKS, 0.5f, 1.4f);
|
||||
return ActionResultType.SUCCESS;
|
||||
}
|
||||
if(stack.getItem()==Items.WATER_BUCKET) {
|
||||
return ActionResultType.SUCCESS; // would be already handled
|
||||
} else if(stack.isEmpty()) {
|
||||
ItemStack ice = te.getIceItem(true);
|
||||
if(!ice.isEmpty()) {
|
||||
player.addItemStackToInventory(ice);
|
||||
world.playSound(null, pos, SoundEvents.ENTITY_ITEM_PICKUP, SoundCategory.BLOCKS, 0.3f, 1.1f);
|
||||
} else {
|
||||
world.playSound(null, pos, SoundEvents.BLOCK_IRON_TRAPDOOR_OPEN, SoundCategory.BLOCKS, 0.2f, 0.02f);
|
||||
}
|
||||
return ActionResultType.SUCCESS;
|
||||
} else {
|
||||
return ActionResultType.PASS;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public void animateTick(BlockState state, World world, BlockPos pos, Random rnd)
|
||||
{}
|
||||
|
||||
@Nullable
|
||||
private FreezerTileEntity getTe(World world, BlockPos pos)
|
||||
{ final TileEntity te=world.getTileEntity(pos); return (!(te instanceof FreezerTileEntity)) ? (null) : ((FreezerTileEntity)te); }
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Tile entity
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static class FreezerTileEntity extends TileEntity implements ITickableTileEntity, IEnergyStorage, ICapabilityProvider
|
||||
{
|
||||
public static final int TICK_INTERVAL = 20;
|
||||
public static final int MAX_FLUID_LEVEL = 2000;
|
||||
public static final int MAX_ENERGY_BUFFER = 32000;
|
||||
public static final int MAX_ENERGY_TRANSFER = 8192;
|
||||
public static final int DEFAULT_ENERGY_CONSUMPTION = 92;
|
||||
public static final int DEFAULT_COOLDOWN_RATE = 2;
|
||||
public static final int PHASE_EMPTY = 0;
|
||||
public static final int PHASE_WATER = 1;
|
||||
public static final int PHASE_ICE = 2;
|
||||
public static final int PHASE_PACKEDICE = 3;
|
||||
public static final int PHASE_BLUEICE = 4;
|
||||
|
||||
private static int energy_consumption = DEFAULT_ENERGY_CONSUMPTION;
|
||||
private static int cooldown_rate = DEFAULT_COOLDOWN_RATE;
|
||||
private static int reheat_rate = 1;
|
||||
private final Fluidics.Tank tank_ = new Fluidics.Tank(2000, fs->fs.getFluid()==Fluids.WATER);
|
||||
private int tick_timer_;
|
||||
private int energy_stored_;
|
||||
private int progress_;
|
||||
private boolean force_block_update_;
|
||||
|
||||
public static void on_config(int consumption, int cooldown_per_second)
|
||||
{
|
||||
energy_consumption = MathHelper.clamp(consumption, 8, 4096);
|
||||
cooldown_rate = MathHelper.clamp(cooldown_per_second, 1, 5);
|
||||
reheat_rate = MathHelper.clamp(cooldown_per_second/2, 1, 5);
|
||||
ModEngineersDecor.logger().info("Config freezer energy consumption:" + energy_consumption + "rf/t, cooldown-rate: " + cooldown_rate + "%/s.");
|
||||
}
|
||||
|
||||
public FreezerTileEntity()
|
||||
{ this(ModContent.TET_FREEZER); }
|
||||
|
||||
public FreezerTileEntity(TileEntityType<?> te_type)
|
||||
{ super(te_type); }
|
||||
|
||||
public int progress()
|
||||
{ return progress_; }
|
||||
|
||||
public int phase()
|
||||
{
|
||||
if(tank_.getFluidAmount() < 1000) return PHASE_EMPTY;
|
||||
if(progress_ >= 100) return PHASE_BLUEICE;
|
||||
if(progress_ >= 70) return PHASE_PACKEDICE;
|
||||
if(progress_ >= 30) return PHASE_ICE;
|
||||
return PHASE_WATER;
|
||||
}
|
||||
|
||||
public ItemStack getIceItem(boolean extract)
|
||||
{
|
||||
ItemStack stack;
|
||||
switch(phase()) {
|
||||
case PHASE_ICE: stack = new ItemStack(Items.ICE); break;
|
||||
case PHASE_PACKEDICE: stack = new ItemStack(Items.PACKED_ICE); break;
|
||||
case PHASE_BLUEICE: stack = new ItemStack(Items.BLUE_ICE); break;
|
||||
default: return ItemStack.EMPTY;
|
||||
}
|
||||
if(extract) reset_process();
|
||||
return stack;
|
||||
}
|
||||
|
||||
public int comparator_signal()
|
||||
{ return phase() * 4; }
|
||||
|
||||
protected void reset_process()
|
||||
{
|
||||
force_block_update_ = true;
|
||||
tank_.drain(1000);
|
||||
tick_timer_ = 0;
|
||||
progress_ = 0;
|
||||
}
|
||||
|
||||
public void readnbt(CompoundNBT nbt)
|
||||
{
|
||||
energy_stored_ = nbt.getInt("energy");
|
||||
progress_ = nbt.getInt("progress");
|
||||
if(nbt.contains("tank", Constants.NBT.TAG_COMPOUND)) tank_.readnbt(nbt.getCompound("tank"));
|
||||
}
|
||||
|
||||
protected void writenbt(CompoundNBT nbt)
|
||||
{
|
||||
nbt.putInt("energy", MathHelper.clamp(energy_stored_,0 , MAX_ENERGY_BUFFER));
|
||||
nbt.putInt("progress", MathHelper.clamp(progress_,0 , 100));
|
||||
if(!tank_.isEmpty()) nbt.put("tank", tank_.writenbt(new CompoundNBT()));
|
||||
}
|
||||
|
||||
// TileEntity ------------------------------------------------------------------------------
|
||||
|
||||
@Override
|
||||
public void read(BlockState state, CompoundNBT nbt)
|
||||
{ super.read(state, nbt); readnbt(nbt); }
|
||||
|
||||
@Override
|
||||
public CompoundNBT write(CompoundNBT nbt)
|
||||
{ super.write(nbt); writenbt(nbt); return nbt; }
|
||||
|
||||
@Override
|
||||
public void remove()
|
||||
{
|
||||
super.remove();
|
||||
energy_handler_.invalidate();
|
||||
fluid_handler_.invalidate();
|
||||
item_handler_.invalidate();
|
||||
}
|
||||
|
||||
// IItemHandler --------------------------------------------------------------------------------
|
||||
|
||||
private LazyOptional<IItemHandler> item_handler_ = LazyOptional.of(() -> (IItemHandler)new FreezerItemHandler(this));
|
||||
|
||||
protected static class FreezerItemHandler implements IItemHandler
|
||||
{
|
||||
private FreezerTileEntity te;
|
||||
|
||||
FreezerItemHandler(FreezerTileEntity te)
|
||||
{ this.te = te; }
|
||||
|
||||
@Override
|
||||
public int getSlots()
|
||||
{ return 1; }
|
||||
|
||||
@Override
|
||||
public int getSlotLimit(int index)
|
||||
{ return 1; }
|
||||
|
||||
@Override
|
||||
public boolean isItemValid(int slot, @Nonnull ItemStack stack)
|
||||
{ return false; }
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public ItemStack getStackInSlot(int index)
|
||||
{ return (index!=0) ? ItemStack.EMPTY : te.getIceItem(false); }
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public ItemStack insertItem(int index, @Nonnull ItemStack stack, boolean simulate)
|
||||
{ return ItemStack.EMPTY; }
|
||||
|
||||
@Override
|
||||
@Nonnull
|
||||
public ItemStack extractItem(int index, int amount, boolean simulate)
|
||||
{ return te.getIceItem(!simulate); }
|
||||
}
|
||||
|
||||
// IFluidHandler --------------------------------------------------------------------------------
|
||||
|
||||
private final LazyOptional<IFluidHandler> fluid_handler_ = LazyOptional.of(() -> new Fluidics.SingleTankFluidHandler(tank_));
|
||||
|
||||
// IEnergyStorage ----------------------------------------------------------------------------
|
||||
|
||||
protected LazyOptional<IEnergyStorage> energy_handler_ = LazyOptional.of(() -> (IEnergyStorage)this);
|
||||
|
||||
@Override
|
||||
public boolean canExtract()
|
||||
{ return false; }
|
||||
|
||||
@Override
|
||||
public boolean canReceive()
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
public int getMaxEnergyStored()
|
||||
{ return MAX_ENERGY_BUFFER; }
|
||||
|
||||
@Override
|
||||
public int getEnergyStored()
|
||||
{ return energy_stored_; }
|
||||
|
||||
@Override
|
||||
public int extractEnergy(int maxExtract, boolean simulate)
|
||||
{ return 0; }
|
||||
|
||||
@Override
|
||||
public int receiveEnergy(int maxReceive, boolean simulate)
|
||||
{
|
||||
if(energy_stored_ >= MAX_ENERGY_BUFFER) return 0;
|
||||
int n = Math.min(maxReceive, (MAX_ENERGY_BUFFER - energy_stored_));
|
||||
if(n > MAX_ENERGY_TRANSFER) n = MAX_ENERGY_TRANSFER;
|
||||
if(!simulate) {energy_stored_ += n; markDirty(); }
|
||||
return n;
|
||||
}
|
||||
|
||||
// Capability export ----------------------------------------------------------------------------
|
||||
|
||||
@Override
|
||||
public <T> LazyOptional<T> getCapability(net.minecraftforge.common.capabilities.Capability<T> capability, @Nullable Direction facing)
|
||||
{
|
||||
if(capability == CapabilityItemHandler.ITEM_HANDLER_CAPABILITY) return item_handler_.cast();
|
||||
if(capability == CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY) return fluid_handler_.cast();
|
||||
if(capability == CapabilityEnergy.ENERGY) return energy_handler_.cast();
|
||||
return super.getCapability(capability, facing);
|
||||
}
|
||||
|
||||
// ITickable ------------------------------------------------------------------------------------
|
||||
|
||||
@Override
|
||||
public void tick()
|
||||
{
|
||||
if(world.isRemote) return;
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof FreezerBlock)) return;
|
||||
boolean dirty = false;
|
||||
final int last_phase = phase();
|
||||
if(tank_.getFluidAmount() < 1000) {
|
||||
progress_ = 0;
|
||||
} else if((energy_stored_ <= 0) || (world.isBlockPowered(pos))) {
|
||||
progress_ = MathHelper.clamp(progress_-reheat_rate, 0,100);
|
||||
} else if(progress_ >= 100) {
|
||||
progress_ = 100;
|
||||
energy_stored_ = MathHelper.clamp(energy_stored_-((energy_consumption*TICK_INTERVAL)/20), 0, MAX_ENERGY_BUFFER);
|
||||
} else {
|
||||
energy_stored_ = MathHelper.clamp(energy_stored_-(energy_consumption*TICK_INTERVAL), 0, MAX_ENERGY_BUFFER);
|
||||
progress_ = MathHelper.clamp(progress_+cooldown_rate, 0, 100);
|
||||
}
|
||||
int new_phase = phase();
|
||||
if(new_phase > last_phase) {
|
||||
world.playSound(null, pos, SoundEvents.BLOCK_SAND_FALL, SoundCategory.BLOCKS, 0.2f, 0.7f);
|
||||
} else if(new_phase < last_phase) {
|
||||
world.playSound(null, pos, SoundEvents.BLOCK_SAND_FALL, SoundCategory.BLOCKS, 0.2f, 0.7f);
|
||||
}
|
||||
// Block state
|
||||
if((force_block_update_ || (state.get(FreezerBlock.PHASE) != new_phase))) {
|
||||
state = state.with(FreezerBlock.PHASE, new_phase);
|
||||
world.setBlockState(pos, state,3|16);
|
||||
world.notifyNeighborsOfStateChange(getPos(), state.getBlock());
|
||||
force_block_update_ = false;
|
||||
}
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* @file EdSoilBlock.java
|
||||
* @file EdGroundBlock.java
|
||||
* @author Stefan Wilhelm (wile)
|
||||
* @copyright (C) 2019 Stefan Wilhelm
|
||||
* @license MIT (see https://opensource.org/licenses/MIT)
|
||||
|
@ -11,10 +11,8 @@ package wile.engineersdecor.blocks;
|
|||
|
||||
import net.minecraft.block.*;
|
||||
|
||||
|
||||
public class EdGroundBlock extends DecorBlock.Normal implements IDecorBlock
|
||||
{
|
||||
public EdGroundBlock(long config, Block.Properties builder)
|
||||
{ super(config, builder); }
|
||||
|
||||
}
|
||||
|
|
|
@ -10,9 +10,7 @@ package wile.engineersdecor.blocks;
|
|||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.EntitySpawnPlacementRegistry;
|
||||
import net.minecraft.entity.EntityType;
|
||||
import net.minecraft.entity.LivingEntity;
|
||||
import net.minecraft.entity.*;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.pathfinding.PathType;
|
||||
import net.minecraft.state.BooleanProperty;
|
||||
|
@ -24,6 +22,7 @@ import net.minecraft.util.math.BlockPos;
|
|||
import net.minecraft.util.math.BlockRayTraceResult;
|
||||
import net.minecraft.util.math.shapes.ISelectionContext;
|
||||
import net.minecraft.util.math.shapes.VoxelShape;
|
||||
import net.minecraft.util.math.vector.Vector3d;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.IWorldReader;
|
||||
import net.minecraft.world.World;
|
||||
|
@ -66,7 +65,7 @@ public class EdHatchBlock extends DecorBlock.HorizontalWaterLoggable implements
|
|||
|
||||
@Override
|
||||
public boolean isLadder(BlockState state, IWorldReader world, BlockPos pos, LivingEntity entity)
|
||||
{ return state.get(OPEN); }
|
||||
{ return state.get(OPEN) && world.getBlockState(pos.up()).isLadder(world, pos, entity); }
|
||||
|
||||
@Override
|
||||
public boolean canCreatureSpawn(BlockState state, IBlockReader world, BlockPos pos, EntitySpawnPlacementRegistry.PlacementType type, @Nullable EntityType<?> entityType)
|
||||
|
@ -97,4 +96,19 @@ public class EdHatchBlock extends DecorBlock.HorizontalWaterLoggable implements
|
|||
world.setBlockState(pos, state.with(OPEN, powered).with(POWERED, powered), 1|2);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public void onEntityCollision(BlockState state, World world, BlockPos pos, Entity entity)
|
||||
{
|
||||
if((!state.get(OPEN)) || (!(entity instanceof PlayerEntity))) return;
|
||||
final PlayerEntity player = (PlayerEntity)entity;
|
||||
if(entity.getLookVec().getY() > -0.75) return;
|
||||
if(player.getHorizontalFacing() != state.get(HORIZONTAL_FACING)) return;
|
||||
Vector3d ppos = player.getPositionVec();
|
||||
Vector3d centre = Vector3d.copyCenteredHorizontally(pos);
|
||||
Vector3d v = centre.subtract(ppos);
|
||||
if(ppos.getY() < (centre.getY()-0.1) || (v.lengthSquared() > 0.3)) return;
|
||||
v = v.scale(0.3);
|
||||
player.addVelocity(v.x, 0, v.z);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
package wile.engineersdecor.blocks;
|
||||
|
||||
import com.mojang.blaze3d.matrix.MatrixStack;
|
||||
import net.minecraft.world.IWorldReader;
|
||||
import wile.engineersdecor.ModContent;
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
|
@ -173,6 +174,10 @@ public class EdHopper
|
|||
((HopperTileEntity)te).collection_timer_ = 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldCheckWeakPower(BlockState state, IWorldReader world, BlockPos pos, Direction side)
|
||||
{ return false; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public boolean canProvidePower(BlockState state)
|
||||
|
|
|
@ -87,12 +87,22 @@ public class EdLadderBlock extends LadderBlock implements IDecorBlock
|
|||
{
|
||||
if((without_speed_boost_) || (player.isOnGround()) || (!player.isOnLadder()) || (player.isSteppingCarefully()) || (player.isSpectator())) return;
|
||||
double lvy = player.getLookVec().y;
|
||||
if(Math.abs(lvy) < 0.94) return;
|
||||
if(Math.abs(lvy) < 0.92) return;
|
||||
final BlockPos pos = player.getPosition();
|
||||
final BlockState state = player.world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof EdLadderBlock)) return;
|
||||
player.fallDistance = 0;
|
||||
player.setMotionMultiplier(state, new Vector3d(0.2, (lvy>0)?(3):(6), 0.2));
|
||||
if((player.getMotion().getY() < 0) == (player.getLookVec().y < 0)) {
|
||||
player.setMotionMultiplier(state, new Vector3d(0.2, (lvy>0)?(3):(6), 0.2));
|
||||
if(Math.abs(player.getMotion().getY()) > 0.1) {
|
||||
Vector3d vdiff = Vector3d.copyCenteredHorizontally(pos).subtract(player.getPositionVec()).scale(1);
|
||||
vdiff.add(Vector3d.copyCenteredHorizontally(state.get(FACING).getDirectionVec()).scale(0.5));
|
||||
vdiff = new Vector3d(vdiff.x, player.getMotion().y, vdiff.z);
|
||||
player.setMotion(vdiff);
|
||||
}
|
||||
} else if(player.getLookVec().y > 0) {
|
||||
player.setMotionMultiplier(state, new Vector3d(1, 0.05, 1));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -21,6 +21,7 @@ import net.minecraft.util.*;
|
|||
import net.minecraft.util.Direction.Axis;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.shapes.IBooleanFunction;
|
||||
import net.minecraft.util.math.shapes.ISelectionContext;
|
||||
import net.minecraft.util.math.shapes.VoxelShape;
|
||||
import net.minecraft.util.math.shapes.VoxelShapes;
|
||||
|
@ -36,14 +37,16 @@ public class EdRoofBlock extends StandardBlocks.HorizontalWaterLoggable implemen
|
|||
{
|
||||
public static final EnumProperty<StairsShape> SHAPE = BlockStateProperties.STAIRS_SHAPE;
|
||||
public static final EnumProperty<Half> HALF = BlockStateProperties.HALF;
|
||||
private static final VoxelShape[][][] SHAPE_CACHE = makeShapes();
|
||||
private final VoxelShape[][][] shape_cache_;
|
||||
|
||||
public EdRoofBlock(long config, Block.Properties properties)
|
||||
{ this(config, properties, VoxelShapes.empty(), VoxelShapes.empty()); }
|
||||
|
||||
public EdRoofBlock(long config, Block.Properties properties, VoxelShape add, VoxelShape cut)
|
||||
{
|
||||
super(config,
|
||||
properties,//.func_235838_a_((state)->1).notSolid(), //shade rendering again messed up
|
||||
Auxiliaries.getPixeledAABB(0, 0,0,16, 8, 16));
|
||||
super(config, properties, Auxiliaries.getPixeledAABB(0, 0,0,16, 8, 16));
|
||||
setDefaultState(stateContainer.getBaseState().with(HORIZONTAL_FACING, Direction.NORTH).with(SHAPE, StairsShape.STRAIGHT).with(WATERLOGGED, false));
|
||||
shape_cache_ = makeShapes(add, cut);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -53,7 +56,7 @@ public class EdRoofBlock extends StandardBlocks.HorizontalWaterLoggable implemen
|
|||
|
||||
@Override
|
||||
public VoxelShape getShape(BlockState state, IBlockReader world, BlockPos pos, ISelectionContext context)
|
||||
{ return SHAPE_CACHE[state.get(HALF).ordinal()][state.get(HORIZONTAL_FACING).getIndex()][state.get(SHAPE).ordinal()]; }
|
||||
{ return shape_cache_[state.get(HALF).ordinal()][state.get(HORIZONTAL_FACING).getIndex()][state.get(SHAPE).ordinal()]; }
|
||||
|
||||
@Override
|
||||
protected void fillStateContainer(StateContainer.Builder<Block, BlockState> builder)
|
||||
|
@ -123,13 +126,22 @@ public class EdRoofBlock extends StandardBlocks.HorizontalWaterLoggable implemen
|
|||
return (!isRoofBlock(st)) || (st.get(HORIZONTAL_FACING) != state.get(HORIZONTAL_FACING));
|
||||
}
|
||||
|
||||
private static VoxelShape[][][] makeShapes()
|
||||
private static VoxelShape[][][] makeShapes(VoxelShape add, VoxelShape cut)
|
||||
{
|
||||
VoxelShape[][][] shapes = new VoxelShape[2][6][5];
|
||||
for(int half_index=0; half_index<Half.values().length; ++half_index) {
|
||||
for(int direction_index=0; direction_index<Direction.values().length; ++direction_index) {
|
||||
for(int stairs_shape_index=0; stairs_shape_index<StairsShape.values().length; ++stairs_shape_index) {
|
||||
shapes[half_index][direction_index][stairs_shape_index] = makeShape(half_index, direction_index, stairs_shape_index);
|
||||
VoxelShape shape = makeShape(half_index, direction_index, stairs_shape_index);
|
||||
try {
|
||||
// Only in case something changes and this fails, log but do not prevent the game from starting.
|
||||
// Roof shapes are not the most important thing in the world.
|
||||
if(!add.isEmpty()) shape = VoxelShapes.combine(shape, add, IBooleanFunction.OR);
|
||||
if(!cut.isEmpty()) shape = VoxelShapes.combine(shape, cut, IBooleanFunction.ONLY_FIRST);
|
||||
} catch(Throwable ex) {
|
||||
Auxiliaries.logError("Failed to cut shape using Boolean function. This is bug.");
|
||||
}
|
||||
shapes[half_index][direction_index][stairs_shape_index] = shape;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
46
src/main/java/wile/engineersdecor/items/EdItem.java
Normal file
46
src/main/java/wile/engineersdecor/items/EdItem.java
Normal file
|
@ -0,0 +1,46 @@
|
|||
/*
|
||||
* @file EdItem.java
|
||||
* @author Stefan Wilhelm (wile)
|
||||
* @copyright (C) 2020 Stefan Wilhelm
|
||||
* @license MIT (see https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Basic item functionality for mod items.
|
||||
*/
|
||||
package wile.engineersdecor.items;
|
||||
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import wile.engineersdecor.ModConfig;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
import net.minecraft.client.util.ITooltipFlag;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemGroup;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.text.ITextComponent;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
public class EdItem extends Item
|
||||
{
|
||||
public static final Collection<ItemGroup> ENABLED_TABS = Collections.singletonList(ModEngineersDecor.ITEMGROUP);
|
||||
public static final Collection<ItemGroup> DISABLED_TABS = new ArrayList<ItemGroup>();
|
||||
|
||||
public EdItem(Item.Properties properties)
|
||||
{ super(properties.group(ModEngineersDecor.ITEMGROUP)); }
|
||||
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public void addInformation(ItemStack stack, @Nullable World world, List<ITextComponent> tooltip, ITooltipFlag flag)
|
||||
{ Auxiliaries.Tooltip.addInformation(stack, world, tooltip, flag, true); }
|
||||
|
||||
@Override
|
||||
public Collection<ItemGroup> getCreativeTabs()
|
||||
{ return ModConfig.isOptedOut(this) ? (DISABLED_TABS) : (ENABLED_TABS); }
|
||||
|
||||
}
|
|
@ -69,6 +69,9 @@ public class Fluidics
|
|||
public Tank(int capacity)
|
||||
{ capacity_ = capacity; }
|
||||
|
||||
public Tank(int capacity, Predicate<FluidStack> validator)
|
||||
{ capacity_ = capacity; setValidator(validator); }
|
||||
|
||||
public Tank readnbt(CompoundNBT nbt)
|
||||
{ setFluid(FluidStack.loadFluidStackFromNBT(nbt)); return this; }
|
||||
|
||||
|
@ -136,6 +139,10 @@ public class Fluidics
|
|||
}
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
public FluidStack drain(int maxDrain)
|
||||
{ return drain(maxDrain, FluidAction.EXECUTE); }
|
||||
|
||||
@Nonnull
|
||||
@Override
|
||||
public FluidStack drain(FluidStack fs, FluidAction action)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue