Interface GeyserServerPortGetter
- All Known Implementing Classes:
IntegratedServerMixin,MinecraftDedicatedServerMixin
public interface GeyserServerPortGetter
Represents a getter to the server port in the dedicated server and in the integrated server.
-
Method Summary
-
Method Details
-
geyser$getServerPort
int geyser$getServerPort()Returns the server port.- If it's a dedicated server, it will return the server port specified in the
server.propertiesfile. - If it's an integrated server, it will return the LAN port if opened, else -1.
MinecraftServer.getPort()doesn't return the LAN port if it's the integrated server, and changing the behavior of this method via a mixin should be avoided as it could have unexpected consequences.- Returns:
- The server port.
- If it's a dedicated server, it will return the server port specified in the
-