Skip to content

Commit

Permalink
Merge branch 'master' into cleanup/detrav
Browse files Browse the repository at this point in the history
  • Loading branch information
Dream-Master authored Sep 6, 2024
2 parents ff6cb51 + 4368fe3 commit 7b6d363
Show file tree
Hide file tree
Showing 28 changed files with 791 additions and 59 deletions.
4 changes: 2 additions & 2 deletions dependencies.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ dependencies {
api("com.github.GTNewHorizons:NotEnoughItems:2.6.34-GTNH:dev")
api("com.github.GTNewHorizons:NotEnoughIds:2.1.0:dev")
api("com.github.GTNewHorizons:GTNHLib:0.5.5:dev")
api("com.github.GTNewHorizons:ModularUI:1.2.1:dev")
api("com.github.GTNewHorizons:ModularUI:1.2.2:dev")
api("com.github.GTNewHorizons:ModularUI2:2.1.4-1.7.10:dev")
api("com.github.GTNewHorizons:waila:1.8.1:dev")
api("com.github.GTNewHorizons:Applied-Energistics-2-Unofficial:rv3-beta-450-GTNH:dev")
Expand All @@ -49,7 +49,7 @@ dependencies {

compileOnlyApi('com.github.GTNewHorizons:ThaumicTinkerer:2.10.1:dev')
compileOnlyApi("com.github.GTNewHorizons:Mobs-Info:0.4.6-GTNH:dev")
compileOnlyApi("com.github.GTNewHorizons:Navigator:1.0.6:dev")
compileOnlyApi("com.github.GTNewHorizons:Navigator:1.0.10:dev")
implementation('com.github.GTNewHorizons:Baubles:1.0.4:dev') {transitive=false}
// Required to prevent an older bauble api from Extra Utilities from loading first in the javac classpath
compileOnly('com.github.GTNewHorizons:Baubles:1.0.4:dev') {transitive=false}
Expand Down
16 changes: 2 additions & 14 deletions src/main/java/ggfab/mte/MTEAdvAssLine.java
Original file line number Diff line number Diff line change
Expand Up @@ -715,20 +715,8 @@ public ArrayList<ItemStack> getDataItems(int state) {
if (GTUtility.isStackValid(mInventory[1]) && isCorrectDataItem(mInventory[1], state)) {
rList.add(mInventory[1]);
}
for (MTEHatchDataAccess tHatch : mDataAccessHatches) {
if (tHatch.isValid()) {
for (int i = 0; i < tHatch.getBaseMetaTileEntity()
.getSizeInventory(); i++) {
if (tHatch.getBaseMetaTileEntity()
.getStackInSlot(i) != null && isCorrectDataItem(
tHatch.getBaseMetaTileEntity()
.getStackInSlot(i),
state))
rList.add(
tHatch.getBaseMetaTileEntity()
.getStackInSlot(i));
}
}
for (MTEHatchDataAccess tHatch : filterValidMTEs(mDataAccessHatches)) {
rList.addAll(tHatch.getInventoryItems(stack -> isCorrectDataItem(stack, state)));
}
return rList;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package goodgenerator.blocks.tileEntity;

import static bartworks.util.BWTooltipReference.TT;
import static bartworks.util.BWUtil.ofGlassTieredMixed;
import static com.gtnewhorizon.structurelib.structure.StructureUtility.*;
import static goodgenerator.util.DescTextLocalization.BLUE_PRINT_INFO;
Expand Down Expand Up @@ -340,6 +341,7 @@ protected MultiblockTooltipBuilder createTooltip() {
.addInfo("But gives more parallel with more advanced one.")
.addInfo("It is 100% faster in Normal Mode.")
.addInfo("Imprecise (MK-0) = 16x, MK-I = 32x, MK-II = 64x, MK-III = 128x, MK-IV = 256x")
.addInfo("Supports " + TT + " energy hatches")
.addPollutionAmount(getPollutionPerSecond(null))
.addInfo("The structure is too complex!")
.addInfo(BLUE_PRINT_INFO)
Expand Down
5 changes: 4 additions & 1 deletion src/main/java/gregtech/api/enums/GTValues.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
import gregtech.api.interfaces.internal.IGTMod;
import gregtech.api.interfaces.internal.IGTRecipeAdder;
import gregtech.api.net.IGT_NetworkHandler;
import gregtech.api.util.GTChunkAssociatedData;

/**
* Made for static imports, this Class is just a Helper.
Expand Down Expand Up @@ -657,6 +656,10 @@ public static final class NBT {
+ "Ba"
+ EnumChatFormatting.LIGHT_PURPLE
+ "ps";
public static final String AuthorOmdaCZ = "Author: " + EnumChatFormatting.BLUE
+ "Omda"
+ EnumChatFormatting.RED
+ "CZ";

public static final String AuthorEvgenWarGold = "" + EnumChatFormatting.RED
+ EnumChatFormatting.BOLD
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/gregtech/api/enums/ItemList.java
Original file line number Diff line number Diff line change
Expand Up @@ -1476,6 +1476,10 @@ public enum ItemList implements IItemContainer {
Electromagnet_Tengam,

Machine_Multi_Canner,
Machine_Multi_Solidifier,

Casing_Fluid_Solidifier,
Radiator_Fluid_Solidifier,

Machine_Multi_IndustrialCompressor,
Machine_Multi_HIPCompressor,
Expand Down
6 changes: 6 additions & 0 deletions src/main/java/gregtech/api/enums/Materials.java
Original file line number Diff line number Diff line change
Expand Up @@ -2276,6 +2276,8 @@ private static void initSubTags() {
TengamAttuned,
MaterialsUEVplus.Eternity,
MaterialsUEVplus.MagMatter,
MaterialsUEVplus.Creon,
MaterialsUEVplus.Mellion,
MaterialsUEVplus.HotProtoHalkonite,
MaterialsUEVplus.ProtoHalkonite,
MaterialsUEVplus.HotExoHalkonite,
Expand Down Expand Up @@ -2546,6 +2548,10 @@ private static void disableUnusedHotIngots() {
OrePrefixes.ingotHot.disableComponent(Materials.EnergeticAlloy);
OrePrefixes.ingotHot.disableComponent(Materials.PulsatingIron);
OrePrefixes.ingotHot.disableComponent(Materials.CrudeSteel);
OrePrefixes.ingotHot.disableComponent(MaterialsUEVplus.HotProtoHalkonite);
OrePrefixes.ingotHot.disableComponent(MaterialsUEVplus.ProtoHalkonite);
OrePrefixes.ingotHot.disableComponent(MaterialsUEVplus.HotExoHalkonite);
OrePrefixes.ingotHot.disableComponent(MaterialsUEVplus.ExoHalkonite);
}

/**
Expand Down
1 change: 1 addition & 0 deletions src/main/java/gregtech/api/enums/MetaTileEntityIDs.java
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,7 @@ public enum MetaTileEntityIDs {
CENTRIFUGE_HV(363),
CENTRIFUGE_EV(364),
CENTRIFUGE_IV(365),
MULTI_SOLIDIFIER_CONTROLLER(366),
ELECTROLYSER_LV(371),
ELECTROLYSER_MV(372),
ELECTROLYSER_HV(373),
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/gregtech/api/enums/Textures.java
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,9 @@ public enum BlockIcons implements IIconContainer, Runnable {
OVERLAY_FRONT_EMS_GLOW,
MACHINE_CASING_EMS,

MACHINE_CASING_MS160,
RADIATOR_MS160,

OVERLAY_FRONT_MULTI_CANNER,
OVERLAY_FRONT_MULTI_CANNER_ACTIVE,
OVERLAY_FRONT_MULTI_CANNER_ACTIVE_GLOW,
Expand Down
7 changes: 7 additions & 0 deletions src/main/java/gregtech/common/blocks/BlockCasings10.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ public BlockCasings10() {
GTLanguageManager
.addStringLocalization(getUnlocalizedName() + ".12.name", "Background Radiation Absorbent Casing");

GTLanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Solidifier Casing");
GTLanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Solidifier Radiator");

ItemList.Casing_Electromagnetic_Separator.set(new ItemStack(this, 1, 0));
ItemList.Casing_Laser.set(new ItemStack(this, 1, 1));
ItemList.BlockQuarkContainmentCasing.set(new ItemStack(this, 1, 2));
Expand All @@ -46,6 +49,8 @@ public BlockCasings10() {
ItemList.Heating_Duct_Casing.set(new ItemStack(this, 1, 10));
ItemList.Extreme_Density_Casing.set(new ItemStack(this, 1, 11));
ItemList.Background_Radiation_Casing.set(new ItemStack(this, 1, 12));
ItemList.Casing_Fluid_Solidifier.set(new ItemStack(this, 1, 13));
ItemList.Radiator_Fluid_Solidifier.set(new ItemStack(this, 1, 14));
}

@Override
Expand All @@ -70,6 +75,8 @@ public IIcon getIcon(int ordinalSide, int aMeta) {
case 10 -> Textures.BlockIcons.MACHINE_CASING_PIPE_BRONZE.getIcon();
case 11 -> Textures.BlockIcons.EXTREME_DENSITY_CASING.getIcon();
case 12 -> Textures.BlockIcons.RADIATION_ABSORBENT_CASING.getIcon();
case 13 -> Textures.BlockIcons.MACHINE_CASING_MS160.getIcon();
case 14 -> Textures.BlockIcons.RADIATOR_MS160.getIcon();
default -> Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon();
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,6 @@ public MetaGeneratedItem01() {
OrePrefixes.plateQuadruple,
OrePrefixes.plateQuintuple,
OrePrefixes.plateDense,
OrePrefixes.plateSuperdense,
OrePrefixes.stick,
OrePrefixes.lens,
OrePrefixes.round,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ protected MultiblockTooltipBuilder createTooltip() {
.addInfo("Needs a minimum of 128 Pressure Containment Casings.")
.addInfo(AuthorVolence)
.addSeparator()
.beginStructureBlock(7, 5, 5, true)
.beginStructureBlock(7, 7, 9, true)
.addController("Front Center")
.addCasingInfoMin("Pressure Containment Casings", 128, false)
.addCasingInfoExactly("Item Pipe Casings", 7, true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ public MTEMultiLathe(String aName) {

public enum PipeTiers {

Tin(1, 0.75F),
Brass(1, 0.8F),
Electrum(2, 0.9F),
Platinum(4, 1F),
Osmium(8, 1.25F),
Quantium(12, 1.5F),
Expand All @@ -91,19 +94,22 @@ public enum PipeTiers {
private PipeTiers getPipeData() {
pipeTier = getPipeTier();
return switch (pipeTier) {
case 2 -> PipeTiers.Osmium;
case 3 -> PipeTiers.Quantium;
case 4 -> PipeTiers.FluxedElectrum;
case 5 -> PipeTiers.BlackPlutonium;
default -> PipeTiers.Platinum;
case 2 -> PipeTiers.Brass;
case 3 -> PipeTiers.Electrum;
case 4 -> PipeTiers.Platinum;
case 5 -> PipeTiers.Osmium;
case 6 -> PipeTiers.Quantium;
case 7 -> PipeTiers.FluxedElectrum;
case 8 -> PipeTiers.BlackPlutonium;
default -> PipeTiers.Tin;
};
}

// get tier from block meta
private static Integer getTierFromMeta(Block block, Integer metaID) {
if (block != GregTechAPI.sBlockCasings11) return -1;
if (metaID < 3 || metaID > 7) return -1;
return (metaID - 2);
if (metaID < 0 || metaID > 7) return -1;
return metaID + 1;
}

private void setPipeTier(int tier) {
Expand Down Expand Up @@ -150,6 +156,9 @@ private int getPipeTier() {
ofBlocksTiered(
MTEMultiLathe::getTierFromMeta,
ImmutableList.of(
Pair.of(GregTechAPI.sBlockCasings11, 0),
Pair.of(GregTechAPI.sBlockCasings11, 1),
Pair.of(GregTechAPI.sBlockCasings11, 2),
Pair.of(GregTechAPI.sBlockCasings11, 3),
Pair.of(GregTechAPI.sBlockCasings11, 4),
Pair.of(GregTechAPI.sBlockCasings11, 5),
Expand Down Expand Up @@ -220,8 +229,8 @@ protected MultiblockTooltipBuilder createTooltip() {
tt.addMachineType("Lathe")
.addInfo("Controller Block for the Industrial Precision Lathe")
.addInfo("Gains 2 parallels per voltage tier,")
.addInfo("and 4 parallels per pipe casing tier (16 for Black Plutonium)")
.addInfo("Better pipe casings increase speed")
.addInfo("and 4 parallels per pipe casing tier starting at Platinum, 16 for Black Plutonium")
.addInfo("Better item pipe casings increase speed")
.addInfo("Only uses 80% of the recipe's required energy")
.addInfo(AuthorVolence)
.addSeparator()
Expand Down Expand Up @@ -270,9 +279,8 @@ public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack a
getBaseMetaTileEntity().sendBlockEvent(GregTechTileClientEvents.CHANGE_CUSTOM_DATA, getUpdateData());
if (!checkPiece(STRUCTURE_PIECE_BODY, 3, 4, -1) && !checkPiece(STRUCTURE_PIECE_BODY_ALT, 3, 4, -1))
return false;
return this.mMaintenanceHatches.size() == 1 && pipeTier >= -1
return this.mMaintenanceHatches.size() == 1 && pipeTier > 0
&& mEnergyHatches.size() >= 1
&& mInputBusses.size() >= 1
&& mMufflerHatches.size() == 1;
}

Expand Down
Loading

0 comments on commit 7b6d363

Please sign in to comment.