| 1 | package net.minecraft.data.worldgen.features;
|
| 2 |
|
| 3 | import java.util.List;
|
| 4 | import java.util.Optional;
|
| 5 | import java.util.OptionalInt;
|
| 6 | import net.minecraft.core.Direction;
|
| 7 | import net.minecraft.core.Holder;
|
| 8 | import net.minecraft.core.HolderGetter;
|
| 9 | import net.minecraft.core.HolderSet;
|
| 10 | import net.minecraft.core.registries.Registries;
|
| 11 | import net.minecraft.data.worldgen.BlockStateProviders;
|
| 12 | import net.minecraft.data.worldgen.BootstrapContext;
|
| 13 | import net.minecraft.resources.ResourceKey;
|
| 14 | import net.minecraft.tags.BlockTags;
|
| 15 | import net.minecraft.util.random.WeightedList;
|
| 16 | import net.minecraft.util.valueproviders.ConstantInt;
|
| 17 | import net.minecraft.util.valueproviders.IntProvider;
|
| 18 | import net.minecraft.util.valueproviders.UniformInt;
|
| 19 | import net.minecraft.util.valueproviders.WeightedListInt;
|
| 20 | import net.minecraft.world.level.block.Block;
|
| 21 | import net.minecraft.world.level.block.Blocks;
|
| 22 | import net.minecraft.world.level.block.HugeMushroomBlock;
|
| 23 | import net.minecraft.world.level.block.state.BlockState;
|
| 24 | import net.minecraft.world.level.levelgen.blockpredicates.BlockPredicate;
|
| 25 | import net.minecraft.world.level.levelgen.feature.FallenTreeFeature;
|
| 26 | import net.minecraft.world.level.levelgen.feature.Feature;
|
| 27 | import net.minecraft.world.level.levelgen.feature.HugeBrownMushroomFeature;
|
| 28 | import net.minecraft.world.level.levelgen.feature.HugeFungusFeature;
|
| 29 | import net.minecraft.world.level.levelgen.feature.HugeRedMushroomFeature;
|
| 30 | import net.minecraft.world.level.levelgen.feature.TreeFeature;
|
| 31 | import net.minecraft.world.level.levelgen.feature.featuresize.ThreeLayersFeatureSize;
|
| 32 | import net.minecraft.world.level.levelgen.feature.featuresize.TwoLayersFeatureSize;
|
| 33 | import net.minecraft.world.level.levelgen.feature.foliageplacers.AcaciaFoliagePlacer;
|
| 34 | import net.minecraft.world.level.levelgen.feature.foliageplacers.BlobFoliagePlacer;
|
| 35 | import net.minecraft.world.level.levelgen.feature.foliageplacers.BushFoliagePlacer;
|
| 36 | import net.minecraft.world.level.levelgen.feature.foliageplacers.CherryFoliagePlacer;
|
| 37 | import net.minecraft.world.level.levelgen.feature.foliageplacers.DarkOakFoliagePlacer;
|
| 38 | import net.minecraft.world.level.levelgen.feature.foliageplacers.FancyFoliagePlacer;
|
| 39 | import net.minecraft.world.level.levelgen.feature.foliageplacers.MegaJungleFoliagePlacer;
|
| 40 | import net.minecraft.world.level.levelgen.feature.foliageplacers.MegaPineFoliagePlacer;
|
| 41 | import net.minecraft.world.level.levelgen.feature.foliageplacers.PineFoliagePlacer;
|
| 42 | import net.minecraft.world.level.levelgen.feature.foliageplacers.PoplarFoliagePlacer;
|
| 43 | import net.minecraft.world.level.levelgen.feature.foliageplacers.RandomSpreadFoliagePlacer;
|
| 44 | import net.minecraft.world.level.levelgen.feature.foliageplacers.SpruceFoliagePlacer;
|
| 45 | import net.minecraft.world.level.levelgen.feature.rootplacers.AboveRootPlacement;
|
| 46 | import net.minecraft.world.level.levelgen.feature.rootplacers.MangroveRootPlacement;
|
| 47 | import net.minecraft.world.level.levelgen.feature.rootplacers.MangroveRootPlacer;
|
| 48 | import net.minecraft.world.level.levelgen.feature.stateproviders.BlockStateProvider;
|
| 49 | import net.minecraft.world.level.levelgen.feature.stateproviders.WeightedStateProvider;
|
| 50 | import net.minecraft.world.level.levelgen.feature.treedecorators.AlterGroundDecorator;
|
| 51 | import net.minecraft.world.level.levelgen.feature.treedecorators.AttachedToLeavesDecorator;
|
| 52 | import net.minecraft.world.level.levelgen.feature.treedecorators.AttachedToLogsDecorator;
|
| 53 | import net.minecraft.world.level.levelgen.feature.treedecorators.BeehiveDecorator;
|
| 54 | import net.minecraft.world.level.levelgen.feature.treedecorators.CocoaDecorator;
|
| 55 | import net.minecraft.world.level.levelgen.feature.treedecorators.CreakingHeartDecorator;
|
| 56 | import net.minecraft.world.level.levelgen.feature.treedecorators.LeaveVineDecorator;
|
| 57 | import net.minecraft.world.level.levelgen.feature.treedecorators.PaleMossDecorator;
|
| 58 | import net.minecraft.world.level.levelgen.feature.treedecorators.PlaceOnGroundDecorator;
|
| 59 | import net.minecraft.world.level.levelgen.feature.treedecorators.ShelfMushroomDecorator;
|
| 60 | import net.minecraft.world.level.levelgen.feature.treedecorators.TrunkVineDecorator;
|
| 61 | import net.minecraft.world.level.levelgen.feature.trunkplacers.BendingTrunkPlacer;
|
| 62 | import net.minecraft.world.level.levelgen.feature.trunkplacers.CherryTrunkPlacer;
|
| 63 | import net.minecraft.world.level.levelgen.feature.trunkplacers.DarkOakTrunkPlacer;
|
| 64 | import net.minecraft.world.level.levelgen.feature.trunkplacers.FancyTrunkPlacer;
|
| 65 | import net.minecraft.world.level.levelgen.feature.trunkplacers.ForkingTrunkPlacer;
|
| 66 | import net.minecraft.world.level.levelgen.feature.trunkplacers.GiantTrunkPlacer;
|
| 67 | import net.minecraft.world.level.levelgen.feature.trunkplacers.MegaJungleTrunkPlacer;
|
| 68 | import net.minecraft.world.level.levelgen.feature.trunkplacers.PoplarTrunkPlacer;
|
| 69 | import net.minecraft.world.level.levelgen.feature.trunkplacers.StraightTrunkPlacer;
|
| 70 | import net.minecraft.world.level.levelgen.feature.trunkplacers.UpwardsBranchingTrunkPlacer;
|
| 71 |
|
| 72 | public class TreeFeatures {
|
| 73 | public static final ResourceKey<Feature> CRIMSON_FUNGUS = FeatureUtils.createKey("crimson_fungus");
|
| 74 | public static final ResourceKey<Feature> CRIMSON_FUNGUS_PLANTED = FeatureUtils.createKey("crimson_fungus_planted");
|
| 75 | public static final ResourceKey<Feature> WARPED_FUNGUS = FeatureUtils.createKey("warped_fungus");
|
| 76 | public static final ResourceKey<Feature> WARPED_FUNGUS_PLANTED = FeatureUtils.createKey("warped_fungus_planted");
|
| 77 | public static final ResourceKey<Feature> HUGE_BROWN_MUSHROOM = FeatureUtils.createKey("huge_brown_mushroom");
|
| 78 | public static final ResourceKey<Feature> HUGE_RED_MUSHROOM = FeatureUtils.createKey("huge_red_mushroom");
|
| 79 | public static final ResourceKey<Feature> OAK = FeatureUtils.createKey("oak");
|
| 80 | public static final ResourceKey<Feature> DARK_OAK = FeatureUtils.createKey("dark_oak");
|
| 81 | public static final ResourceKey<Feature> PALE_OAK = FeatureUtils.createKey("pale_oak");
|
| 82 | public static final ResourceKey<Feature> PALE_OAK_BONEMEAL = FeatureUtils.createKey("pale_oak_bonemeal");
|
| 83 | public static final ResourceKey<Feature> PALE_OAK_CREAKING = FeatureUtils.createKey("pale_oak_creaking");
|
| 84 | public static final ResourceKey<Feature> BIRCH = FeatureUtils.createKey("birch");
|
| 85 | public static final ResourceKey<Feature> ACACIA = FeatureUtils.createKey("acacia");
|
| 86 | public static final ResourceKey<Feature> SPRUCE = FeatureUtils.createKey("spruce");
|
| 87 | public static final ResourceKey<Feature> PINE = FeatureUtils.createKey("pine");
|
| 88 | public static final ResourceKey<Feature> JUNGLE_TREE = FeatureUtils.createKey("jungle_tree");
|
| 89 | public static final ResourceKey<Feature> FANCY_OAK = FeatureUtils.createKey("fancy_oak");
|
| 90 | public static final ResourceKey<Feature> JUNGLE_TREE_NO_VINE = FeatureUtils.createKey("jungle_tree_no_vine");
|
| 91 | public static final ResourceKey<Feature> MEGA_JUNGLE_TREE = FeatureUtils.createKey("mega_jungle_tree");
|
| 92 | public static final ResourceKey<Feature> MEGA_SPRUCE = FeatureUtils.createKey("mega_spruce");
|
| 93 | public static final ResourceKey<Feature> MEGA_PINE = FeatureUtils.createKey("mega_pine");
|
| 94 | public static final ResourceKey<Feature> SUPER_BIRCH_BEES_0002 = FeatureUtils.createKey("super_birch_bees_0002");
|
| 95 | public static final ResourceKey<Feature> SUPER_BIRCH_BEES = FeatureUtils.createKey("super_birch_bees");
|
| 96 | public static final ResourceKey<Feature> SWAMP_OAK = FeatureUtils.createKey("swamp_oak");
|
| 97 | public static final ResourceKey<Feature> JUNGLE_BUSH = FeatureUtils.createKey("jungle_bush");
|
| 98 | public static final ResourceKey<Feature> AZALEA_TREE = FeatureUtils.createKey("azalea_tree");
|
| 99 | public static final ResourceKey<Feature> MANGROVE = FeatureUtils.createKey("mangrove");
|
| 100 | public static final ResourceKey<Feature> TALL_MANGROVE = FeatureUtils.createKey("tall_mangrove");
|
| 101 | public static final ResourceKey<Feature> CHERRY = FeatureUtils.createKey("cherry");
|
| 102 | public static final ResourceKey<Feature> OAK_BEES_0002_LEAF_LITTER = FeatureUtils.createKey("oak_bees_0002_leaf_litter");
|
| 103 | public static final ResourceKey<Feature> OAK_BEES_002 = FeatureUtils.createKey("oak_bees_002");
|
| 104 | public static final ResourceKey<Feature> OAK_BEES_005 = FeatureUtils.createKey("oak_bees_005");
|
| 105 | public static final ResourceKey<Feature> BIRCH_BEES_0002 = FeatureUtils.createKey("birch_bees_0002");
|
| 106 | public static final ResourceKey<Feature> BIRCH_BEES_0002_LEAF_LITTER = FeatureUtils.createKey("birch_bees_0002_leaf_litter");
|
| 107 | public static final ResourceKey<Feature> BIRCH_BEES_002 = FeatureUtils.createKey("birch_bees_002");
|
| 108 | public static final ResourceKey<Feature> BIRCH_BEES_005 = FeatureUtils.createKey("birch_bees_005");
|
| 109 | public static final ResourceKey<Feature> FANCY_OAK_BEES_0002_LEAF_LITTER = FeatureUtils.createKey("fancy_oak_bees_0002_leaf_litter");
|
| 110 | public static final ResourceKey<Feature> FANCY_OAK_BEES_002 = FeatureUtils.createKey("fancy_oak_bees_002");
|
| 111 | public static final ResourceKey<Feature> FANCY_OAK_BEES_005 = FeatureUtils.createKey("fancy_oak_bees_005");
|
| 112 | public static final ResourceKey<Feature> FANCY_OAK_BEES = FeatureUtils.createKey("fancy_oak_bees");
|
| 113 | public static final ResourceKey<Feature> CHERRY_BEES_005 = FeatureUtils.createKey("cherry_bees_005");
|
| 114 | public static final ResourceKey<Feature> OAK_LEAF_LITTER = FeatureUtils.createKey("oak_leaf_litter");
|
| 115 | public static final ResourceKey<Feature> DARK_OAK_LEAF_LITTER = FeatureUtils.createKey("dark_oak_leaf_litter");
|
| 116 | public static final ResourceKey<Feature> BIRCH_LEAF_LITTER = FeatureUtils.createKey("birch_leaf_litter");
|
| 117 | public static final ResourceKey<Feature> FANCY_OAK_LEAF_LITTER = FeatureUtils.createKey("fancy_oak_leaf_litter");
|
| 118 | public static final ResourceKey<Feature> RED_POPLAR = FeatureUtils.createKey("red_poplar");
|
| 119 | public static final ResourceKey<Feature> ORANGE_POPLAR = FeatureUtils.createKey("orange_poplar");
|
| 120 | public static final ResourceKey<Feature> YELLOW_POPLAR = FeatureUtils.createKey("yellow_poplar");
|
| 121 | public static final ResourceKey<Feature> RED_POPLAR_LEAF_LITTER = FeatureUtils.createKey("red_poplar_leaf_litter");
|
| 122 | public static final ResourceKey<Feature> ORANGE_POPLAR_LEAF_LITTER = FeatureUtils.createKey("orange_poplar_leaf_litter");
|
| 123 | public static final ResourceKey<Feature> YELLOW_POPLAR_LEAF_LITTER = FeatureUtils.createKey("yellow_poplar_leaf_litter");
|
| 124 | public static final ResourceKey<Feature> FALLEN_OAK_TREE = FeatureUtils.createKey("fallen_oak_tree");
|
| 125 | public static final ResourceKey<Feature> FALLEN_JUNGLE_TREE = FeatureUtils.createKey("fallen_jungle_tree");
|
| 126 | public static final ResourceKey<Feature> FALLEN_SPRUCE_TREE = FeatureUtils.createKey("fallen_spruce_tree");
|
| 127 | public static final ResourceKey<Feature> FALLEN_BIRCH_TREE = FeatureUtils.createKey("fallen_birch_tree");
|
| 128 | public static final ResourceKey<Feature> FALLEN_SUPER_BIRCH_TREE = FeatureUtils.createKey("fallen_super_birch_tree");
|
| 129 | public static final ResourceKey<Feature> FALLEN_POPLAR_TREE = FeatureUtils.createKey("fallen_poplar_tree");
|
| 130 |
|
| 131 | private static TreeFeature.Builder createStraightBlobTree(
|
| 132 | final Block oakLog,
|
| 133 | final Block oakLeaves,
|
| 134 | final int baseHeight,
|
| 135 | final int heightRandA,
|
| 136 | final int heightRandB,
|
| 137 | final int blobRadius,
|
| 138 | final Holder<BlockStateProvider> belowTrunkProvider
|
| 139 | ) {
|
| 140 | return new TreeFeature.Builder(
|
| 141 | BlockStateProvider.of(oakLog),
|
| 142 | new StraightTrunkPlacer(baseHeight, heightRandA, heightRandB),
|
| 143 | BlockStateProvider.of(oakLeaves),
|
| 144 | new BlobFoliagePlacer(ConstantInt.of(blobRadius), ConstantInt.of(0), 3),
|
| 145 | new TwoLayersFeatureSize(1, 0, 1),
|
| 146 | belowTrunkProvider
|
| 147 | );
|
| 148 | }
|
| 149 |
|
| 150 | private static TreeFeature.Builder createOak(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 151 | return createStraightBlobTree(Blocks.OAK_LOG, Blocks.OAK_LEAVES, 4, 2, 0, 2, belowTrunkProvider).ignoreVines();
|
| 152 | }
|
| 153 |
|
| 154 | private static TreeFeature.Builder createDarkOak(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 155 | return new TreeFeature.Builder(
|
| 156 | BlockStateProvider.of(Blocks.DARK_OAK_LOG),
|
| 157 | new DarkOakTrunkPlacer(6, 2, 1),
|
| 158 | BlockStateProvider.of(Blocks.DARK_OAK_LEAVES),
|
| 159 | new DarkOakFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0)),
|
| 160 | new ThreeLayersFeatureSize(1, 1, 0, 1, 2, OptionalInt.empty()),
|
| 161 | belowTrunkProvider
|
| 162 | );
|
| 163 | }
|
| 164 |
|
| 165 | private static FallenTreeFeature.Builder createFallenOak() {
|
| 166 | return createFallenTrees(Blocks.OAK_LOG, 4, 7).stumpDecorator(TrunkVineDecorator.INSTANCE);
|
| 167 | }
|
| 168 |
|
| 169 | private static FallenTreeFeature.Builder createFallenBirch(final int maxHeight) {
|
| 170 | return createFallenTrees(Blocks.BIRCH_LOG, 5, maxHeight);
|
| 171 | }
|
| 172 |
|
| 173 | private static FallenTreeFeature.Builder createFallenJungle() {
|
| 174 | return createFallenTrees(Blocks.JUNGLE_LOG, 4, 11).stumpDecorator(TrunkVineDecorator.INSTANCE);
|
| 175 | }
|
| 176 |
|
| 177 | private static FallenTreeFeature.Builder createFallenSpruce() {
|
| 178 | return createFallenTrees(Blocks.SPRUCE_LOG, 6, 10);
|
| 179 | }
|
| 180 |
|
| 181 | private static FallenTreeFeature.Builder createFallenPoplar() {
|
| 182 | return FallenTreeFeature.builder(BlockStateProvider.of(Blocks.POPLAR_LOG), UniformInt.of(4, 7))
|
| 183 | .logDecorator(new AttachedToLogsDecorator(0.1F, BlockStateProvider.holderOf(Blocks.BROWN_MUSHROOM), List.of(Direction.UP)))
|
| 184 | .logDecorator(new ShelfMushroomDecorator(0.8F));
|
| 185 | }
|
| 186 |
|
| 187 | private static FallenTreeFeature.Builder createFallenTrees(final Block logBlock, final int minLength, final int maxLength) {
|
| 188 | return FallenTreeFeature.builder(BlockStateProvider.of(logBlock), UniformInt.of(minLength, maxLength))
|
| 189 | .logDecorator(
|
| 190 | new AttachedToLogsDecorator(
|
| 191 | 0.1F,
|
| 192 | Holder.direct(
|
| 193 | new WeightedStateProvider(
|
| 194 | WeightedList.<BlockState>builder().add(Blocks.RED_MUSHROOM.defaultBlockState(), 2).add(Blocks.BROWN_MUSHROOM.defaultBlockState(), 1)
|
| 195 | )
|
| 196 | ),
|
| 197 | List.of(Direction.UP)
|
| 198 | )
|
| 199 | );
|
| 200 | }
|
| 201 |
|
| 202 | private static TreeFeature.Builder createBirch(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 203 | return createStraightBlobTree(Blocks.BIRCH_LOG, Blocks.BIRCH_LEAVES, 5, 2, 0, 2, belowTrunkProvider).ignoreVines();
|
| 204 | }
|
| 205 |
|
| 206 | private static TreeFeature.Builder createSuperBirch(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 207 | return createStraightBlobTree(Blocks.BIRCH_LOG, Blocks.BIRCH_LEAVES, 5, 2, 6, 2, belowTrunkProvider).ignoreVines();
|
| 208 | }
|
| 209 |
|
| 210 | private static TreeFeature.Builder createJungleTree(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 211 | return createStraightBlobTree(Blocks.JUNGLE_LOG, Blocks.JUNGLE_LEAVES, 4, 8, 0, 2, belowTrunkProvider);
|
| 212 | }
|
| 213 |
|
| 214 | private static TreeFeature.Builder createFancyOak(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 215 | return new TreeFeature.Builder(
|
| 216 | BlockStateProvider.of(Blocks.OAK_LOG),
|
| 217 | new FancyTrunkPlacer(3, 11, 0),
|
| 218 | BlockStateProvider.of(Blocks.OAK_LEAVES),
|
| 219 | new FancyFoliagePlacer(ConstantInt.of(2), ConstantInt.of(4), 4),
|
| 220 | new TwoLayersFeatureSize(0, 0, 0, OptionalInt.of(4)),
|
| 221 | belowTrunkProvider
|
| 222 | )
|
| 223 | .ignoreVines();
|
| 224 | }
|
| 225 |
|
| 226 | private static TreeFeature.Builder cherry(final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 227 | return new TreeFeature.Builder(
|
| 228 | BlockStateProvider.of(Blocks.CHERRY_LOG),
|
| 229 | new CherryTrunkPlacer(
|
| 230 | 7,
|
| 231 | 1,
|
| 232 | 0,
|
| 233 | new WeightedListInt(WeightedList.<IntProvider>builder().add(ConstantInt.of(1), 1).add(ConstantInt.of(2), 1).add(ConstantInt.of(3), 1).build()),
|
| 234 | UniformInt.of(2, 4),
|
| 235 | UniformInt.of(-4, -3),
|
| 236 | UniformInt.of(-1, 0)
|
| 237 | ),
|
| 238 | BlockStateProvider.of(Blocks.CHERRY_LEAVES),
|
| 239 | new CherryFoliagePlacer(ConstantInt.of(4), ConstantInt.of(0), ConstantInt.of(5), 0.25F, 0.5F, 0.16666667F, 0.33333334F),
|
| 240 | new TwoLayersFeatureSize(1, 0, 2),
|
| 241 | belowTrunkProvider
|
| 242 | )
|
| 243 | .ignoreVines();
|
| 244 | }
|
| 245 |
|
| 246 | private static TreeFeature.Builder createPoplar(final Block leafBlock, final Holder<BlockStateProvider> belowTrunkProvider) {
|
| 247 | return new TreeFeature.Builder(
|
| 248 | BlockStateProvider.of(Blocks.POPLAR_LOG),
|
| 249 | new PoplarTrunkPlacer(7, 4, 0, ConstantInt.of(4), UniformInt.of(1, 4)),
|
| 250 | BlockStateProvider.of(leafBlock),
|
| 251 | new PoplarFoliagePlacer(
|
| 252 | new WeightedListInt(
|
| 253 | WeightedList.<IntProvider>builder().add(ConstantInt.of(5), 5).add(ConstantInt.of(6), 5).add(ConstantInt.of(7), 1).add(ConstantInt.of(8), 1).build()
|
| 254 | ),
|
| 255 | ConstantInt.of(0),
|
| 256 | UniformInt.of(5, 6),
|
| 257 | 0.15F
|
| 258 | ),
|
| 259 | new TwoLayersFeatureSize(1, 0, 2),
|
| 260 | belowTrunkProvider
|
| 261 | )
|
| 262 | .ignoreVines();
|
| 263 | }
|
| 264 |
|
| 265 | public static void bootstrap(final BootstrapContext<Feature> context) {
|
| 266 | HolderGetter<Block> blocks = context.lookup(Registries.BLOCK);
|
| 267 | HolderGetter<BlockStateProvider> blockStateProviders = context.lookup(Registries.BLOCK_STATE_PROVIDER);
|
| 268 | BlockPredicate stemReplaceableBlocks = BlockPredicate.matchesBlocks(
|
| 269 | Blocks.OAK_SAPLING,
|
| 270 | Blocks.SPRUCE_SAPLING,
|
| 271 | Blocks.BIRCH_SAPLING,
|
| 272 | Blocks.JUNGLE_SAPLING,
|
| 273 | Blocks.ACACIA_SAPLING,
|
| 274 | Blocks.CHERRY_SAPLING,
|
| 275 | Blocks.DARK_OAK_SAPLING,
|
| 276 | Blocks.PALE_OAK_SAPLING,
|
| 277 | Blocks.MANGROVE_PROPAGULE,
|
| 278 | Blocks.DANDELION,
|
| 279 | Blocks.TORCHFLOWER,
|
| 280 | Blocks.POPPY,
|
| 281 | Blocks.BLUE_ORCHID,
|
| 282 | Blocks.ALLIUM,
|
| 283 | Blocks.AZURE_BLUET,
|
| 284 | Blocks.RED_TULIP,
|
| 285 | Blocks.ORANGE_TULIP,
|
| 286 | Blocks.WHITE_TULIP,
|
| 287 | Blocks.PINK_TULIP,
|
| 288 | Blocks.OXEYE_DAISY,
|
| 289 | Blocks.CORNFLOWER,
|
| 290 | Blocks.WITHER_ROSE,
|
| 291 | Blocks.LILY_OF_THE_VALLEY,
|
| 292 | Blocks.BROWN_MUSHROOM,
|
| 293 | Blocks.RED_MUSHROOM,
|
| 294 | Blocks.WHEAT,
|
| 295 | Blocks.SUGAR_CANE,
|
| 296 | Blocks.ATTACHED_PUMPKIN_STEM,
|
| 297 | Blocks.ATTACHED_MELON_STEM,
|
| 298 | Blocks.PUMPKIN_STEM,
|
| 299 | Blocks.MELON_STEM,
|
| 300 | Blocks.LILY_PAD,
|
| 301 | Blocks.NETHER_WART,
|
| 302 | Blocks.COCOA,
|
| 303 | Blocks.CARROTS,
|
| 304 | Blocks.POTATOES,
|
| 305 | Blocks.CHORUS_PLANT,
|
| 306 | Blocks.CHORUS_FLOWER,
|
| 307 | Blocks.TORCHFLOWER_CROP,
|
| 308 | Blocks.PITCHER_CROP,
|
| 309 | Blocks.BEETROOTS,
|
| 310 | Blocks.SWEET_BERRY_BUSH,
|
| 311 | Blocks.WARPED_FUNGUS,
|
| 312 | Blocks.CRIMSON_FUNGUS,
|
| 313 | Blocks.WEEPING_VINES,
|
| 314 | Blocks.WEEPING_VINES_PLANT,
|
| 315 | Blocks.TWISTING_VINES,
|
| 316 | Blocks.TWISTING_VINES_PLANT,
|
| 317 | Blocks.CAVE_VINES,
|
| 318 | Blocks.CAVE_VINES_PLANT,
|
| 319 | Blocks.SPORE_BLOSSOM,
|
| 320 | Blocks.AZALEA,
|
| 321 | Blocks.FLOWERING_AZALEA,
|
| 322 | Blocks.MOSS_CARPET,
|
| 323 | Blocks.PINK_PETALS,
|
| 324 | Blocks.WILDFLOWERS,
|
| 325 | Blocks.BIG_DRIPLEAF,
|
| 326 | Blocks.BIG_DRIPLEAF_STEM,
|
| 327 | Blocks.SMALL_DRIPLEAF
|
| 328 | );
|
| 329 | context.register(
|
| 330 | CRIMSON_FUNGUS,
|
| 331 | new HugeFungusFeature(
|
| 332 | Blocks.CRIMSON_NYLIUM.defaultBlockState(),
|
| 333 | Blocks.CRIMSON_STEM.defaultBlockState(),
|
| 334 | Blocks.NETHER_WART_BLOCK.defaultBlockState(),
|
| 335 | Blocks.SHROOMLIGHT.defaultBlockState(),
|
| 336 | stemReplaceableBlocks,
|
| 337 | false
|
| 338 | )
|
| 339 | );
|
| 340 | context.register(
|
| 341 | CRIMSON_FUNGUS_PLANTED,
|
| 342 | new HugeFungusFeature(
|
| 343 | Blocks.CRIMSON_NYLIUM.defaultBlockState(),
|
| 344 | Blocks.CRIMSON_STEM.defaultBlockState(),
|
| 345 | Blocks.NETHER_WART_BLOCK.defaultBlockState(),
|
| 346 | Blocks.SHROOMLIGHT.defaultBlockState(),
|
| 347 | stemReplaceableBlocks,
|
| 348 | true
|
| 349 | )
|
| 350 | );
|
| 351 | context.register(
|
| 352 | WARPED_FUNGUS,
|
| 353 | new HugeFungusFeature(
|
| 354 | Blocks.WARPED_NYLIUM.defaultBlockState(),
|
| 355 | Blocks.WARPED_STEM.defaultBlockState(),
|
| 356 | Blocks.WARPED_WART_BLOCK.defaultBlockState(),
|
| 357 | Blocks.SHROOMLIGHT.defaultBlockState(),
|
| 358 | stemReplaceableBlocks,
|
| 359 | false
|
| 360 | )
|
| 361 | );
|
| 362 | context.register(
|
| 363 | WARPED_FUNGUS_PLANTED,
|
| 364 | new HugeFungusFeature(
|
| 365 | Blocks.WARPED_NYLIUM.defaultBlockState(),
|
| 366 | Blocks.WARPED_STEM.defaultBlockState(),
|
| 367 | Blocks.WARPED_WART_BLOCK.defaultBlockState(),
|
| 368 | Blocks.SHROOMLIGHT.defaultBlockState(),
|
| 369 | stemReplaceableBlocks,
|
| 370 | true
|
| 371 | )
|
| 372 | );
|
| 373 | context.register(
|
| 374 | HUGE_BROWN_MUSHROOM,
|
| 375 | new HugeBrownMushroomFeature(
|
| 376 | BlockStateProvider.holderOf(Blocks.BROWN_MUSHROOM_BLOCK.defaultBlockState().setValue(HugeMushroomBlock.UP, true).setValue(HugeMushroomBlock.DOWN, false)),
|
| 377 | BlockStateProvider.holderOf(Blocks.MUSHROOM_STEM.defaultBlockState().setValue(HugeMushroomBlock.UP, false).setValue(HugeMushroomBlock.DOWN, false)),
|
| 378 | 3,
|
| 379 | BlockPredicate.matchesTag(BlockTags.HUGE_BROWN_MUSHROOM_CAN_PLACE_ON)
|
| 380 | )
|
| 381 | );
|
| 382 | context.register(
|
| 383 | HUGE_RED_MUSHROOM,
|
| 384 | new HugeRedMushroomFeature(
|
| 385 | BlockStateProvider.holderOf(Blocks.RED_MUSHROOM_BLOCK.defaultBlockState().setValue(HugeMushroomBlock.DOWN, false)),
|
| 386 | BlockStateProvider.holderOf(Blocks.MUSHROOM_STEM.defaultBlockState().setValue(HugeMushroomBlock.UP, false).setValue(HugeMushroomBlock.DOWN, false)),
|
| 387 | 2,
|
| 388 | BlockPredicate.matchesTag(BlockTags.HUGE_RED_MUSHROOM_CAN_PLACE_ON)
|
| 389 | )
|
| 390 | );
|
| 391 | BeehiveDecorator beehive0002 = new BeehiveDecorator(0.002F);
|
| 392 | BeehiveDecorator beehive001 = new BeehiveDecorator(0.01F);
|
| 393 | BeehiveDecorator beehive002 = new BeehiveDecorator(0.02F);
|
| 394 | BeehiveDecorator beehive005 = new BeehiveDecorator(0.05F);
|
| 395 | BeehiveDecorator beehive = new BeehiveDecorator(1.0F);
|
| 396 | PlaceOnGroundDecorator sparseLeafLitter = new PlaceOnGroundDecorator(
|
| 397 | 96, 4, 2, Holder.direct(new WeightedStateProvider(VegetationFeatures.leafLitterPatchBuilder(1, 3)))
|
| 398 | );
|
| 399 | PlaceOnGroundDecorator thickLeafLitter = new PlaceOnGroundDecorator(
|
| 400 | 150, 2, 2, Holder.direct(new WeightedStateProvider(VegetationFeatures.leafLitterPatchBuilder(1, 4)))
|
| 401 | );
|
| 402 | Holder<BlockStateProvider> belowTrunkProvider = blockStateProviders.getOrThrow(BlockStateProviders.SOIL_BENEATH_TREE);
|
| 403 | context.register(OAK, createOak(belowTrunkProvider).build());
|
| 404 | context.register(DARK_OAK, createDarkOak(belowTrunkProvider).ignoreVines().build());
|
| 405 | context.register(
|
| 406 | PALE_OAK,
|
| 407 | new TreeFeature.Builder(
|
| 408 | BlockStateProvider.of(Blocks.PALE_OAK_LOG),
|
| 409 | new DarkOakTrunkPlacer(6, 2, 1),
|
| 410 | BlockStateProvider.of(Blocks.PALE_OAK_LEAVES),
|
| 411 | new DarkOakFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0)),
|
| 412 | new ThreeLayersFeatureSize(1, 1, 0, 1, 2, OptionalInt.empty()),
|
| 413 | belowTrunkProvider
|
| 414 | )
|
| 415 | .decorators(List.of(new PaleMossDecorator(0.15F, 0.4F, 0.8F)))
|
| 416 | .ignoreVines()
|
| 417 | .build()
|
| 418 | );
|
| 419 | context.register(
|
| 420 | PALE_OAK_BONEMEAL,
|
| 421 | new TreeFeature.Builder(
|
| 422 | BlockStateProvider.of(Blocks.PALE_OAK_LOG),
|
| 423 | new DarkOakTrunkPlacer(6, 2, 1),
|
| 424 | BlockStateProvider.of(Blocks.PALE_OAK_LEAVES),
|
| 425 | new DarkOakFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0)),
|
| 426 | new ThreeLayersFeatureSize(1, 1, 0, 1, 2, OptionalInt.empty()),
|
| 427 | belowTrunkProvider
|
| 428 | )
|
| 429 | .ignoreVines()
|
| 430 | .build()
|
| 431 | );
|
| 432 | context.register(
|
| 433 | PALE_OAK_CREAKING,
|
| 434 | new TreeFeature.Builder(
|
| 435 | BlockStateProvider.of(Blocks.PALE_OAK_LOG),
|
| 436 | new DarkOakTrunkPlacer(6, 2, 1),
|
| 437 | BlockStateProvider.of(Blocks.PALE_OAK_LEAVES),
|
| 438 | new DarkOakFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0)),
|
| 439 | new ThreeLayersFeatureSize(1, 1, 0, 1, 2, OptionalInt.empty()),
|
| 440 | belowTrunkProvider
|
| 441 | )
|
| 442 | .decorators(List.of(new PaleMossDecorator(0.15F, 0.4F, 0.8F), new CreakingHeartDecorator(1.0F)))
|
| 443 | .ignoreVines()
|
| 444 | .build()
|
| 445 | );
|
| 446 | context.register(BIRCH, createBirch(belowTrunkProvider).build());
|
| 447 | context.register(
|
| 448 | ACACIA,
|
| 449 | new TreeFeature.Builder(
|
| 450 | BlockStateProvider.of(Blocks.ACACIA_LOG),
|
| 451 | new ForkingTrunkPlacer(5, 2, 2),
|
| 452 | BlockStateProvider.of(Blocks.ACACIA_LEAVES),
|
| 453 | new AcaciaFoliagePlacer(ConstantInt.of(2), ConstantInt.of(0)),
|
| 454 | new TwoLayersFeatureSize(1, 0, 2),
|
| 455 | belowTrunkProvider
|
| 456 | )
|
| 457 | .ignoreVines()
|
| 458 | .build()
|
| 459 | );
|
| 460 | context.register(CHERRY, cherry(belowTrunkProvider).build());
|
| 461 | context.register(CHERRY_BEES_005, cherry(belowTrunkProvider).decorators(List.of(beehive005)).build());
|
| 462 | context.register(
|
| 463 | SPRUCE,
|
| 464 | new TreeFeature.Builder(
|
| 465 | BlockStateProvider.of(Blocks.SPRUCE_LOG),
|
| 466 | new StraightTrunkPlacer(5, 2, 1),
|
| 467 | BlockStateProvider.of(Blocks.SPRUCE_LEAVES),
|
| 468 | new SpruceFoliagePlacer(UniformInt.of(2, 3), UniformInt.of(0, 2), UniformInt.of(1, 2)),
|
| 469 | new TwoLayersFeatureSize(2, 0, 2),
|
| 470 | belowTrunkProvider
|
| 471 | )
|
| 472 | .ignoreVines()
|
| 473 | .build()
|
| 474 | );
|
| 475 | context.register(
|
| 476 | PINE,
|
| 477 | new TreeFeature.Builder(
|
| 478 | BlockStateProvider.of(Blocks.SPRUCE_LOG),
|
| 479 | new StraightTrunkPlacer(6, 4, 0),
|
| 480 | BlockStateProvider.of(Blocks.SPRUCE_LEAVES),
|
| 481 | new PineFoliagePlacer(ConstantInt.of(1), ConstantInt.of(1), UniformInt.of(3, 4)),
|
| 482 | new TwoLayersFeatureSize(2, 0, 2),
|
| 483 | belowTrunkProvider
|
| 484 | )
|
| 485 | .ignoreVines()
|
| 486 | .build()
|
| 487 | );
|
| 488 | context.register(
|
| 489 | JUNGLE_TREE,
|
| 490 | createJungleTree(belowTrunkProvider)
|
| 491 | .decorators(List.of(new CocoaDecorator(0.2F), TrunkVineDecorator.INSTANCE, new LeaveVineDecorator(0.25F)))
|
| 492 | .ignoreVines()
|
| 493 | .build()
|
| 494 | );
|
| 495 | context.register(FANCY_OAK, createFancyOak(belowTrunkProvider).build());
|
| 496 | context.register(JUNGLE_TREE_NO_VINE, createJungleTree(belowTrunkProvider).ignoreVines().build());
|
| 497 | context.register(
|
| 498 | MEGA_JUNGLE_TREE,
|
| 499 | new TreeFeature.Builder(
|
| 500 | BlockStateProvider.of(Blocks.JUNGLE_LOG),
|
| 501 | new MegaJungleTrunkPlacer(10, 2, 19),
|
| 502 | BlockStateProvider.of(Blocks.JUNGLE_LEAVES),
|
| 503 | new MegaJungleFoliagePlacer(ConstantInt.of(2), ConstantInt.of(0), 2),
|
| 504 | new TwoLayersFeatureSize(1, 1, 2),
|
| 505 | belowTrunkProvider
|
| 506 | )
|
| 507 | .decorators(List.of(TrunkVineDecorator.INSTANCE, new LeaveVineDecorator(0.25F)))
|
| 508 | .build()
|
| 509 | );
|
| 510 | Holder<BlockStateProvider> podzol = blockStateProviders.getOrThrow(BlockStateProviders.PODZOL_BENEATH_TREE);
|
| 511 | context.register(
|
| 512 | MEGA_SPRUCE,
|
| 513 | new TreeFeature.Builder(
|
| 514 | BlockStateProvider.of(Blocks.SPRUCE_LOG),
|
| 515 | new GiantTrunkPlacer(13, 2, 14),
|
| 516 | BlockStateProvider.of(Blocks.SPRUCE_LEAVES),
|
| 517 | new MegaPineFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0), UniformInt.of(13, 17)),
|
| 518 | new TwoLayersFeatureSize(1, 1, 2),
|
| 519 | belowTrunkProvider
|
| 520 | )
|
| 521 | .decorators(List.of(new AlterGroundDecorator(podzol)))
|
| 522 | .build()
|
| 523 | );
|
| 524 | context.register(
|
| 525 | MEGA_PINE,
|
| 526 | new TreeFeature.Builder(
|
| 527 | BlockStateProvider.of(Blocks.SPRUCE_LOG),
|
| 528 | new GiantTrunkPlacer(13, 2, 14),
|
| 529 | BlockStateProvider.of(Blocks.SPRUCE_LEAVES),
|
| 530 | new MegaPineFoliagePlacer(ConstantInt.of(0), ConstantInt.of(0), UniformInt.of(3, 7)),
|
| 531 | new TwoLayersFeatureSize(1, 1, 2),
|
| 532 | belowTrunkProvider
|
| 533 | )
|
| 534 | .decorators(List.of(new AlterGroundDecorator(podzol)))
|
| 535 | .build()
|
| 536 | );
|
| 537 | context.register(SUPER_BIRCH_BEES_0002, createSuperBirch(belowTrunkProvider).decorators(List.of(beehive0002)).build());
|
| 538 | context.register(SUPER_BIRCH_BEES, createSuperBirch(belowTrunkProvider).decorators(List.of(beehive)).build());
|
| 539 | context.register(
|
| 540 | SWAMP_OAK,
|
| 541 | createStraightBlobTree(Blocks.OAK_LOG, Blocks.OAK_LEAVES, 5, 3, 0, 3, belowTrunkProvider).decorators(List.of(new LeaveVineDecorator(0.25F))).build()
|
| 542 | );
|
| 543 | context.register(
|
| 544 | JUNGLE_BUSH,
|
| 545 | new TreeFeature.Builder(
|
| 546 | BlockStateProvider.of(Blocks.JUNGLE_LOG),
|
| 547 | new StraightTrunkPlacer(1, 0, 0),
|
| 548 | BlockStateProvider.of(Blocks.OAK_LEAVES),
|
| 549 | new BushFoliagePlacer(ConstantInt.of(2), ConstantInt.of(1), 2),
|
| 550 | new TwoLayersFeatureSize(0, 0, 0),
|
| 551 | belowTrunkProvider
|
| 552 | )
|
| 553 | .build()
|
| 554 | );
|
| 555 | context.register(
|
| 556 | AZALEA_TREE,
|
| 557 | new TreeFeature.Builder(
|
| 558 | BlockStateProvider.of(Blocks.OAK_LOG),
|
| 559 | new BendingTrunkPlacer(4, 2, 0, 3, UniformInt.of(1, 2)),
|
| 560 | new WeightedStateProvider(
|
| 561 | WeightedList.<BlockState>builder().add(Blocks.AZALEA_LEAVES.defaultBlockState(), 3).add(Blocks.FLOWERING_AZALEA_LEAVES.defaultBlockState(), 1)
|
| 562 | ),
|
| 563 | new RandomSpreadFoliagePlacer(ConstantInt.of(3), ConstantInt.of(0), ConstantInt.of(2), 50),
|
| 564 | new TwoLayersFeatureSize(1, 0, 1),
|
| 565 | belowTrunkProvider
|
| 566 | )
|
| 567 | .belowTrunkProvider(BlockStateProvider.holderOf(Blocks.ROOTED_DIRT))
|
| 568 | .build()
|
| 569 | );
|
| 570 | context.register(
|
| 571 | MANGROVE,
|
| 572 | new TreeFeature.Builder(
|
| 573 | BlockStateProvider.of(Blocks.MANGROVE_LOG),
|
| 574 | new UpwardsBranchingTrunkPlacer(2, 1, 4, UniformInt.of(1, 4), 0.5F, UniformInt.of(0, 1), blocks.getOrThrow(BlockTags.MANGROVE_LOGS_CAN_GROW_THROUGH)),
|
| 575 | BlockStateProvider.of(Blocks.MANGROVE_LEAVES),
|
| 576 | new RandomSpreadFoliagePlacer(ConstantInt.of(3), ConstantInt.of(0), ConstantInt.of(2), 70),
|
| 577 | Optional.of(
|
| 578 | new MangroveRootPlacer(
|
| 579 | UniformInt.of(1, 3),
|
| 580 | BlockStateProvider.holderOf(Blocks.MANGROVE_ROOTS),
|
| 581 | Optional.of(new AboveRootPlacement(BlockStateProvider.holderOf(Blocks.MOSS_CARPET), 0.5F)),
|
| 582 | new MangroveRootPlacement(
|
| 583 | blocks.getOrThrow(BlockTags.MANGROVE_ROOTS_CAN_GROW_THROUGH),
|
| 584 | HolderSet.direct(Block::builtInRegistryHolder, Blocks.MUD, Blocks.MUDDY_MANGROVE_ROOTS),
|
| 585 | BlockStateProvider.holderOf(Blocks.MUDDY_MANGROVE_ROOTS),
|
| 586 | 8,
|
| 587 | 15,
|
| 588 | 0.2F
|
| 589 | )
|
| 590 | )
|
| 591 | ),
|
| 592 | new TwoLayersFeatureSize(2, 0, 2),
|
| 593 | belowTrunkProvider
|
| 594 | )
|
| 595 | .decorators(
|
| 596 | List.of(
|
| 597 | new LeaveVineDecorator(0.125F),
|
| 598 | new AttachedToLeavesDecorator(0.14F, 1, 0, blockStateProviders.getOrThrow(BlockStateProviders.MANGROVE_PROPAGULE), 2, List.of(Direction.DOWN)),
|
| 599 | beehive001
|
| 600 | )
|
| 601 | )
|
| 602 | .ignoreVines()
|
| 603 | .build()
|
| 604 | );
|
| 605 | context.register(
|
| 606 | TALL_MANGROVE,
|
| 607 | new TreeFeature.Builder(
|
| 608 | BlockStateProvider.of(Blocks.MANGROVE_LOG),
|
| 609 | new UpwardsBranchingTrunkPlacer(4, 1, 9, UniformInt.of(1, 6), 0.5F, UniformInt.of(0, 1), blocks.getOrThrow(BlockTags.MANGROVE_LOGS_CAN_GROW_THROUGH)),
|
| 610 | BlockStateProvider.of(Blocks.MANGROVE_LEAVES),
|
| 611 | new RandomSpreadFoliagePlacer(ConstantInt.of(3), ConstantInt.of(0), ConstantInt.of(2), 70),
|
| 612 | Optional.of(
|
| 613 | new MangroveRootPlacer(
|
| 614 | UniformInt.of(3, 7),
|
| 615 | BlockStateProvider.holderOf(Blocks.MANGROVE_ROOTS),
|
| 616 | Optional.of(new AboveRootPlacement(BlockStateProvider.holderOf(Blocks.MOSS_CARPET), 0.5F)),
|
| 617 | new MangroveRootPlacement(
|
| 618 | blocks.getOrThrow(BlockTags.MANGROVE_ROOTS_CAN_GROW_THROUGH),
|
| 619 | HolderSet.direct(Block::builtInRegistryHolder, Blocks.MUD, Blocks.MUDDY_MANGROVE_ROOTS),
|
| 620 | BlockStateProvider.holderOf(Blocks.MUDDY_MANGROVE_ROOTS),
|
| 621 | 8,
|
| 622 | 15,
|
| 623 | 0.2F
|
| 624 | )
|
| 625 | )
|
| 626 | ),
|
| 627 | new TwoLayersFeatureSize(3, 0, 2),
|
| 628 | belowTrunkProvider
|
| 629 | )
|
| 630 | .decorators(
|
| 631 | List.of(
|
| 632 | new LeaveVineDecorator(0.125F),
|
| 633 | new AttachedToLeavesDecorator(0.14F, 1, 0, blockStateProviders.getOrThrow(BlockStateProviders.MANGROVE_PROPAGULE), 2, List.of(Direction.DOWN)),
|
| 634 | beehive001
|
| 635 | )
|
| 636 | )
|
| 637 | .ignoreVines()
|
| 638 | .build()
|
| 639 | );
|
| 640 | context.register(OAK_BEES_0002_LEAF_LITTER, createOak(belowTrunkProvider).decorators(List.of(beehive0002, sparseLeafLitter, thickLeafLitter)).build());
|
| 641 | context.register(OAK_BEES_002, createOak(belowTrunkProvider).decorators(List.of(beehive002)).build());
|
| 642 | context.register(OAK_BEES_005, createOak(belowTrunkProvider).decorators(List.of(beehive005)).build());
|
| 643 | context.register(BIRCH_BEES_0002, createBirch(belowTrunkProvider).decorators(List.of(beehive0002)).build());
|
| 644 | context.register(BIRCH_BEES_0002_LEAF_LITTER, createBirch(belowTrunkProvider).decorators(List.of(beehive0002, sparseLeafLitter, thickLeafLitter)).build());
|
| 645 | context.register(BIRCH_BEES_002, createBirch(belowTrunkProvider).decorators(List.of(beehive002)).build());
|
| 646 | context.register(BIRCH_BEES_005, createBirch(belowTrunkProvider).decorators(List.of(beehive005)).build());
|
| 647 | context.register(
|
| 648 | FANCY_OAK_BEES_0002_LEAF_LITTER, createFancyOak(belowTrunkProvider).decorators(List.of(beehive0002, sparseLeafLitter, thickLeafLitter)).build()
|
| 649 | );
|
| 650 | context.register(FANCY_OAK_BEES_002, createFancyOak(belowTrunkProvider).decorators(List.of(beehive002)).build());
|
| 651 | context.register(FANCY_OAK_BEES_005, createFancyOak(belowTrunkProvider).decorators(List.of(beehive005)).build());
|
| 652 | context.register(FANCY_OAK_BEES, createFancyOak(belowTrunkProvider).decorators(List.of(beehive)).build());
|
| 653 | context.register(OAK_LEAF_LITTER, createOak(belowTrunkProvider).decorators(List.of(sparseLeafLitter, thickLeafLitter)).build());
|
| 654 | context.register(DARK_OAK_LEAF_LITTER, createDarkOak(belowTrunkProvider).ignoreVines().decorators(List.of(sparseLeafLitter, thickLeafLitter)).build());
|
| 655 | context.register(BIRCH_LEAF_LITTER, createBirch(belowTrunkProvider).decorators(List.of(sparseLeafLitter, thickLeafLitter)).build());
|
| 656 | context.register(FANCY_OAK_LEAF_LITTER, createFancyOak(belowTrunkProvider).decorators(List.of(sparseLeafLitter, thickLeafLitter)).build());
|
| 657 | context.register(RED_POPLAR, createPoplar(Blocks.RED_POPLAR_LEAVES, belowTrunkProvider).decorators(List.of(new ShelfMushroomDecorator(0.4F))).build());
|
| 658 | context.register(ORANGE_POPLAR, createPoplar(Blocks.ORANGE_POPLAR_LEAVES, belowTrunkProvider).decorators(List.of(new ShelfMushroomDecorator(0.4F))).build());
|
| 659 | context.register(YELLOW_POPLAR, createPoplar(Blocks.YELLOW_POPLAR_LEAVES, belowTrunkProvider).decorators(List.of(new ShelfMushroomDecorator(0.4F))).build());
|
| 660 | context.register(
|
| 661 | RED_POPLAR_LEAF_LITTER,
|
| 662 | createPoplar(Blocks.RED_POPLAR_LEAVES, belowTrunkProvider).decorators(List.of(sparseLeafLitter, thickLeafLitter, new ShelfMushroomDecorator(0.4F))).build()
|
| 663 | );
|
| 664 | context.register(
|
| 665 | ORANGE_POPLAR_LEAF_LITTER,
|
| 666 | createPoplar(Blocks.ORANGE_POPLAR_LEAVES, belowTrunkProvider)
|
| 667 | .decorators(List.of(sparseLeafLitter, thickLeafLitter, new ShelfMushroomDecorator(0.4F)))
|
| 668 | .build()
|
| 669 | );
|
| 670 | context.register(
|
| 671 | YELLOW_POPLAR_LEAF_LITTER,
|
| 672 | createPoplar(Blocks.YELLOW_POPLAR_LEAVES, belowTrunkProvider)
|
| 673 | .decorators(List.of(sparseLeafLitter, thickLeafLitter, new ShelfMushroomDecorator(0.4F)))
|
| 674 | .build()
|
| 675 | );
|
| 676 | context.register(FALLEN_OAK_TREE, createFallenOak().build());
|
| 677 | context.register(FALLEN_BIRCH_TREE, createFallenBirch(8).build());
|
| 678 | context.register(FALLEN_SUPER_BIRCH_TREE, createFallenBirch(15).build());
|
| 679 | context.register(FALLEN_JUNGLE_TREE, createFallenJungle().build());
|
| 680 | context.register(FALLEN_SPRUCE_TREE, createFallenSpruce().build());
|
| 681 | context.register(FALLEN_POPLAR_TREE, createFallenPoplar().build());
|
| 682 | }
|
| 683 | }
|
| 684 |
|