Skip to content

Commit

Permalink
Added Road_Barricade
Browse files Browse the repository at this point in the history
Added in Road_Barricade_1, Road_Barricade_2, Road_Barricade_3
  • Loading branch information
0xE69 committed Mar 29, 2024
1 parent d561229 commit 57edd33
Show file tree
Hide file tree
Showing 19 changed files with 537 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"required": true,
"package": "com.craftingdead.core.mixin",
"compatibilityLevel": "JAVA_17",
"minVersion": "0.8",
"refmap": "craftingdead.refmap.json",
"mixins": [
"AbstractContainerMenuMixin",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ static void register() {
// cutout(DecorationBlocks.DARK_OAK_PLANK_BARRICADE_2);
// cutout(DecorationBlocks.DARK_OAK_PLANK_BARRICADE_3);


cutout(DecorationBlocks.COMPUTER_1);
cutout(DecorationBlocks.COMPUTER_2);
cutout(DecorationBlocks.COMPUTER_3);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,20 @@ public ItemStack makeIcon() {
() -> new BlockItem(DecorationBlocks.WORN_GREEN_BARREL_2.get(),
new Item.Properties().tab(TAB)));

public static final RegistryObject<BlockItem> ROAD_BARRICADE_1 =
deferredRegister.register("road_barricade_1",
() -> new BlockItem(DecorationBlocks.ROAD_BARRICADE_3.get(),
new Item.Properties().tab(TAB)));
public static final RegistryObject<BlockItem> ROAD_BARRICADE_2 =
deferredRegister.register("road_barricade_2",
() -> new BlockItem(DecorationBlocks.ROAD_BARRICADE_3.get(),
new Item.Properties().tab(TAB)));
public static final RegistryObject<BlockItem> ROAD_BARRICADE_3 =
deferredRegister.register("road_barricade_3",
() -> new BlockItem(DecorationBlocks.ROAD_BARRICADE_3.get(),
new Item.Properties().tab(TAB)));


public static final RegistryObject<BlockItem> RED_BARREL_1 =
deferredRegister.register("red_barrel_1",
() -> new BlockItem(DecorationBlocks.RED_BARREL_1.get(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,18 @@ public class BlockShapes {
Block.box(3, 9, 13.5, 13, 10, 14.5),
Block.box(1.5, 8, 3, 2.5, 9, 13));

public static final Function<Direction, VoxelShape> ROAD_BARRICADE_1 = rotatedOrientableShape(Shapes.or(
Block.box(0, 11, 6, 17, 15, 10),
Block.box(0, 0, 4, 17, 11, 12)));

public static final Function<Direction, VoxelShape> ROAD_BARRICADE_2 = rotatedOrientableShape(Shapes.or(
Block.box(0, 11, 6, 17, 15, 10),
Block.box(0, 0, 4, 17, 11, 12)));

public static final Function<Direction, VoxelShape> ROAD_BARRICADE_3 = rotatedOrientableShape(Shapes.or(
Block.box(0, 11, 6, 17, 15, 10),
Block.box(0, 0, 4, 17, 11, 12)));

public static final VoxelShape FLOWER_POT = Shapes.or(
Block.box(6.5, 9, 6.25, 8, 12, 8),
Block.box(4, 0, 4, 12, 7, 12),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,31 @@ public class DecorationBlocks {
.sound(SoundType.METAL)
.noCollission(),
BlockShapes.BOXES_OF_SHOTGUN_SHELLS, false));


public static final RegistryObject<Block> ROAD_BARRICADE_1 =
deferredRegister.register("road_barricade_1",
() -> new OrientableBlock(
BlockBehaviour.Properties.of(Material.METAL)
.strength(5.0F)
.sound(SoundType.METAL),
BlockShapes.ROAD_BARRICADE_1));

public static final RegistryObject<Block> ROAD_BARRICADE_2 =
deferredRegister.register("road_barricade_2",
() -> new OrientableBlock(
BlockBehaviour.Properties.of(Material.METAL)
.strength(5.0F)
.sound(SoundType.METAL),
BlockShapes.ROAD_BARRICADE_2));

public static final RegistryObject<Block> ROAD_BARRICADE_3 =
deferredRegister.register("road_barricade_3",
() -> new OrientableBlock(
BlockBehaviour.Properties.of(Material.METAL)
.strength(5.0F)
.sound(SoundType.METAL),
BlockShapes.ROAD_BARRICADE_3));

public static final RegistryObject<Block> BOXES_OF_SHOTGUN_SHELLS_BLUE =
deferredRegister.register("boxes_of_shotgun_shells_blue",
() -> new OrientableBlock(
Expand Down Expand Up @@ -286,6 +310,7 @@ public class DecorationBlocks {
.noOcclusion(),
BlockShapes.STORE_SHELF));


public static final RegistryObject<Block> BOTTOM_CAN_STORE_SHELF_1 =
deferredRegister.register("bottom_can_store_shelf_1",
() -> new OrientableBlock(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"variants": {
"facing=east": {
"model": "craftingdeaddecoration:block/road_barricade_1",
"y": 90
},
"facing=north": {
"model": "craftingdeaddecoration:block/road_barricade_1"
},
"facing=west": {
"model": "craftingdeaddecoration:block/road_barricade_1",
"y": 270
},
"facing=south": {
"model": "craftingdeaddecoration:block/road_barricade_1",
"y": 180
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"variants": {
"facing=east": {
"model": "craftingdeaddecoration:block/road_barricade_2",
"y": 90
},
"facing=north": {
"model": "craftingdeaddecoration:block/road_barricade_2"
},
"facing=west": {
"model": "craftingdeaddecoration:block/road_barricade_2",
"y": 270
},
"facing=south": {
"model": "craftingdeaddecoration:block/road_barricade_2",
"y": 180
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"variants": {
"facing=east": {
"model": "craftingdeaddecoration:block/road_barricade_3",
"y": 90
},
"facing=north": {
"model": "craftingdeaddecoration:block/road_barricade_3"
},
"facing=west": {
"model": "craftingdeaddecoration:block/road_barricade_3",
"y": 270
},
"facing=south": {
"model": "craftingdeaddecoration:block/road_barricade_3",
"y": 180
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@
"block.craftingdeaddecoration.box_store_shelf_3": "Box Store Shelf 3",
"block.craftingdeaddecoration.box_store_shelf_4": "Box Store Shelf 4",

"block.craftingdeaddecoration.road_barricade_1": "Road Barricade 1",
"block.craftingdeaddecoration.road_barricade_2": "Road Barricade 2",
"block.craftingdeaddecoration.road_barricade_3": "Road Barricade 3",


"block.craftingdeaddecoration.bottom_box_store_shelf_1": "Bottom Box Store Shelf 1",
"block.craftingdeaddecoration.bottom_box_store_shelf_2": "Bottom Box Store Shelf 2",
"block.craftingdeaddecoration.bottom_box_store_shelf_3": "Bottom Box Store Shelf 3",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,178 @@
{
"credit": "Made with Blockbench",
"texture_size": [64, 64],
"textures": {
"0": "craftingdeaddecoration:block/road_barricade_1",
"particle": "#0"
},
"elements": [
{
"from": [2, 1.5, 7.5],
"to": [14, 3.5, 8.5],
"rotation": {"angle": 22.5, "axis": "x", "origin": [1, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 6, 3.25, 6.5], "texture": "#0"},
"east": {"uv": [0, 6, 0.25, 6.5], "texture": "#0"},
"south": {"uv": [3.5, 6, 6.5, 6.5], "texture": "#0"},
"west": {"uv": [3.25, 6, 3.5, 6.5], "texture": "#0"},
"up": {"uv": [3.25, 6, 0.25, 5.75], "texture": "#0"},
"down": {"uv": [6.25, 5.75, 3.25, 6], "texture": "#0"}
}
},
{
"from": [2, 1.5, 7.5],
"to": [14, 3.5, 8.5],
"rotation": {"angle": -22.5, "axis": "x", "origin": [15, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 5.25, 3.25, 5.75], "texture": "#0"},
"east": {"uv": [0, 5.25, 0.25, 5.75], "texture": "#0"},
"south": {"uv": [3.5, 5.25, 6.5, 5.75], "texture": "#0"},
"west": {"uv": [3.25, 5.25, 3.5, 5.75], "texture": "#0"},
"up": {"uv": [3.25, 5.25, 0.25, 5], "texture": "#0"},
"down": {"uv": [6.25, 5, 3.25, 5.25], "texture": "#0"}
}
},
{
"from": [14, -1.5, 7.5],
"to": [16, 15.5, 8.5],
"rotation": {"angle": -22.5, "axis": "x", "origin": [15, 15.5, 8]},
"faces": {
"north": {"uv": [3.25, 6.75, 3.75, 11], "texture": "#0"},
"east": {"uv": [3, 6.75, 3.25, 11], "texture": "#0"},
"south": {"uv": [4, 6.75, 4.5, 11], "texture": "#0"},
"west": {"uv": [3.75, 6.75, 4, 11], "texture": "#0"},
"up": {"uv": [3.75, 6.75, 3.25, 6.5], "texture": "#0"},
"down": {"uv": [4.25, 6.5, 3.75, 6.75], "texture": "#0"}
}
},
{
"from": [14, -1.5, 7.5],
"to": [16, 15.5, 8.5],
"rotation": {"angle": 22.5, "axis": "x", "origin": [15, 15.5, 8]},
"faces": {
"north": {"uv": [1.75, 6.75, 2.25, 11], "texture": "#0"},
"east": {"uv": [1.5, 6.75, 1.75, 11], "texture": "#0"},
"south": {"uv": [2.5, 6.75, 3, 11], "texture": "#0"},
"west": {"uv": [2.25, 6.75, 2.5, 11], "texture": "#0"},
"up": {"uv": [2.25, 6.75, 1.75, 6.5], "texture": "#0"},
"down": {"uv": [2.75, 6.5, 2.25, 6.75], "texture": "#0"}
}
},
{
"from": [0, -1.5, 7.5],
"to": [2, 15.5, 8.5],
"rotation": {"angle": -22.5, "axis": "x", "origin": [1, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 6.75, 0.75, 11], "texture": "#0"},
"east": {"uv": [0, 6.75, 0.25, 11], "texture": "#0"},
"south": {"uv": [1, 6.75, 1.5, 11], "texture": "#0"},
"west": {"uv": [0.75, 6.75, 1, 11], "texture": "#0"},
"up": {"uv": [0.75, 6.75, 0.25, 6.5], "texture": "#0"},
"down": {"uv": [1.25, 6.5, 0.75, 6.75], "texture": "#0"}
}
},
{
"from": [0, -1.5, 7.5],
"to": [2, 15.5, 8.5],
"rotation": {"angle": 22.5, "axis": "x", "origin": [1, 15.5, 8]},
"faces": {
"north": {"uv": [6.5, 6.5, 7, 10.75], "texture": "#0"},
"east": {"uv": [6.25, 6.5, 6.5, 10.75], "texture": "#0"},
"south": {"uv": [7.25, 6.5, 7.75, 10.75], "texture": "#0"},
"west": {"uv": [7, 6.5, 7.25, 10.75], "texture": "#0"},
"up": {"uv": [7, 6.5, 6.5, 6.25], "texture": "#0"},
"down": {"uv": [7.5, 6.25, 7, 6.5], "texture": "#0"}
}
},
{
"from": [13.5, 14.75, 7.5],
"to": [16.5, 16.75, 8.5],
"faces": {
"north": {"uv": [7.75, 6, 8.5, 6.5], "texture": "#0"},
"east": {"uv": [7.5, 6, 7.75, 6.5], "texture": "#0"},
"south": {"uv": [8.75, 6, 9.5, 6.5], "texture": "#0"},
"west": {"uv": [8.5, 6, 8.75, 6.5], "texture": "#0"},
"up": {"uv": [8.5, 6, 7.75, 5.75], "texture": "#0"},
"down": {"uv": [9.25, 5.75, 8.5, 6], "texture": "#0"}
}
},
{
"from": [-0.5, 14.75, 7.5],
"to": [2.5, 16.75, 8.5],
"faces": {
"north": {"uv": [6.75, 5.25, 7.5, 5.75], "texture": "#0"},
"east": {"uv": [6.5, 5.25, 6.75, 5.75], "texture": "#0"},
"south": {"uv": [7.75, 5.25, 8.5, 5.75], "texture": "#0"},
"west": {"uv": [7.5, 5.25, 7.75, 5.75], "texture": "#0"},
"up": {"uv": [7.5, 5.25, 6.75, 5], "texture": "#0"},
"down": {"uv": [8.25, 5, 7.5, 5.25], "texture": "#0"}
}
},
{
"from": [-1, 10.5, 8.5],
"to": [17, 14.5, 9.5],
"rotation": {"angle": -22.5, "axis": "x", "origin": [15, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 4, 4.75, 5], "texture": "#0"},
"east": {"uv": [0, 4, 0.25, 5], "texture": "#0"},
"south": {"uv": [5, 4, 9.5, 5], "texture": "#0"},
"west": {"uv": [4.75, 4, 5, 5], "texture": "#0"},
"up": {"uv": [4.75, 4, 0.25, 3.75], "texture": "#0"},
"down": {"uv": [9.25, 3.75, 4.75, 4], "texture": "#0"}
}
},
{
"from": [-1, 5.5, 8.5],
"to": [17, 9.5, 9.5],
"rotation": {"angle": -22.5, "axis": "x", "origin": [15, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 2.75, 4.75, 3.75], "texture": "#0"},
"east": {"uv": [0, 2.75, 0.25, 3.75], "texture": "#0"},
"south": {"uv": [5, 2.75, 9.5, 3.75], "texture": "#0"},
"west": {"uv": [4.75, 2.75, 5, 3.75], "texture": "#0"},
"up": {"uv": [4.75, 2.75, 0.25, 2.5], "texture": "#0"},
"down": {"uv": [9.25, 2.5, 4.75, 2.75], "texture": "#0"}
}
},
{
"from": [-1, 5.5, 6.5],
"to": [17, 9.5, 7.5],
"rotation": {"angle": 22.5, "axis": "x", "origin": [1, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 1.5, 4.75, 2.5], "texture": "#0"},
"east": {"uv": [0, 1.5, 0.25, 2.5], "texture": "#0"},
"south": {"uv": [5, 1.5, 9.5, 2.5], "texture": "#0"},
"west": {"uv": [4.75, 1.5, 5, 2.5], "texture": "#0"},
"up": {"uv": [4.75, 1.5, 0.25, 1.25], "texture": "#0"},
"down": {"uv": [9.25, 1.25, 4.75, 1.5], "texture": "#0"}
}
},
{
"from": [-1, 10.5, 6.5],
"to": [17, 14.5, 7.5],
"rotation": {"angle": 22.5, "axis": "x", "origin": [1, 15.5, 8]},
"faces": {
"north": {"uv": [0.25, 0.25, 4.75, 1.25], "texture": "#0"},
"east": {"uv": [0, 0.25, 0.25, 1.25], "texture": "#0"},
"south": {"uv": [5, 0.25, 9.5, 1.25], "texture": "#0"},
"west": {"uv": [4.75, 0.25, 5, 1.25], "texture": "#0"},
"up": {"uv": [4.75, 0.25, 0.25, 0], "texture": "#0"},
"down": {"uv": [9.25, 0, 4.75, 0.25], "texture": "#0"}
}
}
],
"groups": [
{
"name": "group",
"origin": [1, 15.5, 8],
"color": 6,
"children": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
},
{
"name": "VoxelShapes",
"origin": [8, 8, 8],
"color": 0,
"children": []
}
]
}

0 comments on commit 57edd33

Please sign in to comment.