Update to Minecraft 1.9

This commit is contained in:
md_5
2016-03-01 08:32:46 +11:00
parent e1ebe524a7
commit aa008dff0f
305 changed files with 6684 additions and 6105 deletions

View File

@@ -14,8 +14,8 @@
public int a;
@@ -34,6 +40,7 @@
public void t_() {
super.t_();
public void m() {
super.m();
+ EntityHuman prevTarget = this.targetPlayer;// CraftBukkit - store old target
if (this.c > 0) {
--this.c;
@@ -35,7 +35,7 @@
+
+ if (!cancelled && targetPlayer != null) {
double d1 = (this.targetPlayer.locX - this.locX) / d0;
double d2 = (this.targetPlayer.locY + (double) this.targetPlayer.getHeadHeight() - this.locY) / d0;
double d2 = (this.targetPlayer.locY + (double) this.targetPlayer.getHeadHeight() / 2.0D - this.locY) / d0;
double d3 = (this.targetPlayer.locZ - this.locZ) / d0;
@@ -77,6 +94,8 @@
this.motY += d2 / d4 * d5 * 0.1D;
@@ -46,16 +46,16 @@
}
this.move(this.motX, this.motY, this.motZ);
@@ -141,7 +160,7 @@
entityhuman.bp = 2;
this.world.makeSound(entityhuman, "random.orb", 0.1F, 0.5F * ((this.random.nextFloat() - this.random.nextFloat()) * 0.7F + 1.8F));
entityhuman.receive(this, 1);
- entityhuman.giveExp(this.value);
+ entityhuman.giveExp(CraftEventFactory.callPlayerExpChangeEvent(entityhuman, this.value).getAmount()); // CraftBukkit - this.value -> event.getAmount()
this.die();
}
@@ -151,7 +170,7 @@
}
@@ -153,6 +172,24 @@
if (this.value > 0) {
- entityhuman.giveExp(this.value);
+ entityhuman.giveExp(CraftEventFactory.callPlayerExpChangeEvent(entityhuman, this.value).getAmount()); // CraftBukkit - this.value -> event.getAmount()
}
this.die();
@@ -173,6 +192,24 @@
}
public static int getOrbValue(int i) {