From c962586cbeea761bb5d16b8f1426a5abecc20d47 Mon Sep 17 00:00:00 2001 From: Zepalesque <60141811+Zepalesque@users.noreply.github.com> Date: Sun, 5 Jan 2025 15:46:09 -0500 Subject: [PATCH] feat: Shaderoot Trees --- .../zepalesque/redux/block/ReduxBlocks.java | 6 +++ .../blockset/flower/ReduxFlowerSets.java | 7 ++++ .../redux/client/particle/ReduxParticles.java | 2 + .../redux/data/gen/ReduxBlockStateData.java | 3 ++ .../redux/data/gen/ReduxItemModelData.java | 3 ++ .../redux/data/gen/ReduxLanguageData.java | 6 +++ .../redux/data/gen/ReduxMapData.java | 2 + .../redux/data/gen/ReduxRecipeData.java | 4 +- .../redux/data/gen/loot/ReduxBlockLoot.java | 14 ++++++- .../data/resource/builders/biome/Blight.java | 7 +++- .../registries/ReduxFeatureConfig.java | 38 ++++++++++++++++++- .../resource/registries/ReduxPlacements.java | 18 +++++++++ .../net/zepalesque/redux/item/ReduxTabs.java | 4 +- .../redux/world/tree/ReduxTreeGrowers.java | 12 ++++++ 14 files changed, 119 insertions(+), 7 deletions(-) diff --git a/src/main/java/net/zepalesque/redux/block/ReduxBlocks.java b/src/main/java/net/zepalesque/redux/block/ReduxBlocks.java index 436f9f667..7ec9a62b9 100644 --- a/src/main/java/net/zepalesque/redux/block/ReduxBlocks.java +++ b/src/main/java/net/zepalesque/redux/block/ReduxBlocks.java @@ -56,6 +56,12 @@ public class ReduxBlocks extends ReduxBlockBuilders { public static DeferredBlock GILDENROOT_LEAF_PILE = register("gildenroot_leaf_pile", () -> new LeafPileBlock(GILDENROOT_LEAVES)); + public static DeferredBlock SHADEROOT_LEAVES = register("shaderoot_leaves", + () -> new FallingLeavesBlock(ReduxParticles.SHADEROOT_LEAF, Properties.ofFullCopy(AetherBlocks.SKYROOT_LEAVES.get()).mapColor(MapColor.TERRACOTTA_PURPLE))); + + public static DeferredBlock SHADEROOT_LEAF_PILE = register("shaderoot_leaf_pile", + () -> new LeafPileBlock(SHADEROOT_LEAVES)); + public static DeferredBlock GOLDEN_CLOVERS = register("golden_clovers", () -> new GoldenCloversBlock(BlockBehaviour.Properties.of() .mapColor(MapColor.GOLD) diff --git a/src/main/java/net/zepalesque/redux/blockset/flower/ReduxFlowerSets.java b/src/main/java/net/zepalesque/redux/blockset/flower/ReduxFlowerSets.java index 9a1417a8b..7d21f190d 100644 --- a/src/main/java/net/zepalesque/redux/blockset/flower/ReduxFlowerSets.java +++ b/src/main/java/net/zepalesque/redux/blockset/flower/ReduxFlowerSets.java @@ -44,6 +44,13 @@ public class ReduxFlowerSets { .compost(0.3F) .withLore("The sapling of the Gildenroot tree. It can be grown by waiting or using Bone Meal.")); + public static final BaseFlowerSet SHADEROOT_SAPLING = register(new UntintedFlowerSet<>("shaderoot_sapling", "natural/", + () -> new SaplingBlock(ReduxTreeGrowers.SHADEROOT, Properties.ofFullCopy(Blocks.OAK_SAPLING).mapColor(MapColor.TERRACOTTA_PURPLE))) + .tabAfter(AetherCreativeTabs.AETHER_NATURAL_BLOCKS, () -> ReduxFlowerSets.GILDENROOT_SAPLING.flower().get(), BlockSet.TabAdditionPhase.BEFORE) + .withFlowerTag(BlockTags.SAPLINGS) + .compost(0.3F) + .withLore("The sapling of the Gildenroot tree. It can be grown by waiting or using Bone Meal.")); + public static final BaseFlowerSet LUCKY_CLOVER = register(new CloverSet<>("lucky_clover", "natural/", () -> new CustomBoundsBushBlock(Block.box(5.0D, 0.0D, 5.0D, 11.0D, 10.0D, 11.0D), Properties.ofFullCopy(Blocks.DANDELION).mapColor(MapColor.GOLD))) .tabAfter(AetherCreativeTabs.AETHER_NATURAL_BLOCKS, ReduxBlocks.GOLDEN_CLOVERS, BlockSet.TabAdditionPhase.AFTER) diff --git a/src/main/java/net/zepalesque/redux/client/particle/ReduxParticles.java b/src/main/java/net/zepalesque/redux/client/particle/ReduxParticles.java index 0e428c1ca..dcd224958 100644 --- a/src/main/java/net/zepalesque/redux/client/particle/ReduxParticles.java +++ b/src/main/java/net/zepalesque/redux/client/particle/ReduxParticles.java @@ -26,6 +26,7 @@ public class ReduxParticles { public static final DeferredRegister> PARTICLES = DeferredRegister.create(BuiltInRegistries.PARTICLE_TYPE, Redux.MODID); public static final DeferredHolder, SimpleParticleType> GILDENROOT_LEAF = PARTICLES.register("gildenroot_leaf", () -> new SimpleParticleType(false)); + public static final DeferredHolder, SimpleParticleType> SHADEROOT_LEAF = PARTICLES.register("shaderoot_leaf", () -> new SimpleParticleType(false)); public static final DeferredHolder, SimpleParticleType> WHIRLWIND_LIGHTNING = PARTICLES.register("whirlwind_lightning", () -> new SimpleParticleType(false)); public static final DeferredHolder, SimpleParticleType> SPARK = PARTICLES.register("spark", () -> new SimpleParticleType(false)); @@ -34,6 +35,7 @@ public class ReduxParticles { @OnlyIn(Dist.CLIENT) public static void registerParticleFactories(RegisterParticleProvidersEvent event) { event.registerSpriteSet(GILDENROOT_LEAF.get(), ReduxLeafParticle.Provider::new); + event.registerSpriteSet(SHADEROOT_LEAF.get(), ReduxLeafParticle.Provider::new); event.registerSpriteSet(WHIRLWIND_LIGHTNING.get(), ReduxGlowParticle.Lightning::new); event.registerSpriteSet(SPARK.get(), SparkParticle.Provider::new); diff --git a/src/main/java/net/zepalesque/redux/data/gen/ReduxBlockStateData.java b/src/main/java/net/zepalesque/redux/data/gen/ReduxBlockStateData.java index f5a333446..5e84db58d 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/ReduxBlockStateData.java +++ b/src/main/java/net/zepalesque/redux/data/gen/ReduxBlockStateData.java @@ -24,6 +24,9 @@ protected void registerStatesAndModels() { this.block(ReduxBlocks.GILDENROOT_LEAVES.get(), "natural/"); this.leafPile(ReduxBlocks.GILDENROOT_LEAF_PILE.get(), ReduxBlocks.GILDENROOT_LEAVES.get(), "natural/"); + this.block(ReduxBlocks.SHADEROOT_LEAVES.get(), "natural/"); + this.leafPile(ReduxBlocks.SHADEROOT_LEAF_PILE.get(), ReduxBlocks.SHADEROOT_LEAVES.get(), "natural/"); + this.pillar(ReduxBlocks.CARVED_PILLAR.get(), "dungeon/"); this.pillar(ReduxBlocks.SENTRY_PILLAR.get(), "dungeon/"); this.baseBrick(ReduxBlocks.CARVED_BASE.get(), "dungeon/"); diff --git a/src/main/java/net/zepalesque/redux/data/gen/ReduxItemModelData.java b/src/main/java/net/zepalesque/redux/data/gen/ReduxItemModelData.java index 42c0f0e6e..bbdc6fa93 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/ReduxItemModelData.java +++ b/src/main/java/net/zepalesque/redux/data/gen/ReduxItemModelData.java @@ -22,6 +22,9 @@ protected void registerModels() { this.itemBlock(ReduxBlocks.GILDENROOT_LEAVES.get()); this.leafPile(ReduxBlocks.GILDENROOT_LEAF_PILE.get()); + this.itemBlock(ReduxBlocks.SHADEROOT_LEAVES.get()); + this.leafPile(ReduxBlocks.SHADEROOT_LEAF_PILE.get()); + this.itemBlock(ReduxBlocks.CARVED_BASE.get()); this.itemBlock(ReduxBlocks.CARVED_PILLAR.get()); this.itemBlock(ReduxBlocks.SENTRY_BASE.get()); diff --git a/src/main/java/net/zepalesque/redux/data/gen/ReduxLanguageData.java b/src/main/java/net/zepalesque/redux/data/gen/ReduxLanguageData.java index c65dd401e..d3dc97be4 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/ReduxLanguageData.java +++ b/src/main/java/net/zepalesque/redux/data/gen/ReduxLanguageData.java @@ -26,6 +26,12 @@ protected void addTranslations() { addBlock(ReduxBlocks.GILDENROOT_LEAF_PILE); addLore(ReduxBlocks.GILDENROOT_LEAF_PILE, "A pile of Gildenroot Leaves. These can be stacked on top of eachother to make various sizes!"); + addBlock(ReduxBlocks.SHADEROOT_LEAVES); + addLore(ReduxBlocks.SHADEROOT_LEAVES, "Leaves of the Shaderoot tree, a corrupted variation of Skyroot that has been inflicted by the Blight."); + + addBlock(ReduxBlocks.SHADEROOT_LEAF_PILE); + addLore(ReduxBlocks.SHADEROOT_LEAF_PILE, "A pile of Shaderoot Leaves. These can be stacked on top of eachother to make various sizes!"); + addBlock(ReduxBlocks.GOLDEN_CLOVERS); addLore(ReduxBlocks.GOLDEN_CLOVERS, "A nice patch of clovers that can be found in the Gilded Groves."); diff --git a/src/main/java/net/zepalesque/redux/data/gen/ReduxMapData.java b/src/main/java/net/zepalesque/redux/data/gen/ReduxMapData.java index ca60a200d..3573ac164 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/ReduxMapData.java +++ b/src/main/java/net/zepalesque/redux/data/gen/ReduxMapData.java @@ -31,6 +31,8 @@ protected void gather() { var compostables = this.builder(NeoForgeDataMaps.COMPOSTABLES); this.addCompost(compostables, ReduxBlocks.GILDENROOT_LEAVES, 0.3F); this.addCompost(compostables, ReduxBlocks.GILDENROOT_LEAF_PILE, 0.05F); + this.addCompost(compostables, ReduxBlocks.SHADEROOT_LEAVES, 0.3F); + this.addCompost(compostables, ReduxBlocks.SHADEROOT_LEAF_PILE, 0.05F); this.addCompost(compostables, ReduxItems.WYND_OATS, 0.3F); this.addCompost(compostables, ReduxBlocks.WYNDSPROUTS, 0.3F); this.addCompost(compostables, ReduxItems.WYND_OAT_PANICLE, 0.65F); diff --git a/src/main/java/net/zepalesque/redux/data/gen/ReduxRecipeData.java b/src/main/java/net/zepalesque/redux/data/gen/ReduxRecipeData.java index 8ed511b6e..4c76db610 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/ReduxRecipeData.java +++ b/src/main/java/net/zepalesque/redux/data/gen/ReduxRecipeData.java @@ -48,6 +48,9 @@ protected void buildRecipes(@NotNull RecipeOutput output) { enchantingRecipe(RecipeCategory.DECORATIONS, ReduxFlowerSets.GILDENROOT_SAPLING.flower().get(), AetherBlocks.SKYROOT_SAPLING.get(), 0.1F, 1000).save(output); ambrosiumEnchanting(ReduxBlocks.GILDENROOT_LEAVES.get(), AetherBlocks.SKYROOT_LEAVES.get()).save(output); + layerBlock(output, ReduxBlocks.GILDENROOT_LEAF_PILE.get(), ReduxBlocks.GILDENROOT_LEAVES.get(), 6); + + layerBlock(output, ReduxBlocks.SHADEROOT_LEAF_PILE.get(), ReduxBlocks.SHADEROOT_LEAVES.get(), 6); stonecuttingRecipe(output, RecipeCategory.BUILDING_BLOCKS, ReduxBlocks.CARVED_BASE.get(), AetherBlocks.CARVED_STONE.get()); stonecuttingRecipe(output, RecipeCategory.BUILDING_BLOCKS, ReduxBlocks.CARVED_PILLAR.get(), AetherBlocks.CARVED_STONE.get()); @@ -217,6 +220,5 @@ protected void buildRecipes(@NotNull RecipeOutput output) { oreBlockStorageRecipesRecipesWithCustomUnpacking(output, RecipeCategory.MISC, ReduxItems.REFINED_SENTRITE.get(), RecipeCategory.BUILDING_BLOCKS, ReduxBlocks.REFINED_SENTRITE_BLOCK.get(), "refined_sentrite_from_refined_sentrite_block", "refined_sentrite"); - layerBlock(output, ReduxBlocks.GILDENROOT_LEAF_PILE.get(), ReduxBlocks.GILDENROOT_LEAVES.get(), 6); } } diff --git a/src/main/java/net/zepalesque/redux/data/gen/loot/ReduxBlockLoot.java b/src/main/java/net/zepalesque/redux/data/gen/loot/ReduxBlockLoot.java index 8bcb15cf3..5569613ca 100644 --- a/src/main/java/net/zepalesque/redux/data/gen/loot/ReduxBlockLoot.java +++ b/src/main/java/net/zepalesque/redux/data/gen/loot/ReduxBlockLoot.java @@ -34,10 +34,20 @@ protected void generate() { Redux.BLOCK_SETS.forEach(set -> set.lootData(this)); this.add(ReduxBlocks.GILDENROOT_LEAVES.get(), - (leaves) -> droppingWithChancesAndSkyrootSticks(leaves, ReduxFlowerSets.GILDENROOT_SAPLING.flower().get(), BlockLootAccessor.aether$getNormalLeavesSaplingChances())); - + (leaves) -> droppingWithChancesAndSkyrootSticks( + leaves, ReduxFlowerSets.GILDENROOT_SAPLING.flower().get(), + BlockLootAccessor.aether$getNormalLeavesSaplingChances()) + ); this.add(ReduxBlocks.GILDENROOT_LEAF_PILE.get(), shears()); + this.add(ReduxBlocks.SHADEROOT_LEAVES.get(), + (leaves) -> droppingWithChancesAndSkyrootSticks( + leaves, ReduxFlowerSets.SHADEROOT_SAPLING.flower().get(), + BlockLootAccessor.aether$getNormalLeavesSaplingChances()) + ); + this.add(ReduxBlocks.SHADEROOT_LEAF_PILE.get(), shears()); + + this.dropSelf(ReduxBlocks.CARVED_PILLAR.get()); this.dropSelf(ReduxBlocks.SENTRY_PILLAR.get()); this.dropSelf(ReduxBlocks.CARVED_BASE.get()); diff --git a/src/main/java/net/zepalesque/redux/data/resource/builders/biome/Blight.java b/src/main/java/net/zepalesque/redux/data/resource/builders/biome/Blight.java index 9167ba4f2..2141c7518 100644 --- a/src/main/java/net/zepalesque/redux/data/resource/builders/biome/Blight.java +++ b/src/main/java/net/zepalesque/redux/data/resource/builders/biome/Blight.java @@ -36,9 +36,11 @@ public static Biome generate(BootstrapContext context) { .grassColorOverride(0xb1_ff_cb) .foliageColorOverride(0xb1_ff_cb) .grassColorModifier(BiomeSpecialEffects.GrassColorModifier.NONE) + // TODO: Consider doing some music stuff .backgroundMusic(ReduxMusic.DEFAULT_AETHER_MUSIC) .build()) .mobSpawnSettings( + // TODO: Blight spawns new MobSpawnSettings.Builder() .addMobCharge(AetherEntityTypes.COCKATRICE.get(), 0.5, 0.15) .addMobCharge(AetherEntityTypes.ZEPHYR.get(), 0.6, 0.16) @@ -72,6 +74,7 @@ public static Biome generate(BootstrapContext context) { .addFeature(GenerationStep.Decoration.LAKES, ReduxPlacements.SURFACE_RULE_WATER_LAKE) + // TODO: Ore balancing .addFeature(GenerationStep.Decoration.UNDERGROUND_ORES, AetherPlacedFeatures.ORE_AETHER_DIRT_PLACEMENT) .addFeature(GenerationStep.Decoration.UNDERGROUND_ORES, AetherPlacedFeatures.ORE_ICESTONE_PLACEMENT) .addFeature(GenerationStep.Decoration.UNDERGROUND_ORES, AetherPlacedFeatures.ORE_AMBROSIUM_PLACEMENT) @@ -81,7 +84,8 @@ public static Biome generate(BootstrapContext context) { .addFeature(GenerationStep.Decoration.FLUID_SPRINGS, AetherPlacedFeatures.WATER_SPRING_PLACEMENT) - .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.SKYROOT_FOREST_TREES_PLACEMENT) + // TODO: Blight plants + .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ReduxPlacements.BLIGHT_TREES) .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.HOLIDAY_TREE_PLACEMENT) .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.GRASS_PATCH_PLACEMENT) .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.TALL_GRASS_PATCH_PLACEMENT) @@ -89,6 +93,7 @@ public static Biome generate(BootstrapContext context) { .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.PURPLE_FLOWER_PATCH_PLACEMENT) .addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, AetherPlacedFeatures.BERRY_BUSH_PATCH_PLACEMENT) + // TODO: Aercloud balancing .addFeature(GenerationStep.Decoration.TOP_LAYER_MODIFICATION, AetherPlacedFeatures.CRYSTAL_ISLAND_PLACEMENT) .addFeature(GenerationStep.Decoration.TOP_LAYER_MODIFICATION, AetherPlacedFeatures.COLD_AERCLOUD_PLACEMENT) .addFeature(GenerationStep.Decoration.TOP_LAYER_MODIFICATION, AetherPlacedFeatures.BLUE_AERCLOUD_PLACEMENT) diff --git a/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxFeatureConfig.java b/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxFeatureConfig.java index 6adbe0bfe..81648bc74 100644 --- a/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxFeatureConfig.java +++ b/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxFeatureConfig.java @@ -87,6 +87,8 @@ public class ReduxFeatureConfig extends ReduxFeatureBuilders { public static final ResourceKey> GROVE_TREES = createKey("gilded_groves_trees"); + public static final ResourceKey> BLIGHT_TREES = createKey("the_blight_trees"); + public static final ResourceKey> SURFACE_RULE_WATER_LAKE = createKey("surface_rule_water_lake"); public static final ResourceKey> AMBROSIUM_ROCK = createKey("ambrosium_rock"); @@ -96,6 +98,9 @@ public class ReduxFeatureConfig extends ReduxFeatureBuilders { public static final ResourceKey> BLEAKMOSS_VEGETATION = createKey("bleakmoss_vegetation"); public static final ResourceKey> BLEAKMOSS_BONEMEAL = createKey("bleakmoss_bonemeal"); + public static final ResourceKey> SMALL_SHADEROOT_TREE = createKey("small_shaderoot"); + + // Overrides public static final ResourceKey> CRYSTAL_TREE = AetherConfiguredFeatures.CRYSTAL_TREE_CONFIGURATION; public static final ResourceKey> SKYROOT_TREE = AetherConfiguredFeatures.SKYROOT_TREE_CONFIGURATION; @@ -126,6 +131,15 @@ public static void bootstrap(BootstrapContext> context) new TwoLayersFeatureSize(1, 0, 1) ).ignoreVines().build()); + register(context, SMALL_SHADEROOT_TREE, Feature.TREE, + new TreeConfiguration.TreeConfigurationBuilder( + BlockStateProvider.simple(AetherFeatureStates.SKYROOT_LOG), + new StraightTrunkPlacer(4, 2, 0), + prov(ReduxBlocks.SHADEROOT_LEAVES), + new SkyrootFoliagePlacer(ConstantInt.of(2), ConstantInt.of(0)), + new TwoLayersFeatureSize(1, 0, 1) + ).ignoreVines().build()); + register(context, LARGE_GILDENROOT_TREE, Feature.TREE, new TreeConfiguration.TreeConfigurationBuilder( BlockStateProvider.simple(AetherFeatureStates.SKYROOT_LOG), @@ -210,8 +224,28 @@ public static void bootstrap(BootstrapContext> context) register(context, GROVE_TREES, Feature.RANDOM_SELECTOR, new RandomFeatureConfiguration(List.of( - new WeightedPlacedFeature(PlacementUtils.inlinePlaced(configs.getOrThrow(GROVE_GILDED_TREES), PlacementUtils.filteredByBlockSurvival(ReduxFlowerSets.GILDENROOT_SAPLING.flower().get())), 0.375F)), - PlacementUtils.inlinePlaced(configs.getOrThrow(GROVE_GOLDEN_TREES), PlacementUtils.filteredByBlockSurvival(AetherBlocks.GOLDEN_OAK_SAPLING.get())))); + new WeightedPlacedFeature( + PlacementUtils.inlinePlaced( + configs.getOrThrow(GROVE_GILDED_TREES), + PlacementUtils.filteredByBlockSurvival(ReduxFlowerSets.GILDENROOT_SAPLING.flower().get())) + , 0.375F)), + PlacementUtils.inlinePlaced( + configs.getOrThrow(GROVE_GOLDEN_TREES), + PlacementUtils.filteredByBlockSurvival(AetherBlocks.GOLDEN_OAK_SAPLING.get()) + ))); + + register(context, BLIGHT_TREES, Feature.RANDOM_SELECTOR, + new RandomFeatureConfiguration(List.of( + new WeightedPlacedFeature( + PlacementUtils.inlinePlaced( + configs.getOrThrow(SMALL_SHADEROOT_TREE), + PlacementUtils.filteredByBlockSurvival(ReduxFlowerSets.SHADEROOT_SAPLING.flower().get())) + , 0.375F)), + // TODO: Blightwillow + PlacementUtils.inlinePlaced( + configs.getOrThrow(SMALL_SHADEROOT_TREE), + PlacementUtils.filteredByBlockSurvival(AetherBlocks.GOLDEN_OAK_SAPLING.get()) + ))); register(context, SENTRITE_ORE, Feature.ORE, new OreConfiguration(new TagMatchTest(AetherTags.Blocks.HOLYSTONE), drops(ReduxStoneSets.SENTRITE.block()), 48, 0.0F)); diff --git a/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxPlacements.java b/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxPlacements.java index 89c7e9533..4397647c9 100644 --- a/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxPlacements.java +++ b/src/main/java/net/zepalesque/redux/data/resource/registries/ReduxPlacements.java @@ -34,6 +34,7 @@ import net.minecraft.world.level.levelgen.placement.PlacedFeature; import net.minecraft.world.level.levelgen.placement.RarityFilter; import net.zepalesque.redux.block.ReduxBlocks; +import net.zepalesque.redux.blockset.flower.ReduxFlowerSets; import net.zepalesque.redux.data.resource.builders.ReduxPlacementBuilders; public class ReduxPlacements extends ReduxPlacementBuilders { @@ -58,6 +59,10 @@ public class ReduxPlacements extends ReduxPlacementBuilders { public static final ResourceKey SURFACE_RULE_WATER_LAKE = copyKey(ReduxFeatureConfig.SURFACE_RULE_WATER_LAKE); public static final ResourceKey WYNDSPROUTS_PATCH = copyKey(ReduxFeatureConfig.WYNDSPROUTS_PATCH); + + public static final ResourceKey BLIGHT_TREES = copyKey(ReduxFeatureConfig.BLIGHT_TREES); + + public static final ResourceKey SPARSE_WYNDSPROUTS_PATCH = createKey("sparse_" + name(ReduxBlocks.WYNDSPROUTS) + "_patch"); public static final ResourceKey BONEMEAL_OVERRIDE = AetherPlacedFeatures.AETHER_GRASS_BONEMEAL; @@ -112,6 +117,19 @@ public static void bootstrap(BootstrapContext context) { blacklist ); + register(context, BLIGHT_TREES, configs.getOrThrow(ReduxFeatureConfig.BLIGHT_TREES), + CountPlacement.of(new WeightedListInt(SimpleWeightedRandomList.builder() + .add(ConstantInt.of(6), 9) + .add(ConstantInt.of(4), 3) + .add(ConstantInt.of(2), 5) + .add(ConstantInt.of(10), 1) + .build())), + ImprovedLayerPlacementModifier.of(Heightmap.Types.OCEAN_FLOOR, ConstantInt.of(2), 4), + BiomeFilter.biome(), + PlacementUtils.filteredByBlockSurvival(ReduxFlowerSets.SHADEROOT_SAPLING.flower().get()), + blacklist + ); + register(context, AURUM_PATCH, configs.getOrThrow(ReduxFeatureConfig.AURUM_PATCH), threshold, ImprovedLayerPlacementModifier.of(Heightmap.Types.MOTION_BLOCKING, UniformInt.of(0, 2), 4), diff --git a/src/main/java/net/zepalesque/redux/item/ReduxTabs.java b/src/main/java/net/zepalesque/redux/item/ReduxTabs.java index ad4423ccc..5b968509b 100644 --- a/src/main/java/net/zepalesque/redux/item/ReduxTabs.java +++ b/src/main/java/net/zepalesque/redux/item/ReduxTabs.java @@ -39,7 +39,9 @@ public static void buildCreativeModeTabs(BuildCreativeModeTabContentsEvent event TabUtil.putAfter(event, UnityBlocks.SKYROOT_LEAF_PILE, ReduxBlocks.GILDENROOT_LEAVES, - ReduxBlocks.GILDENROOT_LEAF_PILE + ReduxBlocks.GILDENROOT_LEAF_PILE, + ReduxBlocks.SHADEROOT_LEAVES, + ReduxBlocks.SHADEROOT_LEAF_PILE ); TabUtil.putAfter(event, ReduxFlowerSets.AURUM.flower(), ReduxBlocks.GOLDEN_CLOVERS); diff --git a/src/main/java/net/zepalesque/redux/world/tree/ReduxTreeGrowers.java b/src/main/java/net/zepalesque/redux/world/tree/ReduxTreeGrowers.java index a2e482755..e0bc711ed 100644 --- a/src/main/java/net/zepalesque/redux/world/tree/ReduxTreeGrowers.java +++ b/src/main/java/net/zepalesque/redux/world/tree/ReduxTreeGrowers.java @@ -17,4 +17,16 @@ public class ReduxTreeGrowers { Optional.empty(), Optional.empty() ); + + public static final TreeGrower SHADEROOT = new TreeGrower( + "gildenroot", + 0.3F, + Optional.empty(), + Optional.empty(), + Optional.of(ReduxFeatureConfig.SMALL_SHADEROOT_TREE), +// Optional.of(ReduxFeatureConfig.LARGE_GILDENROOT_TREE), + Optional.empty(), + Optional.empty(), + Optional.empty() + ); }