Compare commits

...

5 Commits

Author SHA1 Message Date
Martin Prokoph
f075629474 compat: Enderscape 2025-07-26 21:15:40 +02:00
Martin Prokoph
cd95bddd6b feat: add support for remaining BetterEnd leaves 2025-07-26 21:06:39 +02:00
Martin Prokoph
773112caad feat: improved model variation 2025-07-26 20:16:41 +02:00
Martin Prokoph
a4cb2cd2a1 clean: remove built pack from repo 2025-07-26 20:07:28 +02:00
Martin Prokoph
f9a84917f0 feat: download packs from any link before compiling 2025-07-26 20:04:26 +02:00
88 changed files with 940 additions and 18 deletions

1
.gitignore vendored
View File

@@ -1,2 +1,3 @@
/.alt
*__pycache__
Better-Leaves-*.zip

Binary file not shown.

View File

@@ -0,0 +1,246 @@
{
"variants": {
"": [
{
"model": "betterend:block/cave_bush_leaves_11"
},
{
"model": "betterend:block/cave_bush_leaves_11",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_11",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_11",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_12"
},
{
"model": "betterend:block/cave_bush_leaves_12",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_12",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_12",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_13"
},
{
"model": "betterend:block/cave_bush_leaves_13",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_13",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_13",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_14"
},
{
"model": "betterend:block/cave_bush_leaves_14",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_14",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_14",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_21"
},
{
"model": "betterend:block/cave_bush_leaves_21",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_21",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_21",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_22"
},
{
"model": "betterend:block/cave_bush_leaves_22",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_22",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_22",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_23"
},
{
"model": "betterend:block/cave_bush_leaves_23",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_23",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_23",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_24"
},
{
"model": "betterend:block/cave_bush_leaves_24",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_24",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_24",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_31"
},
{
"model": "betterend:block/cave_bush_leaves_31",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_31",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_31",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_32"
},
{
"model": "betterend:block/cave_bush_leaves_32",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_32",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_32",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_33"
},
{
"model": "betterend:block/cave_bush_leaves_33",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_33",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_33",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_34"
},
{
"model": "betterend:block/cave_bush_leaves_34",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_34",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_34",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_41"
},
{
"model": "betterend:block/cave_bush_leaves_41",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_41",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_41",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_42"
},
{
"model": "betterend:block/cave_bush_leaves_42",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_42",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_42",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_43"
},
{
"model": "betterend:block/cave_bush_leaves_43",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_43",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_43",
"y": 270
},
{
"model": "betterend:block/cave_bush_leaves_44"
},
{
"model": "betterend:block/cave_bush_leaves_44",
"y": 90
},
{
"model": "betterend:block/cave_bush_leaves_44",
"y": 180
},
{
"model": "betterend:block/cave_bush_leaves_44",
"y": 270
}
]
}
}

View File

@@ -0,0 +1,246 @@
{
"variants": {
"": [
{
"model": "betterend:block/lucernia_leaves_11"
},
{
"model": "betterend:block/lucernia_leaves_11",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_11",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_11",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_12"
},
{
"model": "betterend:block/lucernia_leaves_12",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_12",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_12",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_13"
},
{
"model": "betterend:block/lucernia_leaves_13",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_13",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_13",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_14"
},
{
"model": "betterend:block/lucernia_leaves_14",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_14",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_14",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_21"
},
{
"model": "betterend:block/lucernia_leaves_21",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_21",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_21",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_22"
},
{
"model": "betterend:block/lucernia_leaves_22",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_22",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_22",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_23"
},
{
"model": "betterend:block/lucernia_leaves_23",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_23",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_23",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_24"
},
{
"model": "betterend:block/lucernia_leaves_24",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_24",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_24",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_31"
},
{
"model": "betterend:block/lucernia_leaves_31",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_31",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_31",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_32"
},
{
"model": "betterend:block/lucernia_leaves_32",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_32",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_32",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_33"
},
{
"model": "betterend:block/lucernia_leaves_33",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_33",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_33",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_34"
},
{
"model": "betterend:block/lucernia_leaves_34",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_34",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_34",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_41"
},
{
"model": "betterend:block/lucernia_leaves_41",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_41",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_41",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_42"
},
{
"model": "betterend:block/lucernia_leaves_42",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_42",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_42",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_43"
},
{
"model": "betterend:block/lucernia_leaves_43",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_43",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_43",
"y": 270
},
{
"model": "betterend:block/lucernia_leaves_44"
},
{
"model": "betterend:block/lucernia_leaves_44",
"y": 90
},
{
"model": "betterend:block/lucernia_leaves_44",
"y": 180
},
{
"model": "betterend:block/lucernia_leaves_44",
"y": 270
}
]
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/cave_bush_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/cave_bush_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/cave_bush_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/cave_bush_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/cave_bush_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/cave_bush_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/cave_bush_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/cave_bush_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/cave_bush_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/cave_bush_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/cave_bush_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/cave_bush_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/cave_bush_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/cave_bush_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/cave_bush_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/lucernia_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/lucernia_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/lucernia_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/lucernia_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/lucernia_leaves_2"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/lucernia_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/lucernia_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/lucernia_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/lucernia_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/lucernia_leaves_3"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/lucernia_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "betterend:block/lucernia_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "betterend:block/lucernia_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "betterend:block/lucernia_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "betterend:block/lucernia_leaves_4"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/cave_bush_leaves_1"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "betterend:block/lucernia_leaves_1"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 998 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1000 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1006 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 990 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -22,9 +22,9 @@
}
},
{
"from": [-6.98223, -6, 8.99264],
"to": [25.01777, 22, 8.99264],
"rotation": {"angle": 22.5, "axis": "y", "origin": [9.01041, 8, 9]},
"from": [-6.98223, -7, 8.99264],
"to": [25.01777, 21, 8.99264],
"rotation": {"angle": 22.5, "axis": "y", "origin": [9.01041, 7, 9]},
"faces": {
"north": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0},
"south": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0}

View File

@@ -31,9 +31,9 @@
}
},
{
"from": [-7.98223, -6, 8.00736],
"to": [24.01777, 22, 8.00736],
"rotation": {"angle": -22.5, "axis": "y", "origin": [8.01041, 8, 8]},
"from": [-7.98223, -5, 8.00736],
"to": [24.01777, 23, 8.00736],
"rotation": {"angle": -22.5, "axis": "y", "origin": [8.01041, 9, 8]},
"faces": {
"north": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0},
"south": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0}

View File

@@ -0,0 +1,66 @@
{
"variants": {
"": [
{
"model": "enderscape:block/veiled_leaves1"
},
{
"model": "enderscape:block/veiled_leaves1",
"y": 90
},
{
"model": "enderscape:block/veiled_leaves1",
"y": 180
},
{
"model": "enderscape:block/veiled_leaves1",
"y": 270
},
{
"model": "enderscape:block/veiled_leaves2"
},
{
"model": "enderscape:block/veiled_leaves2",
"y": 90
},
{
"model": "enderscape:block/veiled_leaves2",
"y": 180
},
{
"model": "enderscape:block/veiled_leaves2",
"y": 270
},
{
"model": "enderscape:block/veiled_leaves3"
},
{
"model": "enderscape:block/veiled_leaves3",
"y": 90
},
{
"model": "enderscape:block/veiled_leaves3",
"y": 180
},
{
"model": "enderscape:block/veiled_leaves3",
"y": 270
},
{
"model": "enderscape:block/veiled_leaves4"
},
{
"model": "enderscape:block/veiled_leaves4",
"y": 90
},
{
"model": "enderscape:block/veiled_leaves4",
"y": 180
},
{
"model": "enderscape:block/veiled_leaves4",
"y": 270
}
]
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves",
"textures": {
"all": "enderscape:block/veiled_leaves"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves1",
"textures": {
"all": "enderscape:block/veiled_leaves"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves2",
"textures": {
"all": "enderscape:block/veiled_leaves"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves3",
"textures": {
"all": "enderscape:block/veiled_leaves"
}
}

View File

@@ -0,0 +1,6 @@
{
"parent": "betterleaves:block/leaves4",
"textures": {
"all": "enderscape:block/veiled_leaves"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 948 B

View File

@@ -22,9 +22,9 @@
}
},
{
"from": [-6.98223, -6, 8.99264],
"to": [25.01777, 22, 8.99264],
"rotation": {"angle": 22.5, "axis": "y", "origin": [9.01041, 8, 9]},
"from": [-6.98223, -7, 8.99264],
"to": [25.01777, 21, 8.99264],
"rotation": {"angle": 22.5, "axis": "y", "origin": [9.01041, 7, 9]},
"faces": {
"north": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0},
"south": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0}

View File

@@ -31,9 +31,9 @@
}
},
{
"from": [-7.98223, -6, 8.00736],
"to": [24.01777, 22, 8.00736],
"rotation": {"angle": -22.5, "axis": "y", "origin": [8.01041, 8, 8]},
"from": [-7.98223, -5, 8.00736],
"to": [24.01777, 23, 8.00736],
"rotation": {"angle": -22.5, "axis": "y", "origin": [8.01041, 9, 8]},
"faces": {
"north": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0},
"south": {"uv": [0, 1, 16, 15], "texture": "#all", "tintindex": 0}

View File

@@ -10,7 +10,7 @@ import time
# Local imports
from src.generator import autoGen
from src.download_helper import downloadFromModrinth
from src.download_helper import downloadPack
from src.zip_utils import makeZip
import src.json_utils
@@ -43,7 +43,7 @@ if __name__ == '__main__':
print("https://github.com/TeamMidnightDust/BetterLeavesLite")
print()
if args.minify: src.json_utils.minify = True
if args.download != None: downloadFromModrinth(args.download)
if args.download != None: downloadPack(args.download)
# Loads overrides from the json file
f = open('./input/overrides.json')

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:cave_bush",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 213 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:cave_bush",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 243 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:cave_bush",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 252 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:cave_bush",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 248 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:lucernia_leaves",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 216 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:lucernia_leaves",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:lucernia_leaves",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 227 B

View File

@@ -0,0 +1,6 @@
{
"blockStateData": {
"block": "betterend:lucernia_leaves",
"state": ""
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 243 B

View File

@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2021 bunten
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Binary file not shown.

After

Width:  |  Height:  |  Size: 526 B

View File

@@ -72,6 +72,8 @@
"betterend:dragon_tree_leaves",
"betterend:pythadendron_leaves",
"betterend:shadow_berry_leaves",
"betterend:lucernia_leaves_1",
"betterend:cave_bush_leaves_1",
"ars_elemental:yellow_archwood_leaves"
],
"blockStateCopies": {

View File

@@ -1,18 +1,28 @@
from os import path
from tqdm import tqdm
import requests
import re
def downloadPack(input: str):
if re.search("(http://*)|(https://*)", input) != None and input.endswith(".zip"):
downloadZip(input)
else:
downloadFromModrinth(input)
def downloadFromModrinth(project_slug):
response = requests.get(f'https://api.modrinth.com/v2/project/{project_slug}/version')
latestFile = response.json()[0]['files'][0]
latestFileURL = latestFile['url']
if len(latestFileURL) < 1: raise Exception(f'Could not get the latest version URL for {project_slug}')
downloadZip(latestFileURL, file_name=latestFile['filename'], pack_name=project_slug)
download_stream = requests.get(latestFileURL, stream=True)
file_name = latestFile['filename']
def downloadZip(url, file_name="", pack_name=""):
download_stream = requests.get(url, stream=True)
if file_name == "": file_name = url.split("/")[-1]
if pack_name == "": pack_name = url
file_path = 'input/texturepacks'
print(f'Downloading texturepack: {project_slug} (Latest version: {file_name})')
print(f'Downloading texturepack: {pack_name} (Latest version: {file_name})')
location = path.join(file_path, file_name)
total = int(download_stream.headers.get('content-length', 0))
with open(location, "wb") as handle, tqdm(

View File

@@ -64,6 +64,6 @@ def generateItemModel(leaf):
# Create models folder if it doesn't exist already
os.makedirs("assets/{}/models/item/".format(mod_namespace), exist_ok=True)
item_model_file = f"assets/{mod_namespace}/models/item/{block_name}.json"
item_model_file = f"assets/{mod_namespace}/models/item/{block_name}.json" if (leaf.blockstate_data == None) else f"assets/{leaf.blockstate_data.namespace}/models/item/{leaf.blockstate_data.block_name}.json"
with open(item_model_file, "w") as f:
dumpJson(item_model_data, f)