diff --git a/CHANGELOG.md b/CHANGELOG.md index 00d4b5b5f0..788f2c2754 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,3 +8,6 @@ Put the changelog BELOW the dashes. ANYTHING ABOVE IS IGNORED - Removed modified water rendering, fixing an issue with Sodium. - Tumbleweeds no longer render their items at the player's position. - Fixed issues with certain sounds like Goat Horn Calls in multiplayer. +- Added missing Mossy Mud Bricks recipes to the Crafting Table. +- Added the Stone Chest to Fabric's chests tag. +- Added a config option to toggle Mossy and Cracked Mud Bricks generating in Trail Ruins. diff --git a/src/datagen/java/net/frozenblock/wilderwild/datagen/recipe/WWRecipeProvider.java b/src/datagen/java/net/frozenblock/wilderwild/datagen/recipe/WWRecipeProvider.java index 6172da96bb..53cc2aaab9 100644 --- a/src/datagen/java/net/frozenblock/wilderwild/datagen/recipe/WWRecipeProvider.java +++ b/src/datagen/java/net/frozenblock/wilderwild/datagen/recipe/WWRecipeProvider.java @@ -38,7 +38,6 @@ import net.minecraft.data.recipes.ShapelessRecipeBuilder; import net.minecraft.data.recipes.SimpleCookingRecipeBuilder; import net.minecraft.data.recipes.SingleItemRecipeBuilder; -import net.minecraft.data.recipes.packs.VanillaRecipeProvider; import net.minecraft.world.item.Items; import net.minecraft.world.item.crafting.Ingredient; import net.minecraft.world.level.ItemLike; @@ -205,6 +204,15 @@ public void buildRecipes(RecipeOutput exporter) { .unlockedBy("has_moss_block", has(Blocks.MOSS_BLOCK)) .save(exporter, getConversionRecipeName(RegisterBlocks.MOSSY_MUD_BRICKS, Blocks.MOSS_BLOCK)); + stairBuilder( + RegisterBlocks.MOSSY_MUD_BRICK_STAIRS, + Ingredient.of(RegisterBlocks.MOSSY_MUD_BRICKS) + ).unlockedBy(getHasName(RegisterBlocks.MOSSY_MUD_BRICKS), has(RegisterBlocks.MOSSY_MUD_BRICKS)).save(exporter); + + slab(exporter, RecipeCategory.BUILDING_BLOCKS, RegisterBlocks.MOSSY_MUD_BRICK_SLAB, RegisterBlocks.MOSSY_MUD_BRICKS); + + wall(exporter, RecipeCategory.MISC, RegisterBlocks.MOSSY_MUD_BRICK_WALL, RegisterBlocks.MOSSY_MUD_BRICKS); + stonecutterResultFromBase(exporter, RecipeCategory.BUILDING_BLOCKS, RegisterBlocks.MOSSY_MUD_BRICK_SLAB, RegisterBlocks.MOSSY_MUD_BRICKS, 2); stonecutterResultFromBase(exporter, RecipeCategory.BUILDING_BLOCKS, RegisterBlocks.MOSSY_MUD_BRICK_STAIRS, RegisterBlocks.MOSSY_MUD_BRICKS); stonecutterResultFromBase(exporter, RecipeCategory.DECORATIONS, RegisterBlocks.MOSSY_MUD_BRICK_WALL, RegisterBlocks.MOSSY_MUD_BRICKS); diff --git a/src/datagen/java/net/frozenblock/wilderwild/datagen/tag/WWBlockTagProvider.java b/src/datagen/java/net/frozenblock/wilderwild/datagen/tag/WWBlockTagProvider.java index b311ff70dd..81a0980f22 100644 --- a/src/datagen/java/net/frozenblock/wilderwild/datagen/tag/WWBlockTagProvider.java +++ b/src/datagen/java/net/frozenblock/wilderwild/datagen/tag/WWBlockTagProvider.java @@ -21,6 +21,7 @@ import java.util.concurrent.CompletableFuture; import net.fabricmc.fabric.api.datagen.v1.FabricDataOutput; import net.fabricmc.fabric.api.datagen.v1.provider.FabricTagProvider; +import net.fabricmc.fabric.api.tag.convention.v2.ConventionalBlockTags; import net.frozenblock.lib.tag.api.FrozenBlockTags; import net.frozenblock.wilderwild.registry.RegisterBlocks; import net.frozenblock.wilderwild.tag.WilderBlockTags; @@ -56,6 +57,9 @@ private TagKey getTag(String id) { } private void generateCompat() { + this.getOrCreateTagBuilder(ConventionalBlockTags.CHESTS) + .add(RegisterBlocks.STONE_CHEST); + this.getOrCreateTagBuilder(getTag("c:stripped_logs")) .add(RegisterBlocks.STRIPPED_BAOBAB_LOG) .add(RegisterBlocks.STRIPPED_CYPRESS_LOG) diff --git a/src/main/generated/data/c/tags/block/chests.json b/src/main/generated/data/c/tags/block/chests.json new file mode 100644 index 0000000000..2fcd843e4a --- /dev/null +++ b/src/main/generated/data/c/tags/block/chests.json @@ -0,0 +1,5 @@ +{ + "values": [ + "wilderwild:stone_chest" + ] +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_slab.json b/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_slab.json new file mode 100644 index 0000000000..8446d59ec8 --- /dev/null +++ b/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_slab.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_mossy_mud_bricks": { + "conditions": { + "items": [ + { + "items": "wilderwild:mossy_mud_bricks" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "wilderwild:mossy_mud_brick_slab" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_mossy_mud_bricks" + ] + ], + "rewards": { + "recipes": [ + "wilderwild:mossy_mud_brick_slab" + ] + } +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_stairs.json b/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_stairs.json new file mode 100644 index 0000000000..7b7851ea21 --- /dev/null +++ b/src/main/generated/data/wilderwild/advancement/recipes/building_blocks/mossy_mud_brick_stairs.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_mossy_mud_bricks": { + "conditions": { + "items": [ + { + "items": "wilderwild:mossy_mud_bricks" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "wilderwild:mossy_mud_brick_stairs" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_mossy_mud_bricks" + ] + ], + "rewards": { + "recipes": [ + "wilderwild:mossy_mud_brick_stairs" + ] + } +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/advancement/recipes/misc/mossy_mud_brick_wall.json b/src/main/generated/data/wilderwild/advancement/recipes/misc/mossy_mud_brick_wall.json new file mode 100644 index 0000000000..f875c2930c --- /dev/null +++ b/src/main/generated/data/wilderwild/advancement/recipes/misc/mossy_mud_brick_wall.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_mossy_mud_bricks": { + "conditions": { + "items": [ + { + "items": "wilderwild:mossy_mud_bricks" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "wilderwild:mossy_mud_brick_wall" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_mossy_mud_bricks" + ] + ], + "rewards": { + "recipes": [ + "wilderwild:mossy_mud_brick_wall" + ] + } +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_slab.json b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_slab.json new file mode 100644 index 0000000000..154994fc95 --- /dev/null +++ b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_slab.json @@ -0,0 +1,16 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "building", + "key": { + "#": { + "item": "wilderwild:mossy_mud_bricks" + } + }, + "pattern": [ + "###" + ], + "result": { + "count": 6, + "id": "wilderwild:mossy_mud_brick_slab" + } +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_stairs.json b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_stairs.json new file mode 100644 index 0000000000..53c32ba19b --- /dev/null +++ b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_stairs.json @@ -0,0 +1,18 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "building", + "key": { + "#": { + "item": "wilderwild:mossy_mud_bricks" + } + }, + "pattern": [ + "# ", + "## ", + "###" + ], + "result": { + "count": 4, + "id": "wilderwild:mossy_mud_brick_stairs" + } +} \ No newline at end of file diff --git a/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_wall.json b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_wall.json new file mode 100644 index 0000000000..96ca81e91a --- /dev/null +++ b/src/main/generated/data/wilderwild/recipe/mossy_mud_brick_wall.json @@ -0,0 +1,17 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "#": { + "item": "wilderwild:mossy_mud_bricks" + } + }, + "pattern": [ + "###", + "###" + ], + "result": { + "count": 6, + "id": "wilderwild:mossy_mud_brick_wall" + } +} \ No newline at end of file diff --git a/src/main/java/net/frozenblock/wilderwild/config/WorldgenConfig.java b/src/main/java/net/frozenblock/wilderwild/config/WorldgenConfig.java index dd90de2b2c..39c35fdf7f 100644 --- a/src/main/java/net/frozenblock/wilderwild/config/WorldgenConfig.java +++ b/src/main/java/net/frozenblock/wilderwild/config/WorldgenConfig.java @@ -115,6 +115,9 @@ public void onSync(WorldgenConfig sync) { @EntrySyncData("newWitchHuts") public boolean newWitchHuts = true; + @EntrySyncData("decayTrailRuins") + public boolean decayTrailRuins = true; + public static WorldgenConfig get() { return get(false); } diff --git a/src/main/java/net/frozenblock/wilderwild/config/gui/WorldgenConfigGui.java b/src/main/java/net/frozenblock/wilderwild/config/gui/WorldgenConfigGui.java index b208f5d58a..45a8092296 100644 --- a/src/main/java/net/frozenblock/wilderwild/config/gui/WorldgenConfigGui.java +++ b/src/main/java/net/frozenblock/wilderwild/config/gui/WorldgenConfigGui.java @@ -655,6 +655,19 @@ public static void setupEntries(@NotNull ConfigCategory category, @NotNull Confi configInstance ) ); + var decayTrailRuins = category.addEntry( + FrozenClothConfig.syncedEntry( + entryBuilder.startBooleanToggle(text("decay_trail_ruins"), modifiedConfig.decayTrailRuins) + .setDefaultValue(defaultConfig.decayTrailRuins) + .setSaveConsumer(newValue -> config.decayTrailRuins = newValue) + .setTooltip(tooltip("decay_trail_ruins")) + .requireRestart() + .build(), + clazz, + "decayTrailRuins", + configInstance + ) + ); var newWitchHuts = category.addEntry( FrozenClothConfig.syncedEntry( entryBuilder.startBooleanToggle(text("new_witch_huts"), modifiedConfig.newWitchHuts) diff --git a/src/main/java/net/frozenblock/wilderwild/mod_compat/FrozenLibIntegration.java b/src/main/java/net/frozenblock/wilderwild/mod_compat/FrozenLibIntegration.java index b55ae12cb3..d062f2ebac 100644 --- a/src/main/java/net/frozenblock/wilderwild/mod_compat/FrozenLibIntegration.java +++ b/src/main/java/net/frozenblock/wilderwild/mod_compat/FrozenLibIntegration.java @@ -55,6 +55,7 @@ import net.frozenblock.wilderwild.config.AmbienceAndMiscConfig; import net.frozenblock.wilderwild.config.BlockConfig; import net.frozenblock.wilderwild.config.EntityConfig; +import net.frozenblock.wilderwild.config.WorldgenConfig; import net.frozenblock.wilderwild.entity.Firefly; import net.frozenblock.wilderwild.registry.RegisterBlockEntities; import net.frozenblock.wilderwild.registry.RegisterBlockSoundTypes; @@ -309,25 +310,27 @@ public void init() { BlockEntityWithoutLevelRendererRegistry.register(RegisterBlocks.STONE_CHEST, RegisterBlockEntities.STONE_CHEST); - StructureProcessorApi.addProcessor( - BuiltinStructures.TRAIL_RUINS.location(), - new RuleProcessor( - ImmutableList.of( - new ProcessorRule(new RandomBlockMatchTest(MUD_BRICKS, 0.2F), AlwaysTrueTest.INSTANCE, CRACKED_MUD_BRICKS.defaultBlockState()), - new ProcessorRule(new RandomBlockMatchTest(MUD_BRICKS, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICKS.defaultBlockState()) + if (WorldgenConfig.get().decayTrailRuins) { + StructureProcessorApi.addProcessor( + BuiltinStructures.TRAIL_RUINS.location(), + new RuleProcessor( + ImmutableList.of( + new ProcessorRule(new RandomBlockMatchTest(MUD_BRICKS, 0.2F), AlwaysTrueTest.INSTANCE, CRACKED_MUD_BRICKS.defaultBlockState()), + new ProcessorRule(new RandomBlockMatchTest(MUD_BRICKS, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICKS.defaultBlockState()) + ) ) - ) - ); - StructureProcessorApi.addProcessor( - BuiltinStructures.TRAIL_RUINS.location(), - new BlockStateRespectingRuleProcessor( - ImmutableList.of( - new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_STAIRS, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_STAIRS), - new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_SLAB, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_SLAB), - new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_SLAB, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_WALL) + ); + StructureProcessorApi.addProcessor( + BuiltinStructures.TRAIL_RUINS.location(), + new BlockStateRespectingRuleProcessor( + ImmutableList.of( + new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_STAIRS, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_STAIRS), + new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_SLAB, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_SLAB), + new BlockStateRespectingProcessorRule(new RandomBlockMatchTest(MUD_BRICK_SLAB, 0.05F), AlwaysTrueTest.INSTANCE, MOSSY_MUD_BRICK_WALL) + ) ) - ) - ); + ); + } if (EntityConfig.get().scorched.scorchedInTrialChambers) { RandomPoolAliasApi.addTarget( diff --git a/src/main/resources/assets/wilderwild/lang/en_us.json b/src/main/resources/assets/wilderwild/lang/en_us.json index 45b460dc11..46239f4867 100644 --- a/src/main/resources/assets/wilderwild/lang/en_us.json +++ b/src/main/resources/assets/wilderwild/lang/en_us.json @@ -617,6 +617,8 @@ "tooltip.wilderwild.mushroom_generation": "Whether worldgen should use Wilder Wild's or Vanilla's Mushroom generation.", "option.wilderwild.nether_geyser_generation": "Nether Geyser Generation", "tooltip.wilderwild.nether_geyser_generation": "Whether Geysers should naturally generate in the Nether.", + "option.wilderwild.decay_trail_ruins": "Decay Trail Ruins", + "tooltip.wilderwild.decay_trail_ruins": "Whether Trail Ruins can generate with Mossy and Cracked Mud Bricks.", "option.wilderwild.new_witch_huts": "New Witch Huts", "tooltip.wilderwild.new_witch_huts": "Whether Witch Huts should use a Cypress and Mangrove wood set.", "option.wilderwild.snapped_trees": "Snapped Trees",