mirror of
https://github.com/rafi1212122/BLHX.Server.git
synced 2025-12-12 14:34:39 +01:00
24 lines
482 B
C#
24 lines
482 B
C#
using BLHX.Server.Common.Utils;
|
|
|
|
namespace BLHX.Server.Common.Data;
|
|
|
|
public class Config : Singleton<Config>
|
|
{
|
|
public string Address { get; set; } = "127.0.0.1";
|
|
public uint Port { get; set; } = 20000;
|
|
|
|
public static void Load()
|
|
{
|
|
Instance = JSON.Load<Config>(JSON.ConfigPath);
|
|
|
|
Logger.c.Log($"Config loaded");
|
|
}
|
|
|
|
public static void Save()
|
|
{
|
|
JSON.Save(JSON.ConfigPath, Instance);
|
|
|
|
Logger.c.Log("Config saved");
|
|
}
|
|
}
|