mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 19:15:32 +01:00
SPIGOT-2807: Update inventory when attack cancelled
This commit is contained in:
parent
95436219a5
commit
ac99d7d474
@ -332,7 +332,19 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (this.world instanceof WorldServer && f4 > 2.0F) {
|
if (this.world instanceof WorldServer && f4 > 2.0F) {
|
||||||
@@ -1118,6 +1243,20 @@
|
@@ -1028,6 +1153,11 @@
|
||||||
|
if (flag4) {
|
||||||
|
entity.extinguish();
|
||||||
|
}
|
||||||
|
+ // CraftBukkit start - resync on cancelled event
|
||||||
|
+ if (this instanceof EntityPlayer) {
|
||||||
|
+ ((EntityPlayer) this).getBukkitEntity().updateInventory();
|
||||||
|
+ }
|
||||||
|
+ // CraftBukkit end
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1118,6 +1248,20 @@
|
||||||
this.stopRiding();
|
this.stopRiding();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -353,7 +365,7 @@
|
|||||||
this.setSize(0.2F, 0.2F);
|
this.setSize(0.2F, 0.2F);
|
||||||
if (this.world.isLoaded(blockposition)) {
|
if (this.world.isLoaded(blockposition)) {
|
||||||
float f = 0.5F + (float) enumdirection.getAdjacentX() * 0.4F;
|
float f = 0.5F + (float) enumdirection.getAdjacentX() * 0.4F;
|
||||||
@@ -1177,6 +1316,23 @@
|
@@ -1177,6 +1321,23 @@
|
||||||
this.world.everyoneSleeping();
|
this.world.everyoneSleeping();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -377,7 +389,7 @@
|
|||||||
this.sleepTicks = flag ? 0 : 100;
|
this.sleepTicks = flag ? 0 : 100;
|
||||||
if (flag2) {
|
if (flag2) {
|
||||||
this.setRespawnPosition(this.bedPosition, false);
|
this.setRespawnPosition(this.bedPosition, false);
|
||||||
@@ -1228,9 +1384,11 @@
|
@@ -1228,9 +1389,11 @@
|
||||||
if (blockposition != null) {
|
if (blockposition != null) {
|
||||||
this.e = blockposition;
|
this.e = blockposition;
|
||||||
this.f = flag;
|
this.f = flag;
|
||||||
|
Loading…
Reference in New Issue
Block a user