mirror of
https://github.com/PaperMC/Paper.git
synced 2025-02-23 04:58:28 +01:00
Don't manually send ClientboundPlayerPositionPacket for refreshPlayer
in 1.19, mojang made it so that teleporations validate that an awaiting pos was set in the server when teleporting, thus we need to ensure that this is set when sending the player pos, otherwise the player will be kicked when the client sends back the aknowledgement
This commit is contained in:
parent
7fdee6200b
commit
53885ac491
1 changed files with 1 additions and 1 deletions
|
@ -131,7 +131,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
+ ServerLevel worldserver = handle.getLevel();
|
||||
+ connection.send(new net.minecraft.network.protocol.game.ClientboundRespawnPacket(worldserver.dimensionTypeId(), worldserver.dimension(), BiomeManager.obfuscateSeed(worldserver.getSeed()), handle.gameMode.getGameModeForPlayer(), handle.gameMode.getPreviousGameModeForPlayer(), worldserver.isDebug(), worldserver.isFlat(), true, this.getHandle().getLastDeathLocation()));
|
||||
+ handle.onUpdateAbilities();
|
||||
+ connection.send(new net.minecraft.network.protocol.game.ClientboundPlayerPositionPacket(loc.getX(), loc.getY(), loc.getZ(), loc.getYaw(), loc.getPitch(), java.util.Collections.emptySet(), 0, false));
|
||||
+ connection.internalTeleport(loc.getX(), loc.getY(), loc.getZ(), loc.getYaw(), loc.getPitch(), java.util.Collections.emptySet(), false);
|
||||
+ net.minecraft.server.MinecraftServer.getServer().getPlayerList().sendAllPlayerInfo(handle);
|
||||
+
|
||||
+ if (this.isOp()) {
|
||||
|
|
Loading…
Add table
Reference in a new issue