Esempio n. 1
0
        public static void Load()
        {
            old = new OldPerms();
            if (PropertiesFile.Read(Paths.ServerPropsFile, ref old, LineProcessor))
            {
                Server.SettingsUpdate();
            }

            CountdownGame.Config.Load();
            ZSGame.Config.Load();
            LSGame.Config.Load();
            CTFGame.Config.Load();
            TWGame.Config.Load();

            Database.Backend = Server.Config.UseMySQL ? MySQLBackend.Instance : SQLiteBackend.Instance;
            #pragma warning disable 0618
            Server.DefaultColor = Server.Config.DefaultColor;
            Server.moneys       = Server.Config.Currency;
            #pragma warning restore 0618

            if (!Directory.Exists(Server.Config.BackupDirectory))
            {
                Server.Config.BackupDirectory = "levels/backups";
            }

            Save();
            Server.SetMainLevel(Server.Config.MainLevel);
        }
Esempio n. 2
0
        public static void Load()
        {
            old = new OldPerms();
            if (PropertiesFile.Read(Paths.ServerPropsFile, ref old, LineProcessor))
            {
                Server.SettingsUpdate();
            }

            CountdownGame.Config.Load();
            ZSGame.Config.Load();
            LSGame.Config.Load();
            CTFGame.Config.Load();
            TWGame.Config.Load();

            Database.Backend = Server.Config.UseMySQL ? MySQLBackend.Instance : SQLiteBackend.Instance;

            if (!Directory.Exists(Server.Config.BackupDirectory))
            {
                Server.Config.BackupDirectory = "levels/backups";
            }

            Save();
            Server.SetMainLevel(Server.Config.MainLevel);
        }