From 62c6ec044e6eaddfc5a057ce5c9d3859053d0b9c Mon Sep 17 00:00:00 2001 From: Shane Freeder Date: Sat, 2 Mar 2024 15:05:35 +0000 Subject: [PATCH] Make sure that the backend server knows the pack application was successful accepted, is just the first expected state, we also need to tell that the pack was actually applied on the client in order to allow it to progress in the connection process --- .../proxy/connection/backend/ConfigSessionHandler.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/ConfigSessionHandler.java b/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/ConfigSessionHandler.java index 1617fb138..32c07c042 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/ConfigSessionHandler.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/ConfigSessionHandler.java @@ -137,8 +137,13 @@ public class ConfigSessionHandler implements MinecraftSessionHandler { if (serverConn.getPlayer().resourcePackHandler().hasPackAppliedByHash(toSend.getHash())) { // Do not apply a resource pack that has already been applied if (serverConn.getConnection() != null) { + // We can technically skip these first 2 states, however, for conformity to normal state flow expectations... serverConn.getConnection().write(new ResourcePackResponsePacket( packet.getId(), packet.getHash(), PlayerResourcePackStatusEvent.Status.ACCEPTED)); + serverConn.getConnection().write(new ResourcePackResponsePacket( + packet.getId(), packet.getHash(), PlayerResourcePackStatusEvent.Status.DOWNLOADED)); + serverConn.getConnection().write(new ResourcePackResponsePacket( + packet.getId(), packet.getHash(), PlayerResourcePackStatusEvent.Status.SUCCESSFUL)); } if (modifiedPack) { logger.warn("A plugin has tried to modify a ResourcePack provided by the backend server "