CLI: Warn when running with name verification disabled on startup

This commit is contained in:
UnknownShadow200 2022-01-03 14:47:28 +11:00
parent f40044cf24
commit f20ae79f9c

View File

@ -79,6 +79,8 @@ namespace MCGalaxy.Cli {
Server.Start();
Console.Title = Server.Config.Name + " - " + Server.SoftwareNameVersioned;
Console.CancelKeyPress += OnCancelKeyPress;
CheckNameVerification();
ConsoleLoop();
} catch (Exception e) {
Logger.LogError(e);
@ -159,6 +161,11 @@ namespace MCGalaxy.Cli {
}
static void CheckNameVerification() {
if (Server.Config.VerifyNames) return;
Write("&eWARNING: Name verification is disabled! This means players can login as anyone, including YOU");
}
static void LogNewerVersionDetected(object sender, EventArgs e) {
Write("&cMCGalaxy update available! Update by replacing with the files from " + Updater.UploadsURL);
}