Beispiel #1
0
        public static void Save()
        {
            var dts = DbSerializer.CustomTypeToBytes(UserProfile.Profile, typeof(Profile));

            C2SSender.Save(UserProfile.ProfileName, dts);
            WorldInfoManager.Save();
        }
Beispiel #2
0
        public static void SaveToDB()
        {
            WorldInfoManager.Save();

            FileStream fs  = new FileStream(string.Format("./Save/{0}.db", ProfileName), FileMode.OpenOrCreate);
            var        dts = DbSerializer.CustomTypeToBytes(Profile, typeof(Profile));

            fs.Write(dts, 0, dts.Length);
            fs.Close();
        }