-
Notifications
You must be signed in to change notification settings - Fork 30
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
Cleanup of Recipes and moving to RecipeHandlers #141
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some of this struck me as a bit odd as I read through the changes. I'm assuming most of the recipe changes are accurate at this point, but I left comments on things that seemed unusual to me.
Also if this is still a work in progress and waiting on other changes from GTCE to be released, perhaps it would be sensible to mark this as a Draft PR rather than one ready for review.
src/main/java/gregicadditions/recipes/MachineCraftingRecipes.java
Outdated
Show resolved
Hide resolved
src/main/java/gregicadditions/recipes/MachineCraftingRecipes.java
Outdated
Show resolved
Hide resolved
@@ -242,7 +139,7 @@ public static void init() { | |||
ModHandler.addShapedRecipe("stainless_steel_drum", GATileEntities.STAINLESS_STEEL_DRUM.getStackForm(), " h ", "PRP", "PRP", 'P', "plateCurvedStainlessSteel", 'R', "stickLongStainlessSteel"); | |||
ModHandler.addShapedRecipe("titanium_drum", GATileEntities.TITANIUM_DRUM.getStackForm(), " h ", "PRP", "PRP", 'P', "plateCurvedTitanium", 'R', "stickLongTitanium"); | |||
ModHandler.addShapedRecipe("tungstensteel_drum", GATileEntities.TUNGSTENSTEEL_DRUM.getStackForm(), " h ", "PRP", "PRP", 'P', "plateCurvedTungstenSteel", 'R', "stickLongTungstenSteel"); | |||
} else if (!(GAConfig.GT6.BendingCurvedPlates || GAConfig.GT6.BendingCylinders)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to pertain to config options to change default recipes based on how things work in GT6. Is there a reason it's being removed from the logic here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The logic here is redundant, as if the curved plates are not registered, then regular plates should just be used. In addition, it can be seen that before the final line was added on the initial if, checking if the curved plates were registered, that the conditionals on this else if
were basically inverted from the conditionals on the if.
|
||
//Power Manipulation Machines | ||
ItemStack last_bat = (GAConfig.GT5U.replaceUVwithMAXBat ? GAMetaItems.MAX_BATTERY : MetaItems.ZPM2).getStackForm(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does GTCE natively have chargers through MAX tier? Not sure why these are being removed otherwise. There's also various configs that control how some of these are added.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, GTCE natively has chargers though MAX tier. I am unsure if there is any config option for adding the higher tier chargers, but I can check for that as well.
ModHandler.addShapedRecipe("ga_steam_turbine_lv", MetaTileEntities.STEAM_TURBINE[0].getStackForm(), "PCP", "RMR", "EWE", 'M', MetaTileEntities.HULL[GTValues.LV].getStackForm(), 'E', MetaItems.ELECTRIC_MOTOR_LV, 'R', new UnificationEntry(OrePrefix.rotor, Materials.Tin), 'C', new UnificationEntry(OrePrefix.valueOf("circuit"), Tier.Basic), 'W', new UnificationEntry(OrePrefix.cableGtSingle, Materials.Tin), 'P', new UnificationEntry(OrePrefix.pipeMedium, Materials.Bronze)); | ||
ModHandler.addShapedRecipe("ga_steam_turbine_mv", MetaTileEntities.STEAM_TURBINE[1].getStackForm(), "PCP", "RMR", "EWE", 'M', MetaTileEntities.HULL[GTValues.MV].getStackForm(), 'E', MetaItems.ELECTRIC_MOTOR_MV, 'R', new UnificationEntry(OrePrefix.rotor, Materials.Bronze), 'C', new UnificationEntry(OrePrefix.valueOf("circuit"), Tier.Good), 'W', new UnificationEntry(OrePrefix.cableGtSingle, Materials.Copper), 'P', new UnificationEntry(OrePrefix.pipeMedium, Materials.Steel)); | ||
ModHandler.addShapedRecipe("ga_steam_turbine_hv", MetaTileEntities.STEAM_TURBINE[2].getStackForm(), "PCP", "RMR", "EWE", 'M', MetaTileEntities.HULL[GTValues.HV].getStackForm(), 'E', MetaItems.ELECTRIC_MOTOR_HV, 'R', new UnificationEntry(OrePrefix.rotor, Materials.Steel), 'C', new UnificationEntry(OrePrefix.valueOf("circuit"), Tier.Advanced), 'W', new UnificationEntry(OrePrefix.cableGtSingle, Materials.Gold), 'P', new UnificationEntry(OrePrefix.pipeMedium, Materials.StainlessSteel)); | ||
ModHandler.addShapedRecipe("ga_magic_energy_absorber", MetaTileEntities.MAGIC_ENERGY_ABSORBER.getStackForm(), "PCP", "PMP", "PCP", 'M', MetaTileEntities.HULL[GTValues.EV].getStackForm(), 'P', MetaItems.SENSOR_EV, 'C', new UnificationEntry(OrePrefix.valueOf("circuit"), Tier.Elite)); | ||
if (MetaTileEntities.MAGIC_ENERGY_ABSORBER != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This block is definitely a different recipe than the base GTCE one, reducing the tier from EV to MV.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you look at the line above your comment, we also attempt to set the recipe to EV tier components (Which happens to be the same as GTCE). I am unsure why we are attempting to set the recipe for this machine twice, once at EV and one at MV, but since this machine gives out EV power, and the original recipe in GTCE is EV, I went with removing the MV recipe.
9da874a
to
469bb86
Compare
4cd3c6a
to
d31aa2d
Compare
f2a926b
to
b1e677b
Compare
81bbca7
to
e20e30c
Compare
Reformat recipe removals to use the Helper methods Minor Formatting
Transfers some ore prefixes to the Recipe Handler system Changes our Ore Prefix creation Consolidates Helper Methods
Address some TODOs
Cleanup some recipe detection Slight formatting
Fix divide by zero crash
Formatting of Recipe Additions Cleanup of some TODOs Remove some commented out code
Add recipes to cover Superconductor wires Address some TODOs
…ected by NO_SMASHING
ff08dfd
to
2006e39
Compare
This PR cleans up various recipe removals and additions, where recipes are removed and then a duplicate recipe is added.
In addition, this PR refactors crafting table recipe removals, namely through wrapping the previously used GTCE methods so that we can add additional logging to see if a removal has failed.
GAConfig
GAEnums
WIRE_DOUBLING_ORDER
, as GTCE's is not able to be referencedGregicAdditions
GAMetaItems
GAMetaTool
ComponentRegistration
GAMachineRecipeRemoval
GARecipeAddition
bendingPipes
config option is enabled. This cannot be done in Recipe Handlers, because there is no curved wood plateharder hull
config option from GTCE is enabledgeneratedRecipes
, consolidating some checks and adding a TODO to break it down in a future PRGeneratorFuels
MachineCraftingRecipes
MatterReplication
RecipeHandlers
Process Ingot
This handles the expensive Wrenches and creating recipes for the Bending Cylinders, both config based
Process Tiny Dust
Changes Tiny dusts to be made using the schematic instead of the integrated circuit
Process Small Dust
Changes Small dusts to be made using the schematic instead of the integrated circuit
Process Foil
Adds recipes for handcrafting foils and Cluster Milling foils, both config based
Process Ring
Changes the Ring Recipes to use the Bending Cylinder, config based
Process Round
Adds hand crafting and lathe recipes for the round
Process Plate Curved
Add recipes converting from plates to curved plates, and vice versa, for both hand crafting and the bender
Registers Recipes for pipes using curved plates (Adds handcrafting recipes for Tiny and Large pipes, which did not have them in base GTCE)
Registers Recipes for Rotors with curved plates (by hand and machine), or else restores the rotor assembler recipes removed by GTCE
Process Double Ingot
Adds recipes for Double Ingots and Double Ingots to plates
Process Plate
Adds handcrafting recipes for Tiny and Large pipes (similar to what is done with curved plates), when curved plates are not enabled
Process Wire GT
Adds Bundler recipes
Adds the GT5U cable recipes (Which is a big mess)
Process Gems
HelperMethods
This class currently just wraps the GTCE removal methods so that we can attach logging to the removals. When I am done testing this PR, the logging levels will be moved to debug on pass and warn on fail.
Closes #144
A Note of conversation. The double ingots flag and config option currently will generate recipes for plates that normally do not have recipes, due to the
NO_SMASHING
flag. Do we want to add this flag to Double ingot generation, to prevent these materials from being generated, or to the crafting recipes, to prevent the hand crafting recipes from being generated? This is a break from previous behavior, but it does make some sense.