From 07db97004e9e32bed59e0201b76b7466876e2754 Mon Sep 17 00:00:00 2001 From: Gustavo <77560533+gustovafing@users.noreply.github.com> Date: Tue, 14 Jul 2026 22:13:24 +1000 Subject: [PATCH 01/23] Update v8 machine migration docs (#5112) --- docs/content/Modpacks/Changes/v8.0.0.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/content/Modpacks/Changes/v8.0.0.md b/docs/content/Modpacks/Changes/v8.0.0.md index af2a7b18ccb..6d4e394dccd 100644 --- a/docs/content/Modpacks/Changes/v8.0.0.md +++ b/docs/content/Modpacks/Changes/v8.0.0.md @@ -15,7 +15,8 @@ Many aspects of the machine classes have been refactored and changed in order to - The `MetaMachineBlockEntity`(MMBE) class has been removed, and `MetaMachine`(MM) is now a BlockEntity. - Most methods and properties of MMBE have been moved onto MM. -- The `IMachineBlockEntity` interface has been removed. Use `MetaMachineBlock` directly instead. +- The `IMachineBlock` interface has been removed. Use `MetaMachineBlock` directly instead. +- The `IMachineBlockEntity` interface has been removed. Use `MetaMachine` directly instead. - Many methods common to all block entities have been moved to the `IGregtechBlockEntity` interface. - Machine instance creation functions have signature `(BlockEntityCreationInfo) -> MetaMachine` instead of `(IMachineBlockEntity) -> MetaMachine` From 8fe56e711d8d0e3c4f959c17629c19a7bcd3da35 Mon Sep 17 00:00:00 2001 From: Jambon123 <68718646+Jambon123@users.noreply.github.com> Date: Wed, 15 Jul 2026 12:15:35 +0100 Subject: [PATCH 02/23] Wiki information on .handleNonMaterialFluids() in Java (#5101) --- ...Prefixes-and-the-power-of-.setIgnored().md | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/docs/content/Modpacks/Materials-and-Elements/TagPrefixes-and-the-power-of-.setIgnored().md b/docs/content/Modpacks/Materials-and-Elements/TagPrefixes-and-the-power-of-.setIgnored().md index 5438349be25..5ab5c122912 100644 --- a/docs/content/Modpacks/Materials-and-Elements/TagPrefixes-and-the-power-of-.setIgnored().md +++ b/docs/content/Modpacks/Materials-and-Elements/TagPrefixes-and-the-power-of-.setIgnored().md @@ -76,3 +76,25 @@ GTCEuStartupEvents.materialModification(event => { // (1) The `Material` for which you are adjusting the TagPrefix must be registered in GTCEu Modern's material registry; if this material is custom, this is done using `GTCEuStartupEvents.registry()`, as depicted in these docs. + + +## What about fluids? + +Fluids are treated differently to items, their inclusion in a material is a property rather than a TagPrefix or MaterialFlag. +This makes replacing the fluid of a material with a fluid that you or another mod have created require a different approach than setIgnored. +The way to do this is using `GTFluids.handleNonMaterialFluids()` which can be found in the [``GTFluids`` class](https://github.com/GregTechCEu/GregTech-Modern/blob/1.20.1/src/main/java/com/gregtechceu/gtceu/common/data/GTFluids.java) + +`GTFluids.handleNonMaterialFluids()` takes in a `Material` and a `Fluid` or `Supplier` to replace the liquid of the material with the provided fluid. +Assure that the material is registered with a liquid before attempting to replace it with your new fluid. An example is below. + +!!! note "This may differ!" + Depending on the way your fluid is registered you may need to change how you pass the `Fluid` argument, check how it is registered in the mod you are working with. + +```java title="ExampleMaterials.java" +public static void register() { + GLUGG_BRINE = new Material.Builder(MyMod.id("glugg_brine")) + .liquid(new FluidBuilder()).buildAndRegister(); + + GTFluids.handleNonMaterialFluids(GLUGG_BRINE, () -> PVFluidRegistry.BRINE_FLUID_SOURCE.get()); +} +``` From fe988f59a5f0403846fa52e3468cc157cd94355b Mon Sep 17 00:00:00 2001 From: TarLaboratories <159147059+TarLaboratories@users.noreply.github.com> Date: Wed, 15 Jul 2026 15:09:34 +0300 Subject: [PATCH 03/23] Fix CM forming after multi refactor (#5091) --- .../api/placeholder/MultiLineComponent.java | 40 ++++- .../gtceu/api/placeholder/Placeholder.java | 11 +- .../api/placeholder/PlaceholderHandler.java | 6 +- .../common/data/machines/GTMultiMachines.java | 6 +- .../item/modules/TextModuleBehaviour.java | 6 + .../electric/CentralMonitorMachine.java | 152 ++++++++++-------- .../gtceu/common/mui/GTByteBufAdapters.java | 5 +- .../mui/factory/CentralMonitorUIFactory.java | 7 +- 8 files changed, 147 insertions(+), 86 deletions(-) diff --git a/src/main/java/com/gregtechceu/gtceu/api/placeholder/MultiLineComponent.java b/src/main/java/com/gregtechceu/gtceu/api/placeholder/MultiLineComponent.java index 156e1ea13c6..25a48d49cc7 100644 --- a/src/main/java/com/gregtechceu/gtceu/api/placeholder/MultiLineComponent.java +++ b/src/main/java/com/gregtechceu/gtceu/api/placeholder/MultiLineComponent.java @@ -1,6 +1,8 @@ package com.gregtechceu.gtceu.api.placeholder; import net.minecraft.ChatFormatting; +import net.minecraft.core.HolderLookup; +import net.minecraft.nbt.*; import net.minecraft.network.chat.*; import com.mojang.serialization.Codec; @@ -177,6 +179,7 @@ public MultiLineComponent withStyle(UnaryOperator