3
0
Mirror von https://github.com/PaperMC/Velocity.git synchronisiert 2024-11-16 21:10:30 +01:00

Fix race condition when switching client from config to play state

Dieser Commit ist enthalten in:
Gero 2024-02-10 23:28:08 +01:00
Ursprung d8bb4e97e4
Commit 15897c5258

Datei anzeigen

@ -197,7 +197,10 @@ public class ClientConfigSessionHandler implements MinecraftSessionHandler {
smc.write(brandPacket); smc.write(brandPacket);
} }
player.getConnection().write(FinishedUpdatePacket.INSTANCE); player.getConnection().eventLoop().execute(() -> {
player.getConnection().write(FinishedUpdatePacket.INSTANCE);
player.getConnection().getChannel().pipeline().get(MinecraftEncoder.class).setState(StateRegistry.PLAY);
});
smc.write(FinishedUpdatePacket.INSTANCE); smc.write(FinishedUpdatePacket.INSTANCE);
smc.getChannel().pipeline().get(MinecraftEncoder.class).setState(StateRegistry.PLAY); smc.getChannel().pipeline().get(MinecraftEncoder.class).setState(StateRegistry.PLAY);