3
0
Mirror von https://github.com/PaperMC/Velocity.git synchronisiert 2024-09-29 14:40:21 +02:00

Merge pull request #21 from MatrixTunnel/dev/version-strings

Update version strings + add constant
Dieser Commit ist enthalten in:
Andrew Steinborn 2018-08-06 19:13:19 -04:00 committet von GitHub
Commit c17b6c1680
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23
3 geänderte Dateien mit 6 neuen und 2 gelöschten Zeilen

Datei anzeigen

@ -25,7 +25,7 @@ It is sufficient to run `./gradlew build` to run the full build cycle.
## Status
Velocity is far from finished, but most of the essential pieces are in place:
you can switch between two servers running Minecraft 1.9-1.13. More versions
you can switch between two servers running Minecraft 1.8-1.13. More versions
and functionality is planned.
You should join us on **irc.spi.gt** `#velocity` or send us a pull request.

Datei anzeigen

@ -4,6 +4,7 @@ import com.google.common.base.Preconditions;
import com.velocitypowered.proxy.VelocityServer;
import com.velocitypowered.proxy.config.VelocityConfiguration;
import com.velocitypowered.proxy.protocol.MinecraftPacket;
import com.velocitypowered.proxy.protocol.ProtocolConstants;
import com.velocitypowered.proxy.protocol.packet.StatusPing;
import com.velocitypowered.proxy.protocol.packet.StatusRequest;
import com.velocitypowered.proxy.protocol.packet.StatusResponse;
@ -35,7 +36,7 @@ public class StatusSessionHandler implements MinecraftSessionHandler {
// Status request
ServerPing ping = new ServerPing(
new ServerPing.Version(connection.getProtocolVersion(), "Velocity 1.9-1.13"),
new ServerPing.Version(connection.getProtocolVersion(), "Velocity " + ProtocolConstants.SUPPORTED_GENERIC_VERSION_STRING),
new ServerPing.Players(0, configuration.getShowMaxPlayers()),
configuration.getMotdComponent(),
null

Datei anzeigen

@ -17,6 +17,9 @@ public enum ProtocolConstants { ;
public static final int MINECRAFT_1_13 = 393;
public static final int MINIMUM_GENERIC_VERSION = MINECRAFT_1_8;
public static final int MAXIMUM_GENERIC_VERSION = MINECRAFT_1_13;
public static final String SUPPORTED_GENERIC_VERSION_STRING = "1.8-1.13";
public static final int[] SUPPORTED_VERSIONS = new int[] {
MINECRAFT_1_8,