diff --git a/src/datagen/groovy/techreborn/datagen/recipes/machine/MachineRecipeJsonFactory.groovy b/src/datagen/groovy/techreborn/datagen/recipes/machine/MachineRecipeJsonFactory.groovy index 3c39e2d88..f0ade2992 100644 --- a/src/datagen/groovy/techreborn/datagen/recipes/machine/MachineRecipeJsonFactory.groovy +++ b/src/datagen/groovy/techreborn/datagen/recipes/machine/MachineRecipeJsonFactory.groovy @@ -40,14 +40,14 @@ import reborncore.common.crafting.ingredient.RebornIngredient import java.util.function.Consumer class MachineRecipeJsonFactory { - private final RebornRecipeType type + protected final RebornRecipeType type - private final List ingredients = new ArrayList<>() - private final List outputs = new ArrayList<>() - private int power = -1 - private int time = -1 - private Identifier customId = null - private String source = null + protected final List ingredients = new ArrayList<>() + protected final List outputs = new ArrayList<>() + protected int power = -1 + protected int time = -1 + protected Identifier customId = null + protected String source = null protected MachineRecipeJsonFactory(RebornRecipeType type) { this.type = type diff --git a/src/datagen/groovy/techreborn/datagen/recipes/machine/blast_furnace/BlastFurnaceRecipesProvider.groovy b/src/datagen/groovy/techreborn/datagen/recipes/machine/blast_furnace/BlastFurnaceRecipesProvider.groovy index dabfef414..d5a83a719 100644 --- a/src/datagen/groovy/techreborn/datagen/recipes/machine/blast_furnace/BlastFurnaceRecipesProvider.groovy +++ b/src/datagen/groovy/techreborn/datagen/recipes/machine/blast_furnace/BlastFurnaceRecipesProvider.groovy @@ -39,9 +39,9 @@ import techreborn.init.TRContent class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { - public final int ARMOR_POWER = 128; - public final int ARMOR_TIME = 140; - public final int ARMOR_HEAT = 1000; + public final int ARMOR_POWER = 128 + public final int ARMOR_TIME = 140 + public final int ARMOR_HEAT = 1000 BlastFurnaceRecipesProvider(FabricDataGenerator dataGenerator) { super(dataGenerator) @@ -60,7 +60,7 @@ class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { } void generateFromBootsRecipes() { - final int count = 4; + final int count = 4 [ (Items.DIAMOND_BOOTS) : new ItemStack(Items.DIAMOND, count), (Items.GOLDEN_BOOTS) : new ItemStack(Items.GOLD_INGOT, count), @@ -84,7 +84,7 @@ class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { } void generateFromChestplateRecipes() { - final int count = 8; + final int count = 8 [ (Items.DIAMOND_CHESTPLATE) : new ItemStack(Items.DIAMOND, count), (Items.GOLDEN_CHESTPLATE) : new ItemStack(Items.GOLD_INGOT, count), @@ -95,12 +95,20 @@ class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { (TRContent.SAPPHIRE_CHESTPLATE) : new ItemStack(TRContent.Gems.SAPPHIRE, count), (TRContent.SILVER_CHESTPLATE) : new ItemStack(TRContent.Ingots.SILVER, count), (TRContent.STEEL_CHESTPLATE) : new ItemStack(TRContent.Ingots.STEEL, count) - ] - + ].each {chestplate, materialStack -> + offerBlastFurnaceRecipe { + ingredients chestplate, Items.SAND + outputs materialStack, TRContent.Dusts.DARK_ASHES + power ARMOR_POWER + time ARMOR_TIME + heat ARMOR_HEAT + source "chestplate" + } + } } void generateFromHelmetRecipes() { - final int count = 5; + final int count = 5 [ (Items.DIAMOND_HELMET) : new ItemStack(Items.DIAMOND, count), (Items.GOLDEN_HELMET) : new ItemStack(Items.GOLD_INGOT, count), @@ -111,12 +119,20 @@ class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { (TRContent.SAPPHIRE_HELMET) : new ItemStack(TRContent.Gems.SAPPHIRE, count), (TRContent.SILVER_HELMET) : new ItemStack(TRContent.Ingots.SILVER, count), (TRContent.STEEL_HELMET) : new ItemStack(TRContent.Ingots.STEEL, count) - ] - + ].each {helmet, materialStack -> + offerBlastFurnaceRecipe { + ingredients helmet, Items.SAND + outputs materialStack, TRContent.Dusts.DARK_ASHES + power ARMOR_POWER + time ARMOR_TIME + heat ARMOR_HEAT + source "helmet" + } + } } void generateFromLeggingsRecipes() { - final int count = 7; + final int count = 7 [ (Items.DIAMOND_LEGGINGS) : new ItemStack(Items.DIAMOND, count), (Items.GOLDEN_LEGGINGS) : new ItemStack(Items.GOLD_INGOT, count), @@ -127,7 +143,15 @@ class BlastFurnaceRecipesProvider extends TechRebornRecipesProvider { (TRContent.SAPPHIRE_LEGGINGS) : new ItemStack(TRContent.Gems.SAPPHIRE, count), (TRContent.SILVER_LEGGINGS) : new ItemStack(TRContent.Ingots.SILVER, count), (TRContent.STEEL_LEGGINGS) : new ItemStack(TRContent.Ingots.STEEL, count) - ] - + ].each {leggings, materialStack -> + offerBlastFurnaceRecipe { + ingredients leggings, Items.SAND + outputs materialStack, TRContent.Dusts.DARK_ASHES + power ARMOR_POWER + time ARMOR_TIME + heat ARMOR_HEAT + source "leggings" + } + } } } \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_boots.json b/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_boots.json deleted file mode 100644 index 0cba6b6b1..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_boots.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:diamond_boots" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:diamond", - "count": 4 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_chestplate.json b/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_chestplate.json deleted file mode 100644 index 3c6b93630..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_chestplate.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:diamond_chestplate" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:diamond", - "count": 8 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_helmet.json b/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_helmet.json deleted file mode 100644 index f3f4e97e1..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_helmet.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:diamond_helmet" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:diamond", - "count": 5 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_leggings.json b/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_leggings.json deleted file mode 100644 index e60aa01ea..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/diamond_from_leggings.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:diamond_leggings" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:diamond", - "count": 7 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_boots.json b/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_boots.json deleted file mode 100644 index 4bc5dec8d..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_boots.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:golden_boots" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:gold_ingot", - "count": 4 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_chestplate.json b/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_chestplate.json deleted file mode 100644 index 3e4b04a55..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_chestplate.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:golden_chestplate" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:gold_ingot", - "count": 8 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_helmet.json b/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_helmet.json deleted file mode 100644 index 374fabf4a..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_helmet.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:golden_helmet" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:gold_ingot", - "count": 5 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_leggings.json b/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_leggings.json deleted file mode 100644 index f29721ef8..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/gold_ingot_from_leggings.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:golden_leggings" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:gold_ingot", - "count": 7 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_boots.json b/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_boots.json deleted file mode 100644 index 58ea8d48d..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_boots.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:iron_boots" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:iron_ingot", - "count": 4 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_chestplate.json b/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_chestplate.json deleted file mode 100644 index a75642354..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_chestplate.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:iron_chestplate" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:iron_ingot", - "count": 8 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_helmet.json b/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_helmet.json deleted file mode 100644 index 04700e503..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_helmet.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:iron_helmet" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:iron_ingot", - "count": 5 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_leggings.json b/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_leggings.json deleted file mode 100644 index fd36487d1..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_leggings.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:iron_leggings" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:iron_ingot", - "count": 7 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -} \ No newline at end of file diff --git a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_minecart.json b/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_minecart.json deleted file mode 100644 index 50aacff14..000000000 --- a/src/main/resources/data/techreborn/recipes/blast_furnace/iron_ingot_from_minecart.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "type": "techreborn:blast_furnace", - "power": 128, - "time": 140, - "heat": 1000, - "ingredients" : [ - { - "item": "minecraft:minecart" - }, - { - "item": "minecraft:sand" - } - ], - "results" : [ - { - "item": "minecraft:iron_ingot", - "count": 5 - }, - { - "item": "techreborn:dark_ashes_dust" - } - ] -}