SPIGOT-7572: Bee nests generated without bees
By: DerFrZocker <derrieple@gmail.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/world/level/block/BlockSapling.java
|
||||
+++ b/net/minecraft/world/level/block/BlockSapling.java
|
||||
@@ -17,6 +17,14 @@
|
||||
@@ -17,6 +17,15 @@
|
||||
import net.minecraft.world.phys.shapes.VoxelShape;
|
||||
import net.minecraft.world.phys.shapes.VoxelShapeCollision;
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
+import org.bukkit.Location;
|
||||
+import org.bukkit.TreeType;
|
||||
+import org.bukkit.block.BlockState;
|
||||
+import org.bukkit.craftbukkit.block.CapturedBlockState;
|
||||
+import org.bukkit.craftbukkit.util.CraftLocation;
|
||||
+import org.bukkit.event.world.StructureGrowEvent;
|
||||
+// CraftBukkit end
|
||||
@@ -15,7 +16,7 @@
|
||||
public class BlockSapling extends BlockPlant implements IBlockFragilePlantElement {
|
||||
|
||||
public static final MapCodec<BlockSapling> CODEC = RecordCodecBuilder.mapCodec((instance) -> {
|
||||
@@ -28,6 +36,7 @@
|
||||
@@ -28,6 +37,7 @@
|
||||
protected static final float AABB_OFFSET = 6.0F;
|
||||
protected static final VoxelShape SHAPE = Block.box(2.0D, 0.0D, 2.0D, 14.0D, 12.0D, 14.0D);
|
||||
protected final WorldGenTreeProvider treeGrower;
|
||||
@@ -23,7 +24,7 @@
|
||||
|
||||
@Override
|
||||
public MapCodec<? extends BlockSapling> codec() {
|
||||
@@ -57,7 +66,32 @@
|
||||
@@ -57,7 +67,32 @@
|
||||
if ((Integer) iblockdata.getValue(BlockSapling.STAGE) == 0) {
|
||||
worldserver.setBlock(blockposition, (IBlockData) iblockdata.cycle(BlockSapling.STAGE), 4);
|
||||
} else {
|
||||
@@ -48,7 +49,7 @@
|
||||
+ }
|
||||
+ if (event == null || !event.isCancelled()) {
|
||||
+ for (BlockState blockstate : blocks) {
|
||||
+ blockstate.update(true);
|
||||
+ CapturedBlockState.setBlockState(blockstate);
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
|
||||
Reference in New Issue
Block a user