--- a/net/minecraft/world/level/block/grower/WorldGenTreeProvider.java
+++ b/net/minecraft/world/level/block/grower/WorldGenTreeProvider.java
@@ -14,6 +14,12 @@
 import net.minecraft.world.level.levelgen.feature.WorldGenFeatureConfigured;
 import net.minecraft.world.level.levelgen.feature.configurations.WorldGenFeatureTreeConfiguration;
 
+// CraftBukkit start
+import net.minecraft.data.worldgen.BiomeDecoratorGroups;
+import net.minecraft.world.level.block.BlockSapling;
+import org.bukkit.TreeType;
+// CraftBukkit end
+
 public abstract class WorldGenTreeProvider {
 
     public WorldGenTreeProvider() {}
@@ -27,6 +33,7 @@
         if (worldgenfeatureconfigured == null) {
             return false;
         } else {
+            setTreeType(worldgenfeatureconfigured); // CraftBukkit
             worldserver.setTypeAndData(blockposition, Blocks.AIR.getBlockData(), 4);
             if (worldgenfeatureconfigured.a(worldserver, chunkgenerator, random, blockposition)) {
                 return true;
@@ -52,4 +59,48 @@
 
         return true;
     }
+
+    // CraftBukkit start
+    protected void setTreeType(WorldGenFeatureConfigured<?, ?> worldgentreeabstract) {
+        if (worldgentreeabstract == BiomeDecoratorGroups.OAK || worldgentreeabstract == BiomeDecoratorGroups.OAK_BEES_005) {
+            BlockSapling.treeType = TreeType.TREE;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.HUGE_RED_MUSHROOM) {
+            BlockSapling.treeType = TreeType.RED_MUSHROOM;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.HUGE_BROWN_MUSHROOM) {
+            BlockSapling.treeType = TreeType.BROWN_MUSHROOM;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.JUNGLE_TREE) {
+            BlockSapling.treeType = TreeType.COCOA_TREE;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.JUNGLE_TREE_NO_VINE) {
+            BlockSapling.treeType = TreeType.SMALL_JUNGLE;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.PINE) {
+            BlockSapling.treeType = TreeType.TALL_REDWOOD;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.SPRUCE) {
+            BlockSapling.treeType = TreeType.REDWOOD;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.ACACIA) {
+            BlockSapling.treeType = TreeType.ACACIA;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.BIRCH || worldgentreeabstract == BiomeDecoratorGroups.BIRCH_BEES_005) {
+            BlockSapling.treeType = TreeType.BIRCH;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.SUPER_BIRCH_BEES_0002) {
+            BlockSapling.treeType = TreeType.TALL_BIRCH;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.SWAMP_OAK) {
+            BlockSapling.treeType = TreeType.SWAMP;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.FANCY_OAK || worldgentreeabstract == BiomeDecoratorGroups.FANCY_OAK_BEES_005) {
+            BlockSapling.treeType = TreeType.BIG_TREE;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.JUNGLE_BUSH) {
+            BlockSapling.treeType = TreeType.JUNGLE_BUSH;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.DARK_OAK) {
+            BlockSapling.treeType = TreeType.DARK_OAK;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.MEGA_SPRUCE) {
+            BlockSapling.treeType = TreeType.MEGA_REDWOOD;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.MEGA_PINE) {
+            BlockSapling.treeType = TreeType.MEGA_REDWOOD;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.MEGA_JUNGLE_TREE) {
+            BlockSapling.treeType = TreeType.JUNGLE;
+        } else if (worldgentreeabstract == BiomeDecoratorGroups.AZALEA_TREE) {
+            BlockSapling.treeType = TreeType.AZALEA;
+        } else {
+            throw new IllegalArgumentException("Unknown tree generator " + worldgentreeabstract);
+        }
+    }
+    // CraftBukkit end
 }
