Update to Minecraft 1.18-pre5

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2021-11-22 09:00:00 +11:00
parent a852b81a69
commit 43702a9e10
700 changed files with 10286 additions and 10098 deletions

View File

@@ -10,20 +10,20 @@
+
public abstract class EntityCreature extends EntityInsentient {
protected EntityCreature(EntityTypes<? extends EntityCreature> entitytypes, World world) {
@@ -41,6 +45,7 @@
protected static final float DEFAULT_WALK_TARGET_VALUE = 0.0F;
@@ -43,6 +47,7 @@
if (this instanceof EntityTameableAnimal && ((EntityTameableAnimal) this).isSitting()) {
if (this instanceof EntityTameableAnimal && ((EntityTameableAnimal) this).isInSittingPose()) {
if (f > 10.0F) {
+ this.level.getCraftServer().getPluginManager().callEvent(new EntityUnleashEvent(this.getBukkitEntity(), EntityUnleashEvent.UnleashReason.DISTANCE)); // CraftBukkit
this.unleash(true, true);
this.dropLeash(true, true);
}
@@ -49,6 +54,7 @@
@@ -51,6 +56,7 @@
this.y(f);
this.onLeashDistance(f);
if (f > 10.0F) {
+ this.level.getCraftServer().getPluginManager().callEvent(new EntityUnleashEvent(this.getBukkitEntity(), EntityUnleashEvent.UnleashReason.DISTANCE)); // CraftBukkit
this.unleash(true, true);
this.goalSelector.a(PathfinderGoal.Type.MOVE);
this.dropLeash(true, true);
this.goalSelector.disableControlFlag(PathfinderGoal.Type.MOVE);
} else if (f > 6.0F) {