diff --git a/src/main/java/li/cil/oc2/data/ModRecipesProvider.java b/src/main/java/li/cil/oc2/data/ModRecipesProvider.java index 565b13ae..fcdd9aa2 100644 --- a/src/main/java/li/cil/oc2/data/ModRecipesProvider.java +++ b/src/main/java/li/cil/oc2/data/ModRecipesProvider.java @@ -244,10 +244,10 @@ public final class ModRecipesProvider extends RecipeProvider { .shapedRecipe(Items.REDSTONE_INTERFACE_CARD.get()) .patternLine("IRT") .patternLine(" B ") - .key('I', Tags.Items.INGOTS_IRON) - .key('B', Items.CIRCUIT_BOARD.get()) - .key('T', Items.TRANSISTOR.get()) .key('R', net.minecraft.item.Items.REDSTONE_TORCH) + .key('I', Tags.Items.INGOTS_IRON) + .key('T', Items.TRANSISTOR.get()) + .key('B', Items.CIRCUIT_BOARD.get()) .addCriterion("has_computer", inventoryChange(Items.COMPUTER.get())) .build(consumer); @@ -255,8 +255,19 @@ public final class ModRecipesProvider extends RecipeProvider { .shapedRecipe(Items.NETWORK_INTERFACE_CARD.get()) .patternLine("IGT") .patternLine(" B ") - .key('I', Tags.Items.INGOTS_IRON) .key('G', Tags.Items.GLASS) + .key('I', Tags.Items.INGOTS_IRON) + .key('T', Items.TRANSISTOR.get()) + .key('B', Items.CIRCUIT_BOARD.get()) + .addCriterion("has_computer", inventoryChange(Items.COMPUTER.get())) + .build(consumer); + + ShapedRecipeBuilder + .shapedRecipe(Items.FILE_IMPORT_EXPORT_CARD.get()) + .patternLine("IET") + .patternLine(" B ") + .key('E', net.minecraft.item.Items.PAPER) + .key('I', Tags.Items.INGOTS_IRON) .key('T', Items.TRANSISTOR.get()) .key('B', Items.CIRCUIT_BOARD.get()) .addCriterion("has_computer", inventoryChange(Items.COMPUTER.get())) diff --git a/src/main/resources/data/oc2/advancements/recipes/oc2.common/file_import_export_card.json b/src/main/resources/data/oc2/advancements/recipes/oc2.common/file_import_export_card.json new file mode 100644 index 00000000..f2301676 --- /dev/null +++ b/src/main/resources/data/oc2/advancements/recipes/oc2.common/file_import_export_card.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "rewards": { + "recipes": [ + "oc2:file_import_export_card" + ] + }, + "criteria": { + "has_computer": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "oc2:computer" + } + ] + } + }, + "has_the_recipe": { + "trigger": "minecraft:recipe_unlocked", + "conditions": { + "recipe": "oc2:file_import_export_card" + } + } + }, + "requirements": [ + [ + "has_computer", + "has_the_recipe" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/oc2/recipes/file_import_export_card.json b/src/main/resources/data/oc2/recipes/file_import_export_card.json new file mode 100644 index 00000000..fb36242d --- /dev/null +++ b/src/main/resources/data/oc2/recipes/file_import_export_card.json @@ -0,0 +1,24 @@ +{ + "type": "minecraft:crafting_shaped", + "pattern": [ + "IET", + " B " + ], + "key": { + "E": { + "item": "minecraft:paper" + }, + "I": { + "tag": "forge:ingots/iron" + }, + "T": { + "item": "oc2:transistor" + }, + "B": { + "item": "oc2:circuit_board" + } + }, + "result": { + "item": "oc2:file_import_export_card" + } +} \ No newline at end of file diff --git a/src/main/resources/data/oc2/recipes/network_interface_card.json b/src/main/resources/data/oc2/recipes/network_interface_card.json index 2f9c5567..637656d4 100644 --- a/src/main/resources/data/oc2/recipes/network_interface_card.json +++ b/src/main/resources/data/oc2/recipes/network_interface_card.json @@ -5,12 +5,12 @@ " B " ], "key": { - "I": { - "tag": "forge:ingots/iron" - }, "G": { "tag": "forge:glass" }, + "I": { + "tag": "forge:ingots/iron" + }, "T": { "item": "oc2:transistor" }, diff --git a/src/main/resources/data/oc2/recipes/redstone_interface_card.json b/src/main/resources/data/oc2/recipes/redstone_interface_card.json index 03de9a99..a3aa5ad5 100644 --- a/src/main/resources/data/oc2/recipes/redstone_interface_card.json +++ b/src/main/resources/data/oc2/recipes/redstone_interface_card.json @@ -5,17 +5,17 @@ " B " ], "key": { + "R": { + "item": "minecraft:redstone_torch" + }, "I": { "tag": "forge:ingots/iron" }, - "B": { - "item": "oc2:circuit_board" - }, "T": { "item": "oc2:transistor" }, - "R": { - "item": "minecraft:redstone_torch" + "B": { + "item": "oc2:circuit_board" } }, "result": {