コード例 #1
0
 public static void ReloadGameConfiguration()
 {
     try
     {
         GameConfiguration = InnerSpaceSettings.Load(ISPath + @"\GameConfiguration.XML");
     }
     catch
     {
         GameConfiguration = null;
     }
 }
コード例 #2
0
        public bool Store(string filename)
        {
            try
            {
                InnerSpaceSettings issettings = new InnerSpaceSettings(this);
                using (TextWriter w = new StreamWriter(filename, false, System.Text.Encoding.UTF8))
                {
                    XmlSerializer s = new XmlSerializer(typeof(InnerSpaceSettings));
                    s.Serialize(w, issettings);
                    return(true);
                }
            }
            catch (Exception e)
            {
//                MessageBox.Show(e.ToString());
//                return false;
                throw;
            }
        }