Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
8673af3
Fix Cosmic Ray Detector
Johny709 Dec 23, 2025
6d713d3
Fix Stellar Forge and add voltage casings to it
Johny709 Dec 23, 2025
b13e13e
Fix Bio Reactor voltage casings
Johny709 Dec 23, 2025
9dd3f09
Fix Plasma Condenser voltage casings
Johny709 Dec 23, 2025
f4953f7
Fix Cosmic Ray Detector voltage casings
Johny709 Dec 23, 2025
b482b7c
Fix Chemical Plant and add coil bonus
Johny709 Dec 24, 2025
79be57f
Turn on distinct mode
Johny709 Dec 24, 2025
9ca36d0
Add tooltips
Johny709 Dec 24, 2025
a2820fa
Fix Deep Miner and implement voltage casings, and breaking blocks to …
Johny709 Dec 24, 2025
8e0f0e1
Add fluid bars to Void Miner UI
Johny709 Dec 24, 2025
f5b339b
Volcanus progress
Johny709 Dec 24, 2025
86e7229
Cryogenic Freezer progress
Johny709 Dec 24, 2025
5a44068
Add Tiered Hatch (voltage casings) predicates to JEI multi preview
Johny709 Dec 24, 2025
29ab9e9
Fix Decay Chamber voltage casings
Johny709 Dec 25, 2025
b9343a5
Match Greenhouse texture and casings
Johny709 Dec 25, 2025
1cb0576
Add extra pages to JEI multiblock previews with multis with different…
Johny709 Dec 25, 2025
5ae38e0
Fix Cosmic Ray Detector not forming
Johny709 Dec 25, 2025
81479ba
Fix Adv Centrifuge voltage casings
Johny709 Dec 25, 2025
4480bb8
Fix Adv Mixer voltage casings
Johny709 Dec 25, 2025
8f8c3a0
Add lasers to Component Assembly Line
Johny709 Dec 26, 2025
f5ec1ee
finish volcanus and cryo freezer logic.
Johny709 Jan 16, 2026
b42857d
fix volcanus and cryo freezer oc not working and add config to set ma…
Johny709 Jan 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -166,4 +166,4 @@ deploymentDebug = false
org.gradle.logging.stacktrace = all
# Sets default memory used for gradle commands. Can be overridden by user or command line properties.
# This is required to provide enough memory for the Minecraft decompilation process.
org.gradle.jvmargs = -Xmx8G
#org.gradle.jvmargs = -Xmx8G
9 changes: 9 additions & 0 deletions src/main/java/com/fulltrix/gcyl/GCYLConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,15 @@ public static class Misc {
@Config.Comment("Efficiency level for the LuV rocket engine")
public int LuVRocketEfficiency= 25;

@Config.Comment("Set the max overclocking voltage for Volcanus. LV = 1, MV = 2, HV = 3 etc. Set to 0 for no limit.")
@Config.Name("Volcanus Max Voltage")
@Config.RequiresMcRestart
public int volcanusMaxVoltage = GTValues.ZPM;

@Config.Comment("Set the max overclocking voltage for Cryogenic Freezer. LV = 1, MV = 2, HV = 3 etc. Set to 0 for no limit.")
@Config.Name("Cryogenic Freezer Max Voltage")
@Config.RequiresMcRestart
public int cryogenicFreezerMaxVoltage = GTValues.ZPM;
}


Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
package com.fulltrix.gcyl.api.multi;

import com.cleanroommc.modularui.api.drawable.IKey;
import com.cleanroommc.modularui.screen.RichTooltip;
import com.cleanroommc.modularui.value.sync.StringSyncValue;
import gregicality.multiblocks.api.capability.impl.GCYMMultiblockRecipeLogic;
import gregicality.multiblocks.api.metatileentity.GCYMMultiblockAbility;
import gregicality.multiblocks.api.metatileentity.GCYMRecipeMapMultiblockController;
import gregtech.api.capability.IMultipleTankHandler;
import gregtech.api.metatileentity.multiblock.ui.MultiblockUIBuilder;
import gregtech.api.mui.sync.FixedIntArraySyncValue;
import gregtech.api.pattern.TraceabilityPredicate;
import gregtech.api.recipes.RecipeMap;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import org.jetbrains.annotations.NotNull;

public abstract class GCYLRecipeMapMultiblockController extends GCYMRecipeMapMultiblockController {
Expand All @@ -23,6 +32,53 @@ public GCYLRecipeMapMultiblockController(ResourceLocation metaTileEntityId, Reci
this.isParallel = isParallel;
}

@Override
protected void configureDisplayText(MultiblockUIBuilder builder) {
super.configureDisplayText(builder);
builder.addRecipeOutputLine(this.recipeMapWorkable).addEmptyLine();
}

protected int[] getTotalFluidAmount(FluidStack testStack, IMultipleTankHandler multiTank) {
int fluidAmount = 0;
int fluidCapacity = 0;
for (var tank : multiTank) {
if (tank != null) {
FluidStack drainStack = tank.drain(testStack, false);
if (drainStack != null && drainStack.amount > 0) {
fluidAmount += drainStack.amount;
fluidCapacity += tank.getCapacity();
}
}
}
return new int[] { fluidAmount, fluidCapacity };
}

/**
* @param tooltip the tooltip to populate
* @param amounts the sync value containing an array of [fuel stored, fuel capacity]
* @param fuelNameValue the name of the fuel
*/
protected void createFuelTooltip(@NotNull RichTooltip tooltip, @NotNull FixedIntArraySyncValue amounts,
@NotNull StringSyncValue fuelNameValue) {
if (isStructureFormed()) {
Fluid fluid = fuelNameValue.getStringValue() == null ? null :
FluidRegistry.getFluid(fuelNameValue.getStringValue());
if (fluid == null) {
tooltip.addLine(IKey.lang("gregtech.multiblock.large_combustion_engine.fuel_none"));
} else {
tooltip.addLine(
IKey.lang("gregtech.multiblock.large_combustion_engine.fuel_amount", amounts.getValue(0),
amounts.getValue(1), fluid.getLocalizedName(new FluidStack(fluid, 1))));
}
} else {
tooltip.addLine(IKey.lang("gregtech.multiblock.invalid_structure"));
}
}

@Override
public boolean canBeDistinct() {
return true;
}

@Override
public boolean isTiered() { return true; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,22 @@
import com.fulltrix.gcyl.blocks.GCYLMetaBlocks;
import com.fulltrix.gcyl.blocks.component_al.GCYLComponentALCasing;
import com.fulltrix.gcyl.blocks.fusion.GCYLFusionCoils;
import com.fulltrix.gcyl.blocks.metal.GCYLCleanroomCasing;
import gregicality.multiblocks.api.metatileentity.GCYMMultiblockAbility;
import gregicality.multiblocks.common.metatileentities.multiblockpart.MetaTileEntityTieredHatch;
import gregtech.api.GregTechAPI;
import gregtech.api.block.ICleanroomFilter;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.MetaTileEntityHolder;
import gregtech.api.metatileentity.multiblock.MultiblockAbility;
import gregtech.api.pattern.PatternStringError;
import gregtech.api.pattern.TraceabilityPredicate;
import gregtech.api.util.BlockInfo;
import gregtech.common.blocks.BlockCleanroomCasing;
import gregtech.common.blocks.MetaBlocks;
import groovyjarjarantlr4.runtime.misc.IntArray;
import net.minecraft.block.Block;
import net.minecraft.block.state.IBlockState;
import org.apache.commons.lang3.ArrayUtils;

import java.util.Arrays;
import java.util.Comparator;
import java.util.LinkedList;
import java.util.*;
import java.util.function.Supplier;

public class TraceabilityPredicates {
Expand Down Expand Up @@ -59,6 +60,9 @@ public class TraceabilityPredicates {
return false;
}
blockWorldState.getMatchContext().getOrPut("VABlock", new LinkedList<>()).add(blockWorldState.getPos());

IntArray bonus = blockWorldState.getMatchContext().getOrCreate("filtered_casings_speed", IntArray::new);
bonus.add(currentFilter.getTier() * 5);
return true;
}

Expand Down Expand Up @@ -131,6 +135,56 @@ public class TraceabilityPredicates {
.toArray(BlockInfo[]::new))
.addTooltips("gcyl.multiblock.pattern.error.elevator_motor_tier");

public static TraceabilityPredicate tieredHatchPredicate() {
return new TraceabilityPredicate(blockWorldState -> {
if (blockWorldState.getTileEntity() instanceof MetaTileEntityHolder holder) {
MetaTileEntity tileEntity = holder.getMetaTileEntity();
if (tileEntity instanceof MetaTileEntityTieredHatch tieredHatch) {
List<MetaTileEntityTieredHatch> tieredHatches = blockWorldState.getMatchContext().getOrCreate("tiered_hatches", ArrayList::new);
tieredHatches.add(tieredHatch);
return tieredHatches.get(0).getTier() == tieredHatch.getTier();
}
}
return false;
}, () -> MultiblockAbility.REGISTRY.get(GCYMMultiblockAbility.TIERED_HATCH).stream()
.map(tileEntity -> {
MetaTileEntityHolder holder = new MetaTileEntityHolder();
holder.setMetaTileEntity(tileEntity);
holder.getMetaTileEntity().onPlacement();
return new BlockInfo(tileEntity.getBlock().getDefaultState(), holder);
}).toArray(BlockInfo[]::new));
}

public static TraceabilityPredicate componentAssemblyLineCasingPredicate() {
return new TraceabilityPredicate(blockWorldState -> {
if (blockWorldState.getBlockState().getBlock() instanceof GCYLComponentALCasing componentALCasing) {
GCYLComponentALCasing.CasingType casingType = componentALCasing.getState(blockWorldState.getBlockState());
List<GCYLComponentALCasing.CasingType> casingTypes = blockWorldState.getMatchContext().getOrCreate("componentAssemblyLineCasings", ArrayList::new);
casingTypes.add(casingType);
return casingTypes.get(0).getTier() == casingType.getTier();
}
return false;
}, () -> Arrays.stream(GCYLComponentALCasing.CasingType.values())
.sorted(Comparator.comparingInt(GCYLComponentALCasing.CasingType::getTier))
.map(entry -> new BlockInfo(GCYLMetaBlocks.GCYL_COMPONENT_AL_CASING.getState(entry)))
.toArray(BlockInfo[]::new));
}

public static TraceabilityPredicate filterCasingPredicate() {
return new TraceabilityPredicate(blockWorldState -> {
ICleanroomFilter filter;
if ((filter = GCYLAPI.GCYL_FILTER_CASINGS.get(blockWorldState.getBlockState())) != null) {
List<ICleanroomFilter> filters = blockWorldState.getMatchContext().getOrCreate("filterCasings", ArrayList::new);
filters.add(filter);
return filters.get(0).getCleanroomType() == filter.getCleanroomType();
}
return false;
}, () -> GCYLAPI.GCYL_FILTER_CASINGS.entrySet().stream()
.sorted(Comparator.comparingInt(entry -> entry.getValue().getTier()))
.map(entry -> new BlockInfo(entry.getKey()))
.toArray(BlockInfo[]::new));
}

public static TraceabilityPredicate advFusionCoils() {
return ADV_FUSION_COIL_PRED.get();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public static void init() {
HYPER_REACTOR[1] = registerMetaTileEntity(++id, new MetaTileEntityHyperReactor(gcylId("hyper_reactor.ii"), GTUtility.getTierByVoltage(GCYLConfig.multis.hyperReactors.euGeneration[1])));
HYPER_REACTOR[2] = registerMetaTileEntity(++id, new MetaTileEntityHyperReactor(gcylId("hyper_reactor.iii"), GTUtility.getTierByVoltage(GCYLConfig.multis.hyperReactors.euGeneration[2])));

PLASMA_CONDENSER = registerMetaTileEntity(++id, new MetaTileEntityPlasmaCondenser(gcylId("plasma_condenser"), false));
PLASMA_CONDENSER = registerMetaTileEntity(++id, new MetaTileEntityPlasmaCondenser(gcylId("plasma_condenser")));

ADVANCED_MIXER = registerMetaTileEntity(++id, new MetaTileEntityAdvMixer(gcylId("large_mixer")));

Expand Down
Original file line number Diff line number Diff line change
@@ -1,39 +1,73 @@
package com.fulltrix.gcyl.machines.multi;

import com.fulltrix.gcyl.api.multi.GCYLMultiblockRecipeLogic;
import com.fulltrix.gcyl.api.multi.GCYLRecipeMapMultiblockController;
import com.fulltrix.gcyl.api.pattern.TraceabilityPredicates;
import com.fulltrix.gcyl.client.ClientHandler;
import com.fulltrix.gcyl.blocks.GCYLMetaBlocks;
import com.fulltrix.gcyl.blocks.GCYLMultiblockCasing2;
import com.fulltrix.gcyl.api.recipes.GCYLRecipeMaps;
import gregicality.multiblocks.common.GCYMConfigHolder;
import gregicality.multiblocks.common.metatileentities.GCYMMetaTileEntities;
import gregicality.multiblocks.common.metatileentities.multiblockpart.MetaTileEntityTieredHatch;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.interfaces.IGregTechTileEntity;
import gregtech.api.metatileentity.multiblock.IMultiblockPart;
import gregtech.api.pattern.BlockPattern;
import gregtech.api.pattern.FactoryBlockPattern;
import gregtech.api.pattern.MultiblockShapeInfo;
import gregtech.api.pattern.PatternMatchContext;
import gregtech.client.renderer.ICubeRenderer;
import gregtech.client.renderer.texture.cube.OrientedOverlayRenderer;
import gregtech.common.blocks.BlockGlassCasing;
import gregtech.common.blocks.MetaBlocks;
import gregtech.common.metatileentities.MetaTileEntities;
import net.minecraft.block.state.IBlockState;
import net.minecraft.client.resources.I18n;
import net.minecraft.item.ItemStack;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.ResourceLocation;
import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import org.jetbrains.annotations.Nullable;

import javax.annotation.Nonnull;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;

import static gregtech.api.util.RelativeDirection.*;

public class MetaTileEntityBioReactor extends GCYLRecipeMapMultiblockController {

private long maxVoltage;

public MetaTileEntityBioReactor(ResourceLocation metaTileEntityId) {
super(metaTileEntityId, GCYLRecipeMaps.BIO_REACTOR_RECIPES, false);
this.recipeMapWorkable = new GCYLMultiblockRecipeLogic(this, false) {
@Override
public long getMaxVoltage() {
return GCYMConfigHolder.globalMultiblocks.enableTieredCasings ? maxVoltage : super.getMaxVoltage();
}
};
}

@Override
@SideOnly(Side.CLIENT)
public void addInformation(ItemStack stack, @Nullable World player, List<String> tooltip, boolean advanced) {
super.addInformation(stack, player, tooltip, advanced);
tooltip.add(I18n.format("gcyl.multiblock.bio_reactor.description"));
}

@Override
public MetaTileEntity createMetaTileEntity(IGregTechTileEntity iGregTechTileEntity) {
return new MetaTileEntityBioReactor(metaTileEntityId);
}

public long maxVoltage = 0;

@Override
protected BlockPattern createStructurePattern() { //TODO: add tiered casings
protected BlockPattern createStructurePattern() {
return FactoryBlockPattern.start()
.aisle("XXXXX", "XGGGX", "XGGGX", "XGGGX", "XXXXX")
.aisle("XXXXX", "G###G", "G#T#G", "G###G", "XXXXX")
Expand All @@ -45,10 +79,41 @@ protected BlockPattern createStructurePattern() { //TODO: add tiered casings
.where('L', states(getCasingState()))
.where('#', air())
.where('G', states(MetaBlocks.TRANSPARENT_CASING.getState(BlockGlassCasing.CasingType.LAMINATED_GLASS)))
.where('T', tieredCasing())
.where('T', TraceabilityPredicates.tieredHatchPredicate())
.build();
}

@Override
public List<MultiblockShapeInfo> getMatchingShapes() {
MultiblockShapeInfo.Builder builder = MultiblockShapeInfo.builder(RIGHT, DOWN, FRONT)
.aisle("XXEMX", "XGGGX", "XGGGX", "XGGGX", "XXXXX")
.aisle("XXXXX", "G###G", "G#T#G", "G###G", "XXXXX")
.aisle("XXXXX", "G#T#G", "GTTTG", "G#T#G", "XXXXX")
.aisle("XXXXX", "G###G", "G#T#G", "G###G", "XXXXX")
.aisle("iISOo", "XGGGX", "XGGGX", "XGGGX", "XXXXX")
.where('S', this, EnumFacing.SOUTH)
.where('I', MetaTileEntities.ITEM_IMPORT_BUS[3], EnumFacing.SOUTH)
.where('O', MetaTileEntities.ITEM_EXPORT_BUS[3], EnumFacing.SOUTH)
.where('i', MetaTileEntities.FLUID_IMPORT_HATCH[3], EnumFacing.SOUTH)
.where('o', MetaTileEntities.FLUID_EXPORT_HATCH[3], EnumFacing.SOUTH)
.where('M', MetaTileEntities.MAINTENANCE_HATCH, EnumFacing.NORTH)
.where('X', this.getCasingState())
.where('L', this.getCasingState())
.where('G', MetaBlocks.TRANSPARENT_CASING.getState(BlockGlassCasing.CasingType.LAMINATED_GLASS));
return Arrays.stream(GCYMMetaTileEntities.TIERED_HATCH)
.map(hatch -> builder.where('T', hatch, EnumFacing.DOWN)
.where('E', MetaTileEntities.ENERGY_INPUT_HATCH[hatch.getTier()], EnumFacing.NORTH)
.build())
.collect(Collectors.toList());
}

@Override
protected void formStructure(PatternMatchContext context) {
super.formStructure(context);
int tier = context.getOrDefault("tiered_hatches", new ArrayList<MetaTileEntityTieredHatch>()).get(0).getTier() - 1;
this.maxVoltage = 32L << tier * 2;
}

@Override
public void invalidateStructure() {
super.invalidateStructure();
Expand Down
Loading