Update to Minecraft 1.17

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2021-06-11 15:00:00 +10:00
parent 75faba7fde
commit b3a8254758
619 changed files with 10708 additions and 8451 deletions

View File

@@ -11,8 +11,8 @@
+
public class BlockSoil extends Block {
public static final BlockStateInteger MOISTURE = BlockProperties.aw;
@@ -81,26 +86,49 @@
public static final BlockStateInteger MOISTURE = BlockProperties.MOISTURE;
@@ -82,26 +87,49 @@
if (!a((IWorldReader) worldserver, blockposition) && !worldserver.isRainingAt(blockposition.up())) {
if (i > 0) {
@@ -29,9 +29,9 @@
}
@Override
public void fallOn(World world, BlockPosition blockposition, Entity entity, float f) {
+ super.fallOn(world, blockposition, entity, f); // CraftBukkit - moved here as game rules / events shouldn't affect fall damage.
if (!world.isClientSide && world.random.nextFloat() < f - 0.5F && entity instanceof EntityLiving && (entity instanceof EntityHuman || world.getGameRules().getBoolean(GameRules.MOB_GRIEFING)) && entity.getWidth() * entity.getWidth() * entity.getHeight() > 0.512F) {
public void fallOn(World world, IBlockData iblockdata, BlockPosition blockposition, Entity entity, float f) {
+ super.fallOn(world, iblockdata, blockposition, entity, f); // CraftBukkit - moved here as game rules / events shouldn't affect fall damage.
if (!world.isClientSide && world.random.nextFloat() < f - 0.5F && entity instanceof EntityLiving && (entity instanceof EntityHuman || world.getGameRules().getBoolean(GameRules.RULE_MOBGRIEFING)) && entity.getWidth() * entity.getWidth() * entity.getHeight() > 0.512F) {
+ // CraftBukkit start - Interact soil
+ org.bukkit.event.Cancellable cancellable;
+ if (entity instanceof EntityHuman) {
@@ -49,11 +49,11 @@
+ return;
+ }
+ // CraftBukkit end
fade(world.getType(blockposition), world, blockposition);
fade(iblockdata, world, blockposition);
}
- super.fallOn(world, blockposition, entity, f);
+ // super.fallOn(world, blockposition, entity, f); // CraftBukkit - moved up
- super.fallOn(world, iblockdata, blockposition, entity, f);
+ // super.fallOn(world, iblockdata, blockposition, entity, f); // CraftBukkit - moved up
}
public static void fade(IBlockData iblockdata, World world, BlockPosition blockposition) {