mirror of
https://github.com/Melledy/Grasscutter.git
synced 2024-11-29 13:17:21 +00:00
Add PublicPort field to server
This commit is contained in:
parent
104d10352b
commit
4605c6506e
@ -54,6 +54,7 @@ public final class Config {
|
||||
public String Ip = "0.0.0.0";
|
||||
public String PublicIp = "127.0.0.1";
|
||||
public int Port = 22102;
|
||||
public int PublicPort = 0;
|
||||
|
||||
public String DispatchServerDatabaseUrl = "mongodb://localhost:27017";
|
||||
public String DispatchServerDatabaseCollection = "grasscutter";
|
||||
|
@ -108,7 +108,7 @@ public final class DispatchServer {
|
||||
|
||||
RegionInfo serverRegion = regionQuery.getRegionInfo().toBuilder()
|
||||
.setIp((Grasscutter.getConfig().getGameServerOptions().PublicIp.isEmpty() ? Grasscutter.getConfig().getGameServerOptions().Ip : Grasscutter.getConfig().getGameServerOptions().PublicIp))
|
||||
.setPort(Grasscutter.getConfig().getGameServerOptions().Port)
|
||||
.setPort(Grasscutter.getConfig().getGameServerOptions().PublicPort != 0 ? Grasscutter.getConfig().getGameServerOptions().PublicPort : Grasscutter.getConfig().getGameServerOptions().Port)
|
||||
.setSecretKey(ByteString.copyFrom(FileUtils.read(Grasscutter.getConfig().KEY_FOLDER + "dispatchSeed.bin")))
|
||||
.build();
|
||||
|
||||
|
@ -41,7 +41,7 @@ public class PacketPlayerLoginRsp extends GenshinPacket {
|
||||
|
||||
RegionInfo serverRegion = regionQuery.getRegionInfo().toBuilder()
|
||||
.setIp((Grasscutter.getConfig().getGameServerOptions().PublicIp.isEmpty() ? Grasscutter.getConfig().getGameServerOptions().Ip : Grasscutter.getConfig().getGameServerOptions().PublicIp))
|
||||
.setPort(Grasscutter.getConfig().getGameServerOptions().Port)
|
||||
.setPort(Grasscutter.getConfig().getGameServerOptions().PublicPort != 0 ? Grasscutter.getConfig().getGameServerOptions().PublicPort : Grasscutter.getConfig().getGameServerOptions().Port)
|
||||
.setSecretKey(ByteString.copyFrom(FileUtils.read(Grasscutter.getConfig().KEY_FOLDER + "dispatchSeed.bin")))
|
||||
.build();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user