Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MTESolarFactory #3703

Draft
wants to merge 28 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
56db47a
ponzu ponzu ponzu ponzu ponzu ponzu ponzu ponzu
purebluez Oct 14, 2024
8504e21
add tooltip + various fixes and changes
purebluez Oct 15, 2024
49151f5
even MORE various fixes and changes and features
purebluez Nov 8, 2024
33eb644
add input sep support + make actual recipes + redo metadata
purebluez Nov 23, 2024
2dbbc82
fix that bug with stocking bus (solution came to me in a dream)
purebluez Nov 25, 2024
ba9074e
Merge remote-tracking branch 'origin/master' into test
purebluez Nov 28, 2024
910d712
fix angelica crash (???)
purebluez Nov 28, 2024
7dfc616
Merge branch 'GTNewHorizons:master' into test
purebluez Nov 28, 2024
94d4ef8
fix artifact from merge? idk how that got there
purebluez Nov 28, 2024
a697105
last commit but proper (hopefully)
purebluez Nov 28, 2024
530d7d3
Merge branch 'GTNewHorizons:master' into test
purebluez Nov 28, 2024
01d3900
add controller recipe + bugfix + cleanup
purebluez Nov 28, 2024
97a595b
Merge branch 'GTNewHorizons:master' into solarfactory
purebluez Dec 8, 2024
0a8d515
recipe adjustments
purebluez Dec 18, 2024
64a8e2d
Merge remote-tracking branch 'origin/master' into solarfactory
purebluez Dec 22, 2024
d700f1c
changes for when i pr
purebluez Dec 23, 2024
2d23633
Merge branch 'GTNewHorizons:master' into solarfactory
purebluez Dec 24, 2024
c2375e7
change structure casings
purebluez Dec 24, 2024
0f389f4
adjust tooltip
purebluez Dec 24, 2024
769bab3
Merge branch 'master' into solarfactory
Dream-Master Dec 24, 2024
dc729db
Merge branch 'master' into solarfactory
Dream-Master Dec 27, 2024
43a64ce
stuff
purebluez Dec 27, 2024
ad23692
remove solar factory recipes (see related coremod pr for where they w…
purebluez Dec 27, 2024
933947c
Merge branch 'master' into solarfactory
Dream-Master Dec 28, 2024
ed844e2
The mantle runs away
purebluez Dec 30, 2024
3523935
implement framework for the new tiers
purebluez Jan 12, 2025
7cecaf8
update tooltip for new tiers
purebluez Jan 13, 2025
4819378
Merge branch 'master' into solarfactory
Dream-Master Jan 18, 2025
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
11 changes: 11 additions & 0 deletions src/main/java/gregtech/api/enums/GTValues.java
Original file line number Diff line number Diff line change
Expand Up @@ -611,6 +611,17 @@ public static final class NBT {

public static final String TecTechHatches = "Supports " + TT + " laser and multi-amp hatches";

public static final String AuthorPureBluez = "Author: " + EnumChatFormatting.WHITE
+ "Pure"
+ EnumChatFormatting.AQUA
+ "B"
+ EnumChatFormatting.DARK_AQUA
+ "l"
+ EnumChatFormatting.BLUE
+ "u"
+ EnumChatFormatting.DARK_BLUE
+ "ez";

// 7.5F comes from GT_Tool_Turbine_Large#getBaseDamage() given huge turbines are the most efficient now.
public static double getMaxPlasmaTurbineEfficiencyFromMaterial(Materials material) {
return (5F + (7.5F + material.mToolQuality)) / 10.0;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/gregtech/api/enums/ItemList.java
Original file line number Diff line number Diff line change
Expand Up @@ -1788,6 +1788,7 @@ public enum ItemList implements IItemContainer {
OreDrill4,
PyrolyseOven,
OilCracker,
SolarFactory,
NanoForge,
Crop_Drop_UUMBerry,
Crop_Drop_UUABerry,
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 @@ -336,6 +336,7 @@ public enum MetaTileEntityIDs {
CENTRIFUGE_EV(364),
CENTRIFUGE_IV(365),
MULTI_SOLIDIFIER_CONTROLLER(366),
SOLAR_FACTORY_CONTROLLER(367),
ELECTROLYSER_LV(371),
ELECTROLYSER_MV(372),
ELECTROLYSER_HV(373),
Expand Down
5 changes: 5 additions & 0 deletions src/main/java/gregtech/api/enums/Textures.java
Original file line number Diff line number Diff line change
Expand Up @@ -1264,6 +1264,11 @@ public enum BlockIcons implements IIconContainer, Runnable {
OVERLAY_TOP_CLEANROOM,
OVERLAY_TOP_CLEANROOM_GLOW,

OVERLAY_FRONT_SOLAR_FACTORY_ACTIVE,
OVERLAY_FRONT_SOLAR_FACTORY_ACTIVE_GLOW,
OVERLAY_FRONT_SOLAR_FACTORY_INACTIVE_GLOW,
OVERLAY_FRONT_SOLAR_FACTORY_INACTIVE,

OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR,
OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_GLOW,
OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_ACTIVE,
Expand Down
10 changes: 10 additions & 0 deletions src/main/java/gregtech/api/recipe/RecipeMaps.java
Original file line number Diff line number Diff line change
Expand Up @@ -833,6 +833,16 @@ && isArrayEmptyOrNull(b.getFluidOutputs())
.minInputs(1, 0)
.disableOptimize()
.build();
public static final RecipeMap<RecipeMapBackend> solarFactoryRecipes = RecipeMapBuilder.of("gt.recipe.solarfactory")
.maxIO(9, 1, 3, 0)
.minInputs(1, 0)
// .neiRecipeComparator(
// Comparator
// .<GTRecipe, SolarFactoryRecipeData>comparing(
// recipe -> recipe
// .getMetadataOrDefault(SolarFactoryRecipeDataKey.INSTANCE, new SolarFactoryRecipeData(0, 0, 0)))
// .thenComparing(GTRecipe::compareTo))
.build();
public static final RecipeMap<RecipeMapBackend> wiremillRecipes = RecipeMapBuilder.of("gt.recipe.wiremill")
.maxIO(2, 1, 0, 0)
.minInputs(1, 0)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package gregtech.api.recipe.metadata;

import static gregtech.api.util.GTUtility.trans;

import javax.annotation.Nullable;

import gregtech.api.recipe.RecipeMetadataKey;
import gregtech.api.util.recipe.SolarFactoryRecipeData;
import gregtech.nei.RecipeDisplayInfo;

public class SolarFactoryRecipeDataKey extends RecipeMetadataKey<SolarFactoryRecipeData> {

private SolarFactoryRecipeDataKey() {
super(SolarFactoryRecipeData.class, "solar_factory_wafer_data");
}

public static final SolarFactoryRecipeDataKey INSTANCE = new SolarFactoryRecipeDataKey();

@Override
public void drawInfo(RecipeDisplayInfo recipeInfo, @Nullable Object value) {
SolarFactoryRecipeData metadata = cast(value);
if (metadata.tierRequired != 0) {
recipeInfo.drawText(trans("510", "Tier required: ") + metadata.tierRequired);
}
}
}
1 change: 1 addition & 0 deletions src/main/java/gregtech/api/util/GTLanguageManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -550,6 +550,7 @@ public static void writePlaceholderStrings() {
addStringLocalization("Interaction_DESCRIPTION_Index_507", "Safe Mode");
addStringLocalization("Interaction_DESCRIPTION_Index_508", "Requires Stabilized Black Hole");
addStringLocalization("Interaction_DESCRIPTION_Index_509", "Requires HIP Unit");
addStringLocalization("Interaction_DESCRIPTION_Index_510", "Multi Tier required: ");
addStringLocalization("Interaction_DESCRIPTION_Index_602", "Use Private Frequency");
addStringLocalization("Interaction_DESCRIPTION_Index_756", "Connectable: ");
addStringLocalization("Interaction_DESCRIPTION_Index_ALL", "All");
Expand Down
27 changes: 27 additions & 0 deletions src/main/java/gregtech/api/util/recipe/SolarFactoryRecipeData.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
package gregtech.api.util.recipe;

import org.jetbrains.annotations.NotNull;

public class SolarFactoryRecipeData implements Comparable<SolarFactoryRecipeData> {

public final int minimumWaferTier;
public final int minimumWaferCount;
public final int tierRequired;

public SolarFactoryRecipeData(int minimumWaferTier, int minimumWaferCount) {
this.minimumWaferTier = minimumWaferTier;
this.minimumWaferCount = minimumWaferCount;
this.tierRequired = 0;
}

public SolarFactoryRecipeData(int minimumWaferTier, int minimumWaferCount, int tierRequired) {
this.minimumWaferTier = minimumWaferTier;
this.minimumWaferCount = minimumWaferCount;
this.tierRequired = tierRequired;
}

@Override
public int compareTo(@NotNull SolarFactoryRecipeData o) {
return 0;
}
}
Loading
Loading