From 3750a52d3a2398d9a1be14424df4e9dea2de2340 Mon Sep 17 00:00:00 2001 From: rbasamoyai Date: Tue, 31 Dec 2024 09:39:42 -0500 Subject: [PATCH] bug: Fixed issue #730, added recipes for the Wired Fuze and Fixed Cannon Mount - Added common CBC tag for copper ingots with EMI translation --- CHANGELOG.md | 3 ++ Translators-Changes.md | 4 +++ .../assets/createbigcannons/lang/en_ud.json | 1 + .../assets/createbigcannons/lang/en_us.json | 1 + .../recipes/misc/fixed_cannon_mount.json | 33 +++++++++++++++++++ .../advancements/recipes/misc/wired_fuze.json | 33 +++++++++++++++++++ .../recipes/fixed_cannon_mount.json | 23 +++++++++++++ .../createbigcannons/recipes/wired_fuze.json | 20 +++++++++++ .../tags/items/ingot_copper.json | 17 ++++++++++ .../assets/createbigcannons/lang/en_ud.json | 1 + .../assets/createbigcannons/lang/en_us.json | 1 + .../recipes/misc/fixed_cannon_mount.json | 33 +++++++++++++++++++ .../advancements/recipes/misc/wired_fuze.json | 33 +++++++++++++++++++ .../recipes/fixed_cannon_mount.json | 23 +++++++++++++ .../createbigcannons/recipes/wired_fuze.json | 20 +++++++++++ .../tags/items/ingot_copper.json | 17 ++++++++++ .../rbasamoyai/createbigcannons/CBCTags.java | 2 ++ .../datagen/assets/CBCLangGen.java | 1 + .../recipes/CBCCraftingRecipeProvider.java | 13 ++++++++ 19 files changed, 279 insertions(+) create mode 100644 fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json create mode 100644 fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json create mode 100644 fabric/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json create mode 100644 fabric/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json create mode 100644 fabric/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json create mode 100644 forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json create mode 100644 forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json create mode 100644 forge/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json create mode 100644 forge/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json create mode 100644 forge/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json diff --git a/CHANGELOG.md b/CHANGELOG.md index dbf273622..c7433e48d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,9 @@ and I'm waiting for you to follow me..."* \ **Create Big Cannons 5.8.1. Comes with a few critical fixes for Create Big Cannons 5.8.0.** +### Added +- Added recipes for Fixed Cannon Mount and Wired Fuze (fixes issue #730) + ## [5.8.0] - 2024-12-30 *"I'm free – I'm FREE, \ diff --git a/Translators-Changes.md b/Translators-Changes.md index 699c90adc..0f59a18c3 100644 --- a/Translators-Changes.md +++ b/Translators-Changes.md @@ -6,6 +6,10 @@ Note: Changes to en_us.json before Create Big Cannons 0.5.3.b => 0.5.4 will not --- +## 5.8.0 → 5.8.1 +Additions: \ ++ `"tag.createbigcannons.ingot_copper": "Copper Ingots"` + ## 5.7.2 → 5.8.0 Additions: \ + `"block.createbigcannons.cannon_mount_extension": "Cannon Mount Extension"` \ diff --git a/fabric/src/generated/resources/assets/createbigcannons/lang/en_ud.json b/fabric/src/generated/resources/assets/createbigcannons/lang/en_ud.json index d1cf6930e..1fd04737e 100644 --- a/fabric/src/generated/resources/assets/createbigcannons/lang/en_ud.json +++ b/fabric/src/generated/resources/assets/createbigcannons/lang/en_ud.json @@ -704,6 +704,7 @@ "tag.createbigcannons.ingot_brass": "sʇobuI ssɐɹᗺ", "tag.createbigcannons.ingot_bronze": "sʇobuI ǝzuoɹᗺ", "tag.createbigcannons.ingot_cast_iron": "sʇobuI uoɹI ʇsɐƆ", + "tag.createbigcannons.ingot_copper": "sʇobuI ɹǝddoƆ", "tag.createbigcannons.ingot_iron": "sʇobuI uoɹI", "tag.createbigcannons.ingot_nethersteel": "sʇobuI ןǝǝʇsɹǝɥʇǝN", "tag.createbigcannons.ingot_steel": "sʇobuI ןǝǝʇS", diff --git a/fabric/src/generated/resources/assets/createbigcannons/lang/en_us.json b/fabric/src/generated/resources/assets/createbigcannons/lang/en_us.json index cf99106d2..65fc9904b 100644 --- a/fabric/src/generated/resources/assets/createbigcannons/lang/en_us.json +++ b/fabric/src/generated/resources/assets/createbigcannons/lang/en_us.json @@ -704,6 +704,7 @@ "tag.createbigcannons.ingot_brass": "Brass Ingots", "tag.createbigcannons.ingot_bronze": "Bronze Ingots", "tag.createbigcannons.ingot_cast_iron": "Cast Iron Ingots", + "tag.createbigcannons.ingot_copper": "Copper Ingots", "tag.createbigcannons.ingot_iron": "Iron Ingots", "tag.createbigcannons.ingot_nethersteel": "Nethersteel Ingots", "tag.createbigcannons.ingot_steel": "Steel Ingots", diff --git a/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json b/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json new file mode 100644 index 000000000..ba3a33874 --- /dev/null +++ b/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json @@ -0,0 +1,33 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_gunpowder": { + "conditions": { + "items": [ + { + "tag": "createbigcannons:gunpowder" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "createbigcannons:fixed_cannon_mount" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_gunpowder", + "has_the_recipe" + ] + ], + "rewards": { + "recipes": [ + "createbigcannons:fixed_cannon_mount" + ] + }, + "sends_telemetry_event": false +} \ No newline at end of file diff --git a/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json b/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json new file mode 100644 index 000000000..3071cccc7 --- /dev/null +++ b/fabric/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json @@ -0,0 +1,33 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_redstone": { + "conditions": { + "items": [ + { + "tag": "createbigcannons:dusts_redstone" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "createbigcannons:wired_fuze" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_redstone", + "has_the_recipe" + ] + ], + "rewards": { + "recipes": [ + "createbigcannons:wired_fuze" + ] + }, + "sends_telemetry_event": false +} \ No newline at end of file diff --git a/fabric/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json b/fabric/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json new file mode 100644 index 000000000..2174a8400 --- /dev/null +++ b/fabric/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json @@ -0,0 +1,23 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "C": { + "item": "create:andesite_casing" + }, + "G": { + "tag": "createbigcannons:gunpowder" + }, + "I": { + "tag": "createbigcannons:sheet_iron" + } + }, + "pattern": [ + " I ", + "GCG" + ], + "result": { + "item": "createbigcannons:fixed_cannon_mount" + }, + "show_notification": true +} \ No newline at end of file diff --git a/fabric/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json b/fabric/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json new file mode 100644 index 000000000..f81107350 --- /dev/null +++ b/fabric/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "I": { + "tag": "createbigcannons:ingot_copper" + }, + "W": { + "tag": "createbigcannons:dusts_redstone" + } + }, + "pattern": [ + "WIW" + ], + "result": { + "count": 4, + "item": "createbigcannons:wired_fuze" + }, + "show_notification": true +} \ No newline at end of file diff --git a/fabric/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json b/fabric/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json new file mode 100644 index 000000000..045c78bc5 --- /dev/null +++ b/fabric/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json @@ -0,0 +1,17 @@ +{ + "replace": false, + "values": [ + { + "id": "#forge:ingots/copper", + "required": false + }, + { + "id": "#c:ingots/copper", + "required": false + }, + { + "id": "#c:copper_ingots", + "required": false + } + ] +} \ No newline at end of file diff --git a/forge/src/generated/resources/assets/createbigcannons/lang/en_ud.json b/forge/src/generated/resources/assets/createbigcannons/lang/en_ud.json index d1cf6930e..1fd04737e 100644 --- a/forge/src/generated/resources/assets/createbigcannons/lang/en_ud.json +++ b/forge/src/generated/resources/assets/createbigcannons/lang/en_ud.json @@ -704,6 +704,7 @@ "tag.createbigcannons.ingot_brass": "sʇobuI ssɐɹᗺ", "tag.createbigcannons.ingot_bronze": "sʇobuI ǝzuoɹᗺ", "tag.createbigcannons.ingot_cast_iron": "sʇobuI uoɹI ʇsɐƆ", + "tag.createbigcannons.ingot_copper": "sʇobuI ɹǝddoƆ", "tag.createbigcannons.ingot_iron": "sʇobuI uoɹI", "tag.createbigcannons.ingot_nethersteel": "sʇobuI ןǝǝʇsɹǝɥʇǝN", "tag.createbigcannons.ingot_steel": "sʇobuI ןǝǝʇS", diff --git a/forge/src/generated/resources/assets/createbigcannons/lang/en_us.json b/forge/src/generated/resources/assets/createbigcannons/lang/en_us.json index cf99106d2..65fc9904b 100644 --- a/forge/src/generated/resources/assets/createbigcannons/lang/en_us.json +++ b/forge/src/generated/resources/assets/createbigcannons/lang/en_us.json @@ -704,6 +704,7 @@ "tag.createbigcannons.ingot_brass": "Brass Ingots", "tag.createbigcannons.ingot_bronze": "Bronze Ingots", "tag.createbigcannons.ingot_cast_iron": "Cast Iron Ingots", + "tag.createbigcannons.ingot_copper": "Copper Ingots", "tag.createbigcannons.ingot_iron": "Iron Ingots", "tag.createbigcannons.ingot_nethersteel": "Nethersteel Ingots", "tag.createbigcannons.ingot_steel": "Steel Ingots", diff --git a/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json b/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json new file mode 100644 index 000000000..ba3a33874 --- /dev/null +++ b/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/fixed_cannon_mount.json @@ -0,0 +1,33 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_gunpowder": { + "conditions": { + "items": [ + { + "tag": "createbigcannons:gunpowder" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "createbigcannons:fixed_cannon_mount" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_gunpowder", + "has_the_recipe" + ] + ], + "rewards": { + "recipes": [ + "createbigcannons:fixed_cannon_mount" + ] + }, + "sends_telemetry_event": false +} \ No newline at end of file diff --git a/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json b/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json new file mode 100644 index 000000000..3071cccc7 --- /dev/null +++ b/forge/src/generated/resources/data/createbigcannons/advancements/recipes/misc/wired_fuze.json @@ -0,0 +1,33 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_redstone": { + "conditions": { + "items": [ + { + "tag": "createbigcannons:dusts_redstone" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "createbigcannons:wired_fuze" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_redstone", + "has_the_recipe" + ] + ], + "rewards": { + "recipes": [ + "createbigcannons:wired_fuze" + ] + }, + "sends_telemetry_event": false +} \ No newline at end of file diff --git a/forge/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json b/forge/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json new file mode 100644 index 000000000..2174a8400 --- /dev/null +++ b/forge/src/generated/resources/data/createbigcannons/recipes/fixed_cannon_mount.json @@ -0,0 +1,23 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "C": { + "item": "create:andesite_casing" + }, + "G": { + "tag": "createbigcannons:gunpowder" + }, + "I": { + "tag": "createbigcannons:sheet_iron" + } + }, + "pattern": [ + " I ", + "GCG" + ], + "result": { + "item": "createbigcannons:fixed_cannon_mount" + }, + "show_notification": true +} \ No newline at end of file diff --git a/forge/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json b/forge/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json new file mode 100644 index 000000000..f81107350 --- /dev/null +++ b/forge/src/generated/resources/data/createbigcannons/recipes/wired_fuze.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "I": { + "tag": "createbigcannons:ingot_copper" + }, + "W": { + "tag": "createbigcannons:dusts_redstone" + } + }, + "pattern": [ + "WIW" + ], + "result": { + "count": 4, + "item": "createbigcannons:wired_fuze" + }, + "show_notification": true +} \ No newline at end of file diff --git a/forge/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json b/forge/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json new file mode 100644 index 000000000..045c78bc5 --- /dev/null +++ b/forge/src/generated/resources/data/createbigcannons/tags/items/ingot_copper.json @@ -0,0 +1,17 @@ +{ + "replace": false, + "values": [ + { + "id": "#forge:ingots/copper", + "required": false + }, + { + "id": "#c:ingots/copper", + "required": false + }, + { + "id": "#c:copper_ingots", + "required": false + } + ] +} \ No newline at end of file diff --git a/src/main/java/rbasamoyai/createbigcannons/CBCTags.java b/src/main/java/rbasamoyai/createbigcannons/CBCTags.java index 58f96092a..4b55fe35d 100644 --- a/src/main/java/rbasamoyai/createbigcannons/CBCTags.java +++ b/src/main/java/rbasamoyai/createbigcannons/CBCTags.java @@ -166,6 +166,7 @@ private static void iterateOverCopperSet(CopperBlockSet set, TagKey tag) } public static class CBCItemTags { + // TODO: Update fabric ore tags to use fabric-convention-tags in 1.21 public static final TagKey IMPACT_FUZE_HEAD = makeTag("impact_fuze_head"), NUGGET_CAST_IRON = commonTag("nugget_cast_iron", "nuggets/cast_iron", "cast_iron_nuggets"), @@ -186,6 +187,7 @@ public static class CBCItemTags { NUGGET_IRON = commonTag("nugget_iron", "nuggets/iron", "iron_nuggets"), SHEET_IRON = commonTag("sheet_iron", "plates/iron", "iron_plates"), NUGGET_COPPER = commonTag("nugget_copper", "nuggets/copper", "copper_nuggets"), + INGOT_COPPER = commonTag("ingot_copper", "ingots/copper", "copper_ingots"), GUNPOWDER = commonTag("gunpowder", "gunpowder", "gunpowder" /* No fabric c: tag */), GEMS_QUARTZ = commonTag("gems_quartz", "gems/quartz", "quartz"), DUSTS_REDSTONE = commonTag("dusts_redstone", "dusts/redstone", "redstone_dusts"), diff --git a/src/main/java/rbasamoyai/createbigcannons/datagen/assets/CBCLangGen.java b/src/main/java/rbasamoyai/createbigcannons/datagen/assets/CBCLangGen.java index 4578e6fe9..b965f2835 100644 --- a/src/main/java/rbasamoyai/createbigcannons/datagen/assets/CBCLangGen.java +++ b/src/main/java/rbasamoyai/createbigcannons/datagen/assets/CBCLangGen.java @@ -339,6 +339,7 @@ public static void prepare() { createEMITagTranslation(CBCTags.CBCItemTags.INGOT_BRASS, "Brass Ingots"); createEMITagTranslation(CBCTags.CBCItemTags.INGOT_BRONZE, "Bronze Ingots"); createEMITagTranslation(CBCTags.CBCItemTags.INGOT_CAST_IRON, "Cast Iron Ingots"); + createEMITagTranslation(CBCTags.CBCItemTags.INGOT_COPPER, "Copper Ingots"); createEMITagTranslation(CBCTags.CBCItemTags.INGOT_IRON, "Iron Ingots"); createEMITagTranslation(CBCTags.CBCItemTags.INGOT_NETHERSTEEL, "Nethersteel Ingots"); createEMITagTranslation(CBCTags.CBCItemTags.INGOT_STEEL, "Steel Ingots"); diff --git a/src/main/java/rbasamoyai/createbigcannons/datagen/recipes/CBCCraftingRecipeProvider.java b/src/main/java/rbasamoyai/createbigcannons/datagen/recipes/CBCCraftingRecipeProvider.java index 6ff740cf8..77b486a6d 100644 --- a/src/main/java/rbasamoyai/createbigcannons/datagen/recipes/CBCCraftingRecipeProvider.java +++ b/src/main/java/rbasamoyai/createbigcannons/datagen/recipes/CBCCraftingRecipeProvider.java @@ -65,6 +65,12 @@ public static void buildCraftingRecipes(Consumer cons) { .unlockedBy(getHasName(CBCItems.IMPACT_FUZE.get()), has(CBCItems.IMPACT_FUZE.get())) .save(cons); + ShapedRecipeBuilder.shaped(RecipeCategory.MISC, CBCItems.WIRED_FUZE.get(), 4) + .define('I', CBCTags.CBCItemTags.INGOT_COPPER).define('W', CBCTags.CBCItemTags.DUSTS_REDSTONE) + .pattern("WIW") + .unlockedBy("has_redstone", has(CBCTags.CBCItemTags.DUSTS_REDSTONE)) + .save(cons); + ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, CBCItems.TRACER_TIP.get(), 4) .requires(CBCTags.CBCItemTags.DUST_GLOWSTONE).requires(Items.BLAZE_POWDER) .unlockedBy("has_glowstone", has(CBCTags.CBCItemTags.DUST_GLOWSTONE)) @@ -354,6 +360,13 @@ public static void buildCraftingRecipes(Consumer cons) { .unlockedBy(getHasName(CBCBlocks.CANNON_MOUNT.get()), has(CBCBlocks.CANNON_MOUNT.get())) .save(cons); + ShapedRecipeBuilder.shaped(RecipeCategory.MISC, CBCBlocks.FIXED_CANNON_MOUNT.get()) + .define('C', AllBlocks.ANDESITE_CASING.get()).define('G', CBCTags.CBCItemTags.GUNPOWDER).define('I', CBCTags.CBCItemTags.SHEET_IRON) + .pattern(" I ") + .pattern("GCG") + .unlockedBy("has_gunpowder", has(CBCTags.CBCItemTags.GUNPOWDER)) + .save(cons); + ShapedRecipeBuilder.shaped(RecipeCategory.MISC, CBCItems.CAST_IRON_SLIDING_BREECHBLOCK.get()) .define('I', CBCTags.CBCItemTags.INGOT_CAST_IRON).define('C', AllBlocks.COGWHEEL.get()) .pattern(" I ")