[SPIGOT-4867] Incorrect PacketPlayOutRespawn dimension ID for nether portal teleports Created: 04/May/19  Updated: 04/May/19  Resolved: 04/May/19

Status: Resolved
Project: Spigot
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: Ale Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: 1.14

Version: CraftBukkit version git-Spigot-1eece4f-68e72f6 (MC: 1.14) (Implementing API version 1.14-R0.1-SNAPSHOT)
Guidelines Read: Yes

 Description   

Back in 1.13, when a player teleported to a world through a nether portal, PlayerList#moveToWorld would send the PacketPlayOutRespawn packet, which would be constructed with:

new PacketPlayOutRespawn(worldserver.worldProvider.getDimensionManager(), ...

But in 1.14, teleporting through nether portals doesn't utilize the above method anymore, instead creating PacketPlayOutRespawn in EntityPlayer#a with:

new PacketPlayOutRespawn(dimensionmanager, ...

This causes the packet to use the custom dimensionId for custom worlds, which causes strange client-side behavior when changing the portal event destination to a custom world.

 

To fix this, simply change the passed constructor argument to:

worldserver1.worldProvider.getDimensionManager()

 


Generated at Tue Apr 22 04:54:53 UTC 2025 using Jira 10.3.5#10030005-sha1:190c783f2bd6c69cd5accdb70f97e48812a78d14.