Skip to content

Commit

Permalink
2.0 progress. Lattices, Balustrades
Browse files Browse the repository at this point in the history
  • Loading branch information
crispytwig committed Sep 19, 2024
1 parent 299cde6 commit a530e02
Show file tree
Hide file tree
Showing 237 changed files with 10,101 additions and 157 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
- To remove the Dirt, simply right-click the Urn with any Shovel -- this uses the #minecraft:shovels tag, so any item tagged as a Shovel will work.
- Urns utilize Supplementaries' "prevents_offset_above" tag, so when using Supplementaries, plants will not have a random offset when placed inside of Urns. This prevents them from being placed on the edges of the Urn.
- ### Stone Frames + Frame Tweaks
- ***Frames should no longer crash when connected to a non-solid block!***
- Frames now have custom hitboxes, and can be interacted through. Their more precise hitboxes will be replaced with a larger hitbox when holding Hammers or Frames or crouching.
- **There is a config available to change these hitboxes to always be visible or to not get show at all when crouching.**
- Frame tooltips also change depending on which config option you have enabled!
Expand Down
24 changes: 22 additions & 2 deletions src/main/java/com/starfish_studios/bbb/BBBVanillaIntegration.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,17 @@ private static void registerBlockColors() {
}
return BiomeColors.getAverageFoliageColor(world, pos);
},
BBBBlocks.OAK_LATTICE
BBBBlocks.OAK_LATTICE,
BBBBlocks.SPRUCE_LATTICE,
BBBBlocks.BIRCH_LATTICE,
BBBBlocks.JUNGLE_LATTICE,
BBBBlocks.ACACIA_LATTICE,
BBBBlocks.DARK_OAK_LATTICE,
BBBBlocks.CRIMSON_LATTICE,
BBBBlocks.WARPED_LATTICE,
BBBBlocks.MANGROVE_LATTICE,
BBBBlocks.BAMBOO_LATTICE,
BBBBlocks.CHERRY_LATTICE
);

ColorProviderRegistry.ITEM.register((stack, tintIndex) -> {
Expand Down Expand Up @@ -81,7 +91,17 @@ private static void registerBlockRenderLayers() {
BBBBlocks.MANGROVE_LADDER,
BBBBlocks.BAMBOO_LADDER,
BBBBlocks.CHERRY_LADDER,
BBBBlocks.OAK_LATTICE
BBBBlocks.OAK_LATTICE,
BBBBlocks.SPRUCE_LATTICE,
BBBBlocks.BIRCH_LATTICE,
BBBBlocks.JUNGLE_LATTICE,
BBBBlocks.ACACIA_LATTICE,
BBBBlocks.DARK_OAK_LATTICE,
BBBBlocks.CRIMSON_LATTICE,
BBBBlocks.WARPED_LATTICE,
BBBBlocks.MANGROVE_LATTICE,
BBBBlocks.BAMBOO_LATTICE,
BBBBlocks.CHERRY_LATTICE
);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public class BalustradeBlock extends Block implements SimpleWaterloggedBlock {
public static BooleanProperty WATERLOGGED = BlockStateProperties.WATERLOGGED;

public static VoxelShape BOTTOM_AABB = Block.box(0, 0, 0, 16, 2, 16);
public static VoxelShape TOP_AABB = Block.box(0, 12, 0, 16, 16, 16);
public static VoxelShape TOP_AABB = Block.box(0, 13, 0, 16, 16, 16);
public static VoxelShape PILLAR_AABB = Block.box(4, 0, 4, 12, 16, 12);

public static VoxelShape NORTH_TILTED_AABB = Shapes.or(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public class LatticeBlock extends Block implements SimpleWaterloggedBlock, Bonem
map.put(LatticePlantType.FLOWERING_AZALEA_LEAVES, Items.FLOWERING_AZALEA_LEAVES);
map.put(LatticePlantType.MANGROVE_LEAVES, Items.MANGROVE_LEAVES);
map.put(LatticePlantType.CHERRY_LEAVES, Items.CHERRY_LEAVES);
map.put(LatticePlantType.ROSE_BUSH, Items.ROSE_BUSH);
// map.put(LatticePlantType.ROSE_BUSH, Items.ROSE_BUSH);
map.put(LatticePlantType.GLOW_LICHEN, Items.GLOW_LICHEN);
map.put(LatticePlantType.CAVE_VINES, Items.GLOW_BERRIES);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public enum LatticePlantType implements StringRepresentable {
FLOWERING_AZALEA_LEAVES("flowering_azalea_leaves"),
MANGROVE_LEAVES("mangrove_leaves"),
CHERRY_LEAVES("cherry_leaves"),
ROSE_BUSH("rose_bush"),
// ROSE_BUSH("rose_bush"),
GLOW_LICHEN("glow_lichen"),
CAVE_VINES("cave_vines");

Expand Down
28 changes: 22 additions & 6 deletions src/main/java/com/starfish_studios/bbb/registry/BBBBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,31 @@ public class BBBBlocks {

// region BALUSTRADES
public static final Block OAK_BALUSTRADE = register("oak_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.OAK_PLANKS)).noOcclusion()));
// public static final Block SPRUCE_BALUSTRADE = register("spruce_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.SPRUCE_PLANKS)).noOcclusion()));
// public static final Block BIRCH_BALUSTRADE = register("birch_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.BIRCH_PLANKS)).noOcclusion()));
// public static final Block JUNGLE_BALUSTRADE = register("jungle_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.JUNGLE_PLANKS)).noOcclusion()));
// public static final Block ACACIA_BALUSTRADE = register("acacia_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.ACACIA_PLANKS)).noOcclusion()));
// public static final Block DARK_OAK_BALUSTRADE = register("dark_oak_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.DARK_OAK_PLANKS)).noOcclusion()));

public static final Block SPRUCE_BALUSTRADE = register("spruce_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.SPRUCE_PLANKS)).noOcclusion()));
public static final Block BIRCH_BALUSTRADE = register("birch_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.BIRCH_PLANKS)).noOcclusion()));
public static final Block JUNGLE_BALUSTRADE = register("jungle_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.JUNGLE_PLANKS)).noOcclusion()));
public static final Block ACACIA_BALUSTRADE = register("acacia_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.ACACIA_PLANKS)).noOcclusion()));
public static final Block DARK_OAK_BALUSTRADE = register("dark_oak_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.DARK_OAK_PLANKS)).noOcclusion()));
public static final Block CRIMSON_BALUSTRADE = register("crimson_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.CRIMSON_PLANKS)).noOcclusion()));
public static final Block WARPED_BALUSTRADE = register("warped_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.WARPED_PLANKS)).noOcclusion()));
public static final Block MANGROVE_BALUSTRADE = register("mangrove_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.MANGROVE_PLANKS)).noOcclusion()));
public static final Block BAMBOO_BALUSTRADE = register("bamboo_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.BAMBOO_PLANKS)).noOcclusion()));
public static final Block CHERRY_BALUSTRADE = register("cherry_balustrade", new BalustradeBlock(FabricBlockSettings.copy((Blocks.CHERRY_PLANKS)).noOcclusion()));
// endregion

// region LATTICES
public static final Block OAK_LATTICE = register("oak_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.OAK_PLANKS)).noOcclusion()));
public static final Block SPRUCE_LATTICE = register("spruce_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.SPRUCE_PLANKS)).noOcclusion()));
public static final Block BIRCH_LATTICE = register("birch_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.BIRCH_PLANKS)).noOcclusion()));
public static final Block JUNGLE_LATTICE = register("jungle_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.JUNGLE_PLANKS)).noOcclusion()));
public static final Block ACACIA_LATTICE = register("acacia_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.ACACIA_PLANKS)).noOcclusion()));
public static final Block DARK_OAK_LATTICE = register("dark_oak_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.DARK_OAK_PLANKS)).noOcclusion()));
public static final Block CRIMSON_LATTICE = register("crimson_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.CRIMSON_PLANKS)).noOcclusion()));
public static final Block WARPED_LATTICE = register("warped_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.WARPED_PLANKS)).noOcclusion()));
public static final Block MANGROVE_LATTICE = register("mangrove_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.MANGROVE_PLANKS)).noOcclusion()));
public static final Block BAMBOO_LATTICE = register("bamboo_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.BAMBOO_PLANKS)).noOcclusion()));
public static final Block CHERRY_LATTICE = register("cherry_lattice", new LatticeBlock(FabricBlockSettings.copy((Blocks.CHERRY_PLANKS)).noOcclusion()));
// endregion


// region WALLS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,29 @@ public class BBBCreativeModeTab {
output.accept(SOUL_BRAZIER);
output.accept(IRON_FENCE);

output.accept(OAK_LATTICE);
output.accept(SPRUCE_LATTICE);
output.accept(BIRCH_LATTICE);
output.accept(JUNGLE_LATTICE);
output.accept(ACACIA_LATTICE);
output.accept(DARK_OAK_LATTICE);
output.accept(CRIMSON_LATTICE);
output.accept(WARPED_LATTICE);
output.accept(MANGROVE_LATTICE);
output.accept(BAMBOO_LATTICE);
output.accept(CHERRY_LATTICE);

output.accept(OAK_BALUSTRADE);
output.accept(SPRUCE_BALUSTRADE);
output.accept(BIRCH_BALUSTRADE);
output.accept(JUNGLE_BALUSTRADE);
output.accept(ACACIA_BALUSTRADE);
output.accept(DARK_OAK_BALUSTRADE);
output.accept(CRIMSON_BALUSTRADE);
output.accept(WARPED_BALUSTRADE);
output.accept(MANGROVE_BALUSTRADE);
output.accept(BAMBOO_BALUSTRADE);
output.accept(CHERRY_BALUSTRADE);

output.accept(STONE_FRAME);
output.accept(BLACKSTONE_FRAME);
Expand Down
22 changes: 22 additions & 0 deletions src/main/java/com/starfish_studios/bbb/registry/BBBItems.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,35 @@

public class BBBItems {

/// Oak, Spruce, Birch, Jungle, Acacia, Dark Oak, Crimson, Warped, Mangrove, Bamboo, Cherry

public static final Item CORNERSTONE = register("bbb", new Item(new FabricItemSettings().maxCount(1).rarity(Rarity.UNCOMMON).fireproof()));
public static final Item HAMMER = register("hammer", new HammerItem(new FabricItemSettings().maxCount(1).durability(256)));
public static final Item CHISEL = register("chisel", new Item(new FabricItemSettings().maxCount(1).durability(256)));

public static final Item OAK_BALUSTRADE = register("oak_balustrade", new DescriptionBlockItem(BBBBlocks.OAK_BALUSTRADE, new FabricItemSettings()));
public static final Item SPRUCE_BALUSTRADE = register("spruce_balustrade", new DescriptionBlockItem(BBBBlocks.SPRUCE_BALUSTRADE, new FabricItemSettings()));
public static final Item BIRCH_BALUSTRADE = register("birch_balustrade", new DescriptionBlockItem(BBBBlocks.BIRCH_BALUSTRADE, new FabricItemSettings()));
public static final Item JUNGLE_BALUSTRADE = register("jungle_balustrade", new DescriptionBlockItem(BBBBlocks.JUNGLE_BALUSTRADE, new FabricItemSettings()));
public static final Item ACACIA_BALUSTRADE = register("acacia_balustrade", new DescriptionBlockItem(BBBBlocks.ACACIA_BALUSTRADE, new FabricItemSettings()));
public static final Item DARK_OAK_BALUSTRADE = register("dark_oak_balustrade", new DescriptionBlockItem(BBBBlocks.DARK_OAK_BALUSTRADE, new FabricItemSettings()));
public static final Item CRIMSON_BALUSTRADE = register("crimson_balustrade", new DescriptionBlockItem(BBBBlocks.CRIMSON_BALUSTRADE, new FabricItemSettings()));
public static final Item WARPED_BALUSTRADE = register("warped_balustrade", new DescriptionBlockItem(BBBBlocks.WARPED_BALUSTRADE, new FabricItemSettings()));
public static final Item MANGROVE_BALUSTRADE = register("mangrove_balustrade", new DescriptionBlockItem(BBBBlocks.MANGROVE_BALUSTRADE, new FabricItemSettings()));
public static final Item BAMBOO_BALUSTRADE = register("bamboo_balustrade", new DescriptionBlockItem(BBBBlocks.BAMBOO_BALUSTRADE, new FabricItemSettings()));
public static final Item CHERRY_BALUSTRADE = register("cherry_balustrade", new DescriptionBlockItem(BBBBlocks.CHERRY_BALUSTRADE, new FabricItemSettings()));

public static final Item OAK_LATTICE = register("oak_lattice", new DescriptionBlockItem(BBBBlocks.OAK_LATTICE, new FabricItemSettings()));
public static final Item SPRUCE_LATTICE = register("spruce_lattice", new DescriptionBlockItem(BBBBlocks.SPRUCE_LATTICE, new FabricItemSettings()));
public static final Item BIRCH_LATTICE = register("birch_lattice", new DescriptionBlockItem(BBBBlocks.BIRCH_LATTICE, new FabricItemSettings()));
public static final Item JUNGLE_LATTICE = register("jungle_lattice", new DescriptionBlockItem(BBBBlocks.JUNGLE_LATTICE, new FabricItemSettings()));
public static final Item ACACIA_LATTICE = register("acacia_lattice", new DescriptionBlockItem(BBBBlocks.ACACIA_LATTICE, new FabricItemSettings()));
public static final Item DARK_OAK_LATTICE = register("dark_oak_lattice", new DescriptionBlockItem(BBBBlocks.DARK_OAK_LATTICE, new FabricItemSettings()));
public static final Item CRIMSON_LATTICE = register("crimson_lattice", new DescriptionBlockItem(BBBBlocks.CRIMSON_LATTICE, new FabricItemSettings()));
public static final Item WARPED_LATTICE = register("warped_lattice", new DescriptionBlockItem(BBBBlocks.WARPED_LATTICE, new FabricItemSettings()));
public static final Item MANGROVE_LATTICE = register("mangrove_lattice", new DescriptionBlockItem(BBBBlocks.MANGROVE_LATTICE, new FabricItemSettings()));
public static final Item BAMBOO_LATTICE = register("bamboo_lattice", new DescriptionBlockItem(BBBBlocks.BAMBOO_LATTICE, new FabricItemSettings()));
public static final Item CHERRY_LATTICE = register("cherry_lattice", new DescriptionBlockItem(BBBBlocks.CHERRY_LATTICE, new FabricItemSettings()));

public static final Item STONE_BLOCK = Items.registerBlock(new StandingAndWallBlockItem(BBBBlocks.STONE_BLOCK, BBBBlocks.WALL_STONE_BLOCK, new Item.Properties(), Direction.DOWN));
public static final Item BLACKSTONE_BLOCK = Items.registerBlock(new StandingAndWallBlockItem(BBBBlocks.BLACKSTONE_BLOCK, BBBBlocks.WALL_BLACKSTONE_BLOCK, new Item.Properties(), Direction.DOWN));
Expand Down
153 changes: 153 additions & 0 deletions src/main/resources/assets/bbb/blockstates/acacia_balustrade.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,153 @@
{
"multipart": [
{
"apply": {
"model": "bbb:block/balustrade/acacia_beam",
"uvlock": true
}
},
{
"when": {
"top": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_beam_top",
"uvlock": true
}
},
{
"when": {
"bottom": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_beam_bottom",
"uvlock": true
}
},
{
"when": {
"top": "true",
"facing": "north",
"tilted": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top"
}
},
{
"when": {
"top": "true",
"facing": "east",
"tilted": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top",
"y": 90
}
},
{
"when": {
"top": "true",
"facing": "south",
"tilted": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top",
"y": 180
}
},
{
"when": {
"top": "true",
"facing": "west",
"tilted": "false"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top",
"y": 270
}
},
{
"when": {
"top": "true",
"facing": "north",
"tilted": "true"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top_tilted"
}
},
{
"when": {
"top": "true",
"facing": "east",
"tilted": "true"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top_tilted",
"y": 90
}
},
{
"when": {
"top": "true",
"facing": "south",
"tilted": "true"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top_tilted",
"y": 180
}
},
{
"when": {
"top": "true",
"facing": "west",
"tilted": "true"
},
"apply": {
"model": "bbb:block/balustrade/acacia_top_tilted",
"y": 270
}
},
{
"when": {
"bottom": "true",
"facing": "north"
},
"apply": {
"model": "bbb:block/balustrade/acacia_bottom"
}
},
{
"when": {
"bottom": "true",
"facing": "east"
},
"apply": {
"model": "bbb:block/balustrade/acacia_bottom",
"y": 90
}
},
{
"when": {
"bottom": "true",
"facing": "south"
},
"apply": {
"model": "bbb:block/balustrade/acacia_bottom",
"y": 180
}
},
{
"when": {
"bottom": "true",
"facing": "west"
},
"apply": {
"model": "bbb:block/balustrade/acacia_bottom",
"y": 270
}
}
]
}
Loading

0 comments on commit a530e02

Please sign in to comment.