Update to Minecraft 1.13-pre7

This commit is contained in:
md_5
2018-07-15 10:00:00 +10:00
parent 57ab4cfc6f
commit 421c1728c8
608 changed files with 17788 additions and 9378 deletions

View File

@@ -1,6 +1,6 @@
--- a/net/minecraft/server/EntityBoat.java
+++ b/net/minecraft/server/EntityBoat.java
@@ -5,6 +5,15 @@
@@ -3,6 +3,15 @@
import java.util.List;
import javax.annotation.Nullable;
@@ -16,9 +16,9 @@
public class EntityBoat extends Entity {
private static final DataWatcherObject<Integer> a = DataWatcher.a(EntityBoat.class, DataWatcherRegistry.b);
@@ -32,6 +41,14 @@
private EntityBoat.EnumStatus aH;
private double aI;
@@ -37,6 +46,14 @@
private float aR;
private float aS;
+ // CraftBukkit start
+ // PAIL: Some of these haven't worked since a few updates, and since 1.9 they are less and less applicable.
@@ -29,9 +29,9 @@
+ // CraftBukkit end
+
public EntityBoat(World world) {
super(world);
this.f = new float[2];
@@ -95,6 +112,19 @@
super(EntityTypes.BOAT, world);
this.h = new float[2];
@@ -94,6 +111,19 @@
if (damagesource instanceof EntityDamageSourceIndirect && damagesource.getEntity() != null && this.w(damagesource.getEntity())) {
return false;
} else {
@@ -48,13 +48,13 @@
+ // f = event.getDamage(); // TODO Why don't we do this?
+ // CraftBukkit end
+
this.d(-this.r());
this.c(10);
this.setDamage(this.p() + f * 10.0F);
@@ -102,6 +132,15 @@
this.c(-this.o());
this.b(10);
this.setDamage(this.m() + f * 10.0F);
@@ -101,6 +131,15 @@
boolean flag = damagesource.getEntity() instanceof EntityHuman && ((EntityHuman) damagesource.getEntity()).abilities.canInstantlyBuild;
if (flag || this.p() > 40.0F) {
if (flag || this.m() > 40.0F) {
+ // CraftBukkit start
+ VehicleDestroyEvent destroyEvent = new VehicleDestroyEvent(vehicle, attacker);
+ this.world.getServer().getPluginManager().callEvent(destroyEvent);
@@ -65,9 +65,9 @@
+ }
+ // CraftBukkit end
if (!flag && this.world.getGameRules().getBoolean("doEntityDrops")) {
this.a(this.j(), 1, 0.0F);
this.a((IMaterial) this.f());
}
@@ -119,9 +158,25 @@
@@ -134,9 +173,25 @@
public void collide(Entity entity) {
if (entity instanceof EntityBoat) {
if (entity.getBoundingBox().b < this.getBoundingBox().e) {
@@ -93,23 +93,15 @@
super.collide(entity);
}
@@ -158,6 +213,7 @@
@@ -173,6 +228,7 @@
return this.getDirection().e();
}
+ private Location lastLocation; // CraftBukkit
public void B_() {
this.aH = this.aG;
this.aG = this.u();
@@ -178,7 +234,6 @@
if (this.p() > 0.0F) {
this.setDamage(this.p() - 1.0F);
}
-
this.lastX = this.locX;
this.lastY = this.locY;
this.lastZ = this.locZ;
@@ -202,6 +257,22 @@
public void tick() {
this.aM = this.aL;
this.aL = this.s();
@@ -217,6 +273,22 @@
this.motZ = 0.0D;
}
@@ -129,12 +121,12 @@
+ lastLocation = vehicle.getLocation();
+ // CraftBukkit end
+
for (int i = 0; i <= 1; ++i) {
if (this.a(i)) {
if (!this.isSilent() && (double) (this.f[i] % 6.2831855F) <= 0.7853981852531433D && ((double) this.f[i] + 0.39269909262657166D) % 6.2831854820251465D >= 0.7853981852531433D) {
@@ -622,6 +693,11 @@
this.q();
this.e(this.fallDistance, 1.0F);
for (int i = 0; i <= 1; ++i) {
@@ -737,6 +809,11 @@
this.c(this.fallDistance, 1.0F);
if (!this.world.isClientSide && !this.dead) {
+ // CraftBukkit start
+ Vehicle vehicle = (Vehicle) this.getBukkitEntity();
@@ -144,7 +136,7 @@
this.die();
if (this.world.getGameRules().getBoolean("doEntityDrops")) {
int i;
@@ -635,6 +711,7 @@
@@ -750,6 +827,7 @@
}
}
}