Skip to content

Commit

Permalink
v1.3.9 [ 1.20.2 ]
Browse files Browse the repository at this point in the history
changelog: see changelog.md
  • Loading branch information
sa-shiro committed Oct 15, 2023
1 parent 690f2c7 commit 528c939
Show file tree
Hide file tree
Showing 53 changed files with 2,092 additions and 305 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# certain platforms or Java versions, and provides a first line of defence
# against bad commits.

run-name: "v1.3.8 - 1.20.2"
run-name: "v1.3.9 - 1.20.2"

name: build
on: [ push, pull_request, workflow_dispatch ]
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
# certain platforms or Java versions, and provides a first line of defence
# against bad commits.

run-name: "release: v1.3.8 - 1.20.2"
run-name: "release: v1.3.9 - 1.20.2"

name: publish
on: workflow_dispatch

env:
VERSION: 1.3.8
VERSION: 1.3.9
MC_VERSION: "1.20.2"
MC_VERSION_RANGE: |
1.20
Expand Down
5 changes: 3 additions & 2 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
# v1.3.8 [ 1.20.2 ]
# v1.3.9 [ 1.20.2 ]

## General

- Added the forgotten Copper Blocks
- Fix Copper Blocks textures (fixes #38)
- Add Bone Block
- Compatible with: `[ 1.20, 1.20.1, 1.20.2 ]`

---
Expand Down
335 changes: 174 additions & 161 deletions common/src/main/java/net/sashiro/compressedblocks/block/BlockList.java

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -204,19 +204,4 @@ public void appendHoverText(@NotNull ItemStack is, @Nullable BlockGetter bg, @No
lC.add(Component.literal(compressor.getBlockCount() + " Blocks").withStyle(compressor.getStyle()));
}
}

public static class CustomWeatheringCopperBlock extends WeatheringCopperFullBlock {
private final Compression compressor = new Compression();

public CustomWeatheringCopperBlock(WeatherState weatherState, Properties properties, int compressionLevel) {
super(weatherState, properties);
compressor.setCompressionLevel(compressionLevel);
}

@Override
public void appendHoverText(@NotNull ItemStack is, @Nullable BlockGetter bg, @NotNull List<Component> lC, @NotNull TooltipFlag ttf) {
super.appendHoverText(is, bg, lC, ttf);
lC.add(Component.literal(compressor.getBlockCount() + " Blocks").withStyle(compressor.getStyle()));
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,17 @@ public static String stringFormat(String formatString) {
}
return stringFormat.toString().trim();
}

/**
* Utility function to remove the index of compressed Items & Blocks
* @param name of the Item / Block.
* @return actual Block name.
*/
public static String removeCompressionName(String name) {
for (int i = 0; i < 10; i++) {
if (name.contains("c" + i))
name = name.replace("c" + i + "_", "");
}
return name;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c0_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c0_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c0_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c1_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c1_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c1_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c2_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c2_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c2_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c3_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c3_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c3_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c4_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c4_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c4_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c5_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c5_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c5_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c6_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c6_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c6_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c7_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c7_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c7_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c8_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c8_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c8_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"variants": {
"axis=x": {
"model": "compressedblocks:block/c9_bone_block_horizontal",
"x": 90,
"y": 90
},
"axis=y": {
"model": "compressedblocks:block/c9_bone_block"
},
"axis=z": {
"model": "compressedblocks:block/c9_bone_block_horizontal",
"x": 90
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
{
"parent": "minecraft:block/cube_column",
"elements": [
{
"faces": {
"down": {
"texture": "#end"
},
"east": {
"texture": "#side"
},
"north": {
"texture": "#side"
},
"south": {
"texture": "#side"
},
"up": {
"texture": "#end"
},
"west": {
"texture": "#side"
}
},
"from": [
0,
0,
0
],
"to": [
16,
16,
16
]
},
{
"faces": {
"down": {
"texture": "#overlay"
},
"east": {
"texture": "#overlay"
},
"north": {
"texture": "#overlay"
},
"south": {
"texture": "#overlay"
},
"up": {
"texture": "#overlay"
},
"west": {
"texture": "#overlay"
}
},
"from": [
0,
0,
0
],
"to": [
16,
16,
16
]
}
],
"render_type": "minecraft:translucent",
"textures": {
"end": "minecraft:block/bone_block_top",
"overlay": "compressedblocks:block/compression_level_0",
"particle": "minecraft:block/bone_block_side",
"side": "minecraft:block/bone_block_side"
}
}
Loading

0 comments on commit 528c939

Please sign in to comment.