Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-10-03 08:41:05 +02:00
Fix lower version support (default to client version if we can't port it instead of server) #519
Dieser Commit ist enthalten in:
Ursprung
f92b7e5b80
Commit
b6dbe82d16
@ -110,14 +110,16 @@ public class BungeeEncodeHandler extends MessageToMessageEncoder<ByteBuf> {
|
|||||||
// Refresh the pipes
|
// Refresh the pipes
|
||||||
List<Pair<Integer, Protocol>> protocols = ProtocolRegistry.getProtocolPath(info.getProtocolVersion(), protocolId);
|
List<Pair<Integer, Protocol>> protocols = ProtocolRegistry.getProtocolPath(info.getProtocolVersion(), protocolId);
|
||||||
ProtocolPipeline pipeline = viaConnection.get(ProtocolInfo.class).getPipeline();
|
ProtocolPipeline pipeline = viaConnection.get(ProtocolInfo.class).getPipeline();
|
||||||
|
|
||||||
viaConnection.clearStoredObjects();
|
viaConnection.clearStoredObjects();
|
||||||
pipeline.cleanPipes();
|
pipeline.cleanPipes();
|
||||||
|
if (protocols == null) {
|
||||||
if (protocols != null)
|
// TODO Check Bungee Supported Protocols? *shrugs*
|
||||||
|
protocolId = info.getProtocolVersion();
|
||||||
|
} else {
|
||||||
for (Pair<Integer, Protocol> prot : protocols) {
|
for (Pair<Integer, Protocol> prot : protocols) {
|
||||||
pipeline.add(prot.getValue());
|
pipeline.add(prot.getValue());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
viaConnection.put(info);
|
viaConnection.put(info);
|
||||||
viaConnection.put(storage);
|
viaConnection.put(storage);
|
||||||
@ -138,6 +140,7 @@ public class BungeeEncodeHandler extends MessageToMessageEncoder<ByteBuf> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Method getEntityMap = null;
|
private static Method getEntityMap = null;
|
||||||
private static Method setVersion = null;
|
private static Method setVersion = null;
|
||||||
private static Field entityRewrite = null;
|
private static Field entityRewrite = null;
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren