From 8be2bab29a14811e78b2027db790b1823e5761ca Mon Sep 17 00:00:00 2001 From: screret <68943070+screret@users.noreply.github.com> Date: Sun, 5 May 2024 19:30:29 +0300 Subject: [PATCH] fix laser & optical pipes not dropping anything (#1197) --- .../loot_tables/blocks/normal_laser_pipe.json | 21 +++++++++++++++++++ .../blocks/normal_optical_pipe.json | 21 +++++++++++++++++++ .../gtceu/common/data/GTBlocks.java | 4 ++-- 3 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 src/generated/resources/data/gtceu/loot_tables/blocks/normal_laser_pipe.json create mode 100644 src/generated/resources/data/gtceu/loot_tables/blocks/normal_optical_pipe.json diff --git a/src/generated/resources/data/gtceu/loot_tables/blocks/normal_laser_pipe.json b/src/generated/resources/data/gtceu/loot_tables/blocks/normal_laser_pipe.json new file mode 100644 index 0000000000..d14a70d62b --- /dev/null +++ b/src/generated/resources/data/gtceu/loot_tables/blocks/normal_laser_pipe.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "gtceu:normal_laser_pipe" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "gtceu:blocks/normal_laser_pipe" +} \ No newline at end of file diff --git a/src/generated/resources/data/gtceu/loot_tables/blocks/normal_optical_pipe.json b/src/generated/resources/data/gtceu/loot_tables/blocks/normal_optical_pipe.json new file mode 100644 index 0000000000..40b990e301 --- /dev/null +++ b/src/generated/resources/data/gtceu/loot_tables/blocks/normal_optical_pipe.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "gtceu:normal_optical_pipe" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "gtceu:blocks/normal_optical_pipe" +} \ No newline at end of file diff --git a/src/main/java/com/gregtechceu/gtceu/common/data/GTBlocks.java b/src/main/java/com/gregtechceu/gtceu/common/data/GTBlocks.java index 960b3ef4fa..02125e13b0 100644 --- a/src/main/java/com/gregtechceu/gtceu/common/data/GTBlocks.java +++ b/src/main/java/com/gregtechceu/gtceu/common/data/GTBlocks.java @@ -383,7 +383,7 @@ private static void registerLaserPipeBlock(int index) { var type = LaserPipeType.values()[index]; var entry = REGISTRATE.block("%s_laser_pipe".formatted(type.getSerializedName()), (p) -> new LaserPipeBlock(p, type)) .initialProperties(() -> Blocks.IRON_BLOCK) - .properties(p -> p.dynamicShape().noOcclusion().noLootTable()) + .properties(p -> p.dynamicShape().noOcclusion()) .blockstate(NonNullBiConsumer.noop()) .defaultLoot() .tag(GTToolType.WIRE_CUTTER.harvestTags.get(0)) @@ -409,7 +409,7 @@ private static void registerOpticalPipeBlock(int index) { var type = OpticalPipeType.values()[index]; var entry = REGISTRATE.block("%s_optical_pipe".formatted(type.getSerializedName()), (p) -> new OpticalPipeBlock(p, type)) .initialProperties(() -> Blocks.IRON_BLOCK) - .properties(p -> p.dynamicShape().noOcclusion().noLootTable()) + .properties(p -> p.dynamicShape().noOcclusion()) .blockstate(NonNullBiConsumer.noop()) .defaultLoot() .tag(GTToolType.WIRE_CUTTER.harvestTags.get(0))