1
0
mirror of https://github.com/GeyserMC/Geyser.git synced 2025-12-19 14:59:27 +00:00

Indicate 1.21.112/1.21.113 support, track server platform types in bstats metrics

This commit is contained in:
onebeastchris
2025-10-12 13:28:40 +02:00
parent 8a6bb8e0ba
commit 826b4b4e48
11 changed files with 52 additions and 5 deletions

View File

@@ -271,6 +271,11 @@ public class GeyserBungeePlugin extends Plugin implements GeyserBootstrap {
return Paths.get(getProxy().getName().equals("BungeeCord") ? "proxy.log.0" : "logs/latest.log");
}
@Override
public @NonNull String getServerPlatform() {
return getProxy().getName();
}
@Nullable
@Override
public SocketAddress getSocketAddress() {

View File

@@ -238,4 +238,9 @@ public abstract class GeyserModBootstrap implements GeyserBootstrap {
return false;
}
}
@Override
public @NonNull String getServerPlatform() {
return server.getServerModName();
}
}

View File

@@ -402,6 +402,11 @@ public class GeyserSpigotPlugin extends JavaPlugin implements GeyserBootstrap {
return this.minecraftVersion;
}
@Override
public @NonNull String getServerPlatform() {
return Bukkit.getName();
}
@Override
public SocketAddress getSocketAddress() {
return this.geyserInjector.getServerSocketAddress();

View File

@@ -314,6 +314,11 @@ public class GeyserStandaloneBootstrap implements GeyserBootstrap {
return new GeyserStandaloneDumpInfo(this);
}
@Override
public @NonNull String getServerPlatform() {
return PlatformType.STANDALONE.platformName();
}
@NonNull
@Override
public String getServerBindAddress() {

View File

@@ -230,6 +230,11 @@ public class GeyserVelocityPlugin implements GeyserBootstrap {
return new GeyserVelocityDumpInfo(proxyServer);
}
@Override
public @NonNull String getServerPlatform() {
return proxyServer.getVersion().getName();
}
@Nullable
@Override
public SocketAddress getSocketAddress() {

View File

@@ -230,6 +230,11 @@ public class GeyserViaProxyPlugin extends ViaProxyPlugin implements GeyserBootst
return new GeyserViaProxyDumpInfo();
}
@Override
public @NonNull String getServerPlatform() {
return PlatformType.VIAPROXY.platformName();
}
@NonNull
@Override
public String getServerBindAddress() {