Fix Public Issue #10

This commit is contained in:
Somebody
2024-08-17 19:42:40 +08:00
parent 13b4f4899a
commit bf850af9d1
218 changed files with 994 additions and 980 deletions

View File

@@ -14,13 +14,19 @@ public class ConfigContainer
public class HttpServerConfig
{
public string BindAddress { get; set; } = "0.0.0.0";
public string PublicAddress { get; set; } = "127.0.0.1";
public int PublicPort { get; set; } = 443;
public int Port { get; set; } = 443;
public bool UseSSL { get; set; } = true;
public string GetDisplayAddress()
{
return (UseSSL ? "https" : "http") + "://" + PublicAddress + ":" + PublicPort;
return (UseSSL ? "https" : "http") + "://" + PublicAddress + ":" + Port;
}
public string GetBindDisplayAddress()
{
return (UseSSL ? "https" : "http") + "://" + BindAddress + ":" + Port;
}
}
@@ -32,16 +38,16 @@ public class KeyStoreConfig
public class GameServerConfig
{
public string BindAddress { get; set; } = "0.0.0.0";
public string PublicAddress { get; set; } = "127.0.0.1";
public uint PublicPort { get; set; } = 23301;
public uint Port { get; set; } = 23301;
public string GameServerId { get; set; } = "dan_heng";
public string GameServerName { get; set; } = "DanhengServer";
public string GameServerDescription { get; set; } = "A re-implementation of StarRail server";
public int KcpInterval { get; set; } = 40;
public string GetDisplayAddress()
{
return PublicAddress + ":" + PublicPort;
return PublicAddress + ":" + Port;
}
}