1
0
mirror of https://github.com/p2r3/bareiron.git synced 2025-10-01 23:25:09 +02:00

implement water flow

This commit is contained in:
p2r3
2025-08-26 22:54:48 +03:00
parent aa1334db9e
commit 71737380d5
4 changed files with 120 additions and 8 deletions

View File

@@ -39,6 +39,13 @@ const blockBlacklist = [
const blockWhitelist = [
"air",
"water",
"water_1",
"water_2",
"water_3",
"water_4",
"water_5",
"water_6",
"water_7",
"lava",
"snowy_grass_block",
"mud",
@@ -105,6 +112,12 @@ async function extractItemsAndBlocks () {
const snowyState = entry[1].states.find(c => c.properties.snowy);
blocks["snowy_" + entry[0].replace("minecraft:", "")] = snowyState.id;
}
// Include levels for fluids
if ("fluid" in entry[1].definition) {
for (let i = 1; i <= 7; i ++) {
blocks[entry[0].replace("minecraft:", "") + "_" + i] = defaultState.id + i;
}
}
}
for (const item in itemSource) {
@@ -332,7 +345,8 @@ async function convert () {
const tagBuffer = serializeTags({
"fluid": {
"water": [ 2 ] // source water block
// Water and lava, both flowing and still states
"water": [ 1, 2, 3, 4 ]
},
"block": {
"mineable/pickaxe": [