mirror of
https://github.com/PaperMC/Paper.git
synced 2025-03-24 20:51:10 +01:00
SPIGOT-7435: Add TeleportCause#EXIT_BED
By: md_5 <git@md-5.net>
This commit is contained in:
parent
223ea107d2
commit
86a10c9c2c
@ -667,7 +667,7 @@
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -989,6 +1303,24 @@
|
||||
@@ -989,13 +1303,31 @@
|
||||
|
||||
@Override
|
||||
public void stopSleepInBed(boolean flag, boolean flag1) {
|
||||
@ -692,6 +692,14 @@
|
||||
if (this.isSleeping()) {
|
||||
this.serverLevel().getChunkSource().broadcastAndSend(this, new PacketPlayOutAnimation(this, 2));
|
||||
}
|
||||
|
||||
super.stopSleepInBed(flag, flag1);
|
||||
if (this.connection != null) {
|
||||
- this.connection.teleport(this.getX(), this.getY(), this.getZ(), this.getYRot(), this.getXRot());
|
||||
+ this.connection.teleport(this.getX(), this.getY(), this.getZ(), this.getYRot(), this.getXRot(), TeleportCause.EXIT_BED); // CraftBukkit
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1037,8 +1369,9 @@
|
||||
this.connection.send(new PacketPlayOutOpenSignEditor(tileentitysign.getBlockPos(), flag));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user