3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-12-27 08:30:09 +01:00
Dieser Commit ist enthalten in:
creeper123123321 2020-06-30 16:08:48 -03:00 committet von Five (Xer)
Ursprung 6c3479e739
Commit b1e60f5f1b
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: A3F306B10E6330E7

Datei anzeigen

@ -2,7 +2,6 @@ package us.myles.ViaVersion.velocity.providers;
import com.velocitypowered.api.proxy.ServerConnection; import com.velocitypowered.api.proxy.ServerConnection;
import io.netty.channel.ChannelHandler; import io.netty.channel.ChannelHandler;
import io.netty.channel.ServerChannel;
import us.myles.ViaVersion.VelocityPlugin; import us.myles.ViaVersion.VelocityPlugin;
import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.Via;
import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.data.UserConnection;
@ -40,7 +39,7 @@ public class VelocityVersionProvider extends VersionProvider {
private int getFrontProtocol(UserConnection user) throws Exception { private int getFrontProtocol(UserConnection user) throws Exception {
System.out.println("frontend protocol!"); System.out.println("frontend protocol!");
int playerVersion = user.get(ProtocolInfo.class).getProtocolVersion(); int playerVersion = user.getProtocolInfo().getProtocolVersion();
IntStream versions = com.velocitypowered.api.network.ProtocolVersion.SUPPORTED_VERSIONS.stream() IntStream versions = com.velocitypowered.api.network.ProtocolVersion.SUPPORTED_VERSIONS.stream()
.mapToInt(com.velocitypowered.api.network.ProtocolVersion::getProtocol); .mapToInt(com.velocitypowered.api.network.ProtocolVersion::getProtocol);