Example #1
0
        /// <summary>
        /// Save to XML
        /// </summary>
        /// <param name="fileName"></param>
        /// <returns></returns>
        internal static Model.Model Load(string fileName)
        {
            Model.Model model;

            if (File.Exists(fileName))
            {
                XmlSerializer xsSubmit = new XmlSerializer(typeof(Model.Model));

                using (var sww = new StreamReader(fileName))
                {
                    XmlReader writer = XmlReader.Create(sww);
                    model = (Model.Model)xsSubmit.Deserialize(writer);
                }


                FileManager.SearchForInstalledVersions(model);
                FolderScanner.GetGameInformation(null, "", "");
                SetGameTypes(model);
                CemuFeatures.UpdateFeaturesForInstalledVersions(model);

                SetSaveDirs(model);

                return(model);
            }
            model = new Model.Model();
            return(model);
        }
Example #2
0
        internal static void DownloadCemu(Form parent, Unpacker unpacker, Model.Model model)
        {
            using (FormMultiFileDownload dl = new FormMultiFileDownload(model))
            {
                dl.ShowDialog(parent);
            }

            SearchForInstalledVersions(model);

            if (Directory.Exists("graphicsPacks"))
            {
                FolderScanner.FindGraphicsPacks(new DirectoryInfo(Path.Combine("graphicsPacks", "graphicsPacks")), model.GraphicsPacks);
            }
            FolderScanner.AddGraphicsPacksToGames(model);
            CemuFeatures.UpdateFeaturesForInstalledVersions(model);
        }