Update to Minecraft 1.14-pre5

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2019-04-23 12:00:00 +10:00
parent 0e98365784
commit a0f2b74c8d
560 changed files with 10642 additions and 10867 deletions

View File

@@ -8,10 +8,10 @@
public class EntityBat extends EntityAmbient {
@@ -94,12 +95,20 @@
@@ -104,12 +105,20 @@
}
if (this.world.b(this, 4.0D) != null) {
if (this.world.a(EntityBat.c, (EntityLiving) this) != null) {
+ // CraftBukkit Start - Call BatToggleSleepEvent
+ if (CraftEventFactory.handleBatToggleSleepEvent(this, true)) {
+ this.setAsleep(false);
@@ -31,11 +31,11 @@
+ // CraftBukkit End - Call BatToggleSleepEvent
}
} else {
if (this.b != null && (!this.world.isEmpty(this.b) || this.b.getY() < 1)) {
@@ -123,7 +132,11 @@
this.bj = 0.5F;
if (this.d != null && (!this.world.isEmpty(this.d) || this.d.getY() < 1)) {
@@ -133,7 +142,11 @@
this.bd = 0.5F;
this.yaw += f1;
if (this.random.nextInt(100) == 0 && this.world.getType(blockposition1).isOccluding()) {
if (this.random.nextInt(100) == 0 && this.world.getType(blockposition1).isOccluding(this.world, blockposition1)) {
- this.setAsleep(true);
+ // CraftBukkit Start - Call BatToggleSleepEvent
+ if (CraftEventFactory.handleBatToggleSleepEvent(this, false)) {
@@ -45,7 +45,7 @@
}
}
@@ -146,7 +159,11 @@
@@ -161,7 +174,11 @@
return false;
} else {
if (!this.world.isClientSide && this.isAsleep()) {