diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/04f5124b-0229-496f-8bcb-9d8880905602.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/04f5124b-0229-496f-8bcb-9d8880905602.vsidx deleted file mode 100644 index 48a3723..0000000 Binary files a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/04f5124b-0229-496f-8bcb-9d8880905602.vsidx and /dev/null differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/068892f9-e7ce-4566-ae8a-94f6553c1e82.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/068892f9-e7ce-4566-ae8a-94f6553c1e82.vsidx new file mode 100644 index 0000000..cae370c Binary files /dev/null and b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/068892f9-e7ce-4566-ae8a-94f6553c1e82.vsidx differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/0b02963d-23c0-49b7-a9f8-bbb5d1649240.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/0b02963d-23c0-49b7-a9f8-bbb5d1649240.vsidx deleted file mode 100644 index 5a95df4..0000000 Binary files a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/0b02963d-23c0-49b7-a9f8-bbb5d1649240.vsidx and /dev/null differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/2ab6882b-e530-47f8-a0ed-7e5666790802.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/2ab6882b-e530-47f8-a0ed-7e5666790802.vsidx deleted file mode 100644 index 246215a..0000000 Binary files a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/2ab6882b-e530-47f8-a0ed-7e5666790802.vsidx and /dev/null differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/3ba74aa4-1f34-4681-ae6b-205ea625f65b.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/3ba74aa4-1f34-4681-ae6b-205ea625f65b.vsidx deleted file mode 100644 index 4874334..0000000 Binary files a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/3ba74aa4-1f34-4681-ae6b-205ea625f65b.vsidx and /dev/null differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/400702b1-6508-451e-88e5-a4517a94e8f3.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/400702b1-6508-451e-88e5-a4517a94e8f3.vsidx new file mode 100644 index 0000000..d6fb31a Binary files /dev/null and b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/400702b1-6508-451e-88e5-a4517a94e8f3.vsidx differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/48796b58-52b0-49d1-a1b9-2798dd24949c.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/48796b58-52b0-49d1-a1b9-2798dd24949c.vsidx new file mode 100644 index 0000000..57f07d4 Binary files /dev/null and b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/48796b58-52b0-49d1-a1b9-2798dd24949c.vsidx differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/8cffd8c5-fe0e-4674-bfaf-a8c798a25900.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/8cffd8c5-fe0e-4674-bfaf-a8c798a25900.vsidx new file mode 100644 index 0000000..9c096c5 Binary files /dev/null and b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/8cffd8c5-fe0e-4674-bfaf-a8c798a25900.vsidx differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/cd6ef953-912d-4fa5-a529-0a8dd1c0e81f.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/cd6ef953-912d-4fa5-a529-0a8dd1c0e81f.vsidx deleted file mode 100644 index 676f576..0000000 Binary files a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/cd6ef953-912d-4fa5-a529-0a8dd1c0e81f.vsidx and /dev/null differ diff --git a/VTOL_2.0.0/.vs/VTOL/FileContentIndex/eb8b4d71-ad0b-4e46-8daf-fb55431af441.vsidx b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/eb8b4d71-ad0b-4e46-8daf-fb55431af441.vsidx new file mode 100644 index 0000000..fb1680d Binary files /dev/null and b/VTOL_2.0.0/.vs/VTOL/FileContentIndex/eb8b4d71-ad0b-4e46-8daf-fb55431af441.vsidx differ diff --git a/VTOL_2.0.0/MainWindow.xaml.cs b/VTOL_2.0.0/MainWindow.xaml.cs index ff78f2d..d50b18e 100644 --- a/VTOL_2.0.0/MainWindow.xaml.cs +++ b/VTOL_2.0.0/MainWindow.xaml.cs @@ -382,7 +382,7 @@ public void SwitchCursor(string cur) } switch (cur) { - case "Defualt": + case "Default": this.Cursor = null; break; diff --git a/VTOL_2.0.0/Pages/Page_Settings.xaml.cs b/VTOL_2.0.0/Pages/Page_Settings.xaml.cs index 91e9030..919c7fa 100644 --- a/VTOL_2.0.0/Pages/Page_Settings.xaml.cs +++ b/VTOL_2.0.0/Pages/Page_Settings.xaml.cs @@ -75,8 +75,8 @@ public class PropertyGridDemoModel [Category("Github")] public string Master_Server_Url { get; set; } - [Category("Cursor")] - public cur Cursor { get; set; } + //[Category("Cursor")] + //public cur Cursor { get; set; } //public Theme Theme { get; set; } //[Category("Themes")] @@ -92,7 +92,7 @@ public enum Theme } public enum cur { - Defualt, + Default, LeadWall, Ronin } @@ -268,12 +268,10 @@ private void Settings_LostFocus(object sender, RoutedEventArgs e) } DispatchIfNecessary(async () => { - if(Settings_.Cursor != cur.Defualt) - { + Main.SwitchCursor(Settings_.Cursor.ToString()); - } - + if (curr_lang.ToString() != Settings_.Language.ToString()) { Dialog_.ButtonLeftName = VTOL.Resources.Languages.Language.Page_Settings_Settings_LostFocus_Restart; diff --git a/VTOL_2.0.0/Pages/Page_Tools.xaml.cs b/VTOL_2.0.0/Pages/Page_Tools.xaml.cs index 6b0affb..3129dfc 100644 --- a/VTOL_2.0.0/Pages/Page_Tools.xaml.cs +++ b/VTOL_2.0.0/Pages/Page_Tools.xaml.cs @@ -2028,590 +2028,7 @@ private void Button_Click(object sender, RoutedEventArgs e) string Mod_Adv_Version_Num; string Mod_Adv_Skin_Name; string Mod_Adv_Output_Path; - //public void Convert() - //{ - // try { - - // //Mod_Adv_Version_Num = Mod_version_number_Advocate.Text; - // //Mod_Adv_Author_name = Mod_Author_Name_Advocate.Text; - // //Mod_Adv_Skin_Name = Mod_Skin_Name_Advocate.Text; - - // if(Mod_Adv_Author_name == null || Mod_Adv_Author_name == "" || Mod_Adv_Author_name.Count() < 2) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Author Name Is Minimum 2 Letters"; - // SnackBar.Show(); - // } - // if (Mod_Adv_Version_Num == null || Mod_Adv_Version_Num == "" || Mod_Adv_Version_Num.Count() < 2 || !Regex.Match(Mod_Adv_Version_Num, "^\\d+.\\d+.\\d+$").Success) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Version Number Is Invalid"; - // SnackBar.Show(); - // } - // if (Mod_Adv_Skin_Name == null || Mod_Adv_Skin_Name == "" || Mod_Adv_Skin_Name.Count() < 2) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Skin Name Is Is Invalid"; - // SnackBar.Show(); - // } - - // //if (Description_Box_Advocate.Document.Blocks.Count < 1) - // //{ - // // SnackBar.Appearance = ControlAppearance.Danger; - // // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // // SnackBar.Message = "Description Is Invalid"; - // // SnackBar.Show(); - // //} - // if (!File.Exists(Mod_Adv_Skin_Path)) - // { - - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Skin Content Is Invalid!"; - // SnackBar.Show(); - // return; - // } - // if (!Directory.Exists(Mod_Adv_Output_Path)) - // { - - - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Output Path Is Invalid!"; - // SnackBar.Show(); - // return; - // } - // if (!File.Exists(Mod_Adv_Repak_Path)) - // { - - - - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "RePak Path Is Invalid!"; - // SnackBar.Show(); - // return; - // } - // if (!File.Exists(Mod_Adv_Icon_Path)) - // { - - - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Icon Content Is Invalid!"; - // SnackBar.Show(); - // return; - // } - - // // the temp path is appended with the current date and time to prevent duplicates - // string tempFolderPath = Path.GetTempPath() + "/Advocate/" + DateTime.Now.ToString("yyyyMMdd-THHmmss"); - // string skinTempFolderPath = Path.GetFullPath(tempFolderPath + "/Skin"); - // string modTempFolderPath = Path.GetFullPath(tempFolderPath + "/Mod"); - // string repakTempFolderPath = Path.GetFullPath(tempFolderPath + "/RePak"); - - // // try convert stuff, if we get a weird exception, don't crash preferably - // try - // { - // ///////////////////////////// - // // create temp directories // - // ///////////////////////////// - - // // - // // directory for unzipped file - // TryCreateDirectory(skinTempFolderPath); - - // // directory for TS-compliant mod - // TryCreateDirectory(modTempFolderPath); - - // // directory for RePak things - // TryCreateDirectory(repakTempFolderPath); - - - // /////////////////////////////// - // // unzip skin to temp folder // - // /////////////////////////////// - - - // try - // { - // ZipFile.ExtractToDirectory(Mod_Adv_Skin_Path, skinTempFolderPath, true); - // } - // catch (InvalidDataException ex) - // { - // Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}"); - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Unable to unzip skin!"; - // SnackBar.Show(); - // return; - - // } - - - // //////////////////////////////////// - // // create temp mod file structure // - // //////////////////////////////////// - - - // TryCreateDirectory(modTempFolderPath + "\\packages\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + "\\paks"); - - - // ///////////////////// - // // create icon.png // - // ///////////////////// - - // if (Mod_Adv_Icon_Path == "") - // { - // // fuck you, im using the col of the first folder i find, shouldve specified an icon path - // string[] skinPaths = Directory.GetDirectories(skinTempFolderPath); - // if (skinPaths.Length == 0) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No Skins found in zip!"; - // SnackBar.Show(); - // return; - // } - // string[] resolutions = Directory.GetDirectories(skinPaths[0]); - // if (resolutions.Length == 0) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No Skins found in zip!"; - // SnackBar.Show(); - // return; - // } - // // find highest resolution folder - // int highestRes = 0; - // foreach (string resolution in resolutions) - // { - // string? thing = Path.GetFileName(resolution); - // // check if higher than highestRes and a power of 2 - // if (int.TryParse(thing, out int res) && res > highestRes && (highestRes & (highestRes - 1)) == 0) - // { - // highestRes = res; - // } - // } - // // check that we actually found something - // if (highestRes == 0) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No valid image resolutions found in zip!"; - // SnackBar.Show(); - // return; - // } - - // string[] files = Directory.GetFiles(skinPaths[0] + "\\" + highestRes.ToString()); - // if (files.Length == 0) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No files in highest resolution folder!"; - // SnackBar.Show(); - // return; - // } - // // find _col file - // string colPath = ""; - // foreach (string file in files) - // { - // if (file.EndsWith("_col.dds")) - // { - // colPath = file; - // break; - // } - // } - // if (colPath == "") - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No _col texture found in highest resolution folder"; - // SnackBar.Show(); - // return; - // } - - // if (!DdsToPng(colPath, modTempFolderPath + "\\icon.png")) - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "Failed to convert dds to png for icon!"; - // SnackBar.Show(); - // return; - // } - // } - // else - // { - // // check that png is correct size - // System.Drawing.Image img = System.Drawing.Image.FromFile(Mod_Adv_Icon_Path); - - - // // copy png over - // TryCopyFile(Mod_Adv_Icon_Path, modTempFolderPath + "\\icon.png",true); - // } - - // // ConvertTaskComplete(); - - // ////////////////////// - // // create README.md // - // ////////////////////// - - // // if (Description_Box_Advocate.Document.Blocks.Count > 1) - // // { - // // TextRange textRange = new TextRange( - // // // TextPointer to the start of content in the RichTextBox. - // // Description_Box_Advocate.Document.ContentStart, - // // // TextPointer to the end of content in the RichTextBox. - // // Description_Box_Advocate.Document.ContentEnd - // //); - - // // The Text property on a TextRange object returns a string - // // representing the plain text content of the TextRange. - - - // File.WriteAllText(modTempFolderPath + "\\README.md", textRange.Text); - // } - // else - // { - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = "No files in highest resolution folder!"; - // SnackBar.Show(); - - // } - - - // ////////////////////////// - // // create manifest.json // - // ////////////////////////// - - - // string manifest = string.Format("{{\n\"name\":\"{0}\",\n\"version_number\":\"{1}\",\n\"website_url\":\"\",\n\"dependencies\":[],\n\"description\":\"{2}\"\n}}", Mod_Adv_Skin_Name.Replace(' ', '_'), Mod_Adv_Version_Num, string.Format("Skin made by {0}", Mod_Adv_Author_name)); - // File.WriteAllText(modTempFolderPath + "\\manifest.json", manifest); - - - // ///////////////////// - // // create mod.json // - // ///////////////////// - - - // string modJson = string.Format("{{\n\"Name\": \"{0}\",\n\"Description\": \"\",\n\"Version\": \"{1}\",\n\"LoadPriority\": 1,\n\"ConVars\":[],\n\"Scripts\":[],\n\"Localisation\":[]\n}}", Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name, Mod_Adv_Version_Num); - // File.WriteAllText(modTempFolderPath + "\\packages\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + "\\mod.json", modJson); - - - // ////////////////////////////////////////////////////////////////// - // // create map.json and move textures to temp folder for packing // - // ////////////////////////////////////////////////////////////////// - - // Advocate.Conversion.JSON.Map map = new(Mod_Adv_Skin_Name, $"{repakTempFolderPath}/assets", $"{modTempFolderPath}/mods/{Mod_Adv_Author_name}.{Mod_Adv_Skin_Name}/paks"); - - // // this tracks the textures that we have already added to the json, so we can avoid duplicates in there - // List textures = new(); - // // this tracks the different skin types that we have found, for description parsing later - // List skinTypes = new(); - - // // this keeps track of the different DDS files we are handling and combining - // // the key is the texture name (example: CAR_Default_col) - // Dictionary ddsManagers = new(); - // /* The plan here is to: - // * 1. find all textures, and put them into arrays/lists of mip sizes (where 2^index == image width/height) - // * 2. take each dds, and rip the image data directly from it, putting them together to create as many mip levels as we can - // * 3. create the lower level mips from the highest resolution image that we have - // * (decompression and recompression harms image quality so we want to avoid this wherever we can) - // * 4. put the raw image data for the mips into one dds file - // * - // * ASSUMPTIONS: - // * 1. the lower resolution images use the same compression format as the highest resolution image - // * if this is not the case, log, and skip the lower level image (this means we have to generate more mip levels, which is bad) - // * - // */ - - // // find all DDS files within the zip folder - // string[] ddsImages = Directory.GetFiles(skinTempFolderPath, "*.dds", SearchOption.AllDirectories); - - // // add all of the files to their respective DDS Managers - // foreach (string path in ddsImages) - // { - // string filename = Path.GetFileNameWithoutExtension(path); - - // // create a new DDS.Manager if needed - // if (!ddsManagers.ContainsKey(filename)) - // { - // // Debug($"Found new texture type '{filename}', creating Manager."); - // ddsManagers.Add(filename, new Advocate.DDS.Manager()); - // } - - // // read the dds file into the Manager - // // Debug($"Adding new image for texture type '{filename}' from path '{path}'"); - // BinaryReader reader = new(new FileStream(path, FileMode.Open)); - // ddsManagers[filename].LoadImage(reader); - // reader.Close(); - - // // add texture to skinTypes for tracking which skins are in the package - // string type = Path.GetFileNameWithoutExtension(path).Split("_")[0]; - // if (!skinTypes.Contains(type)) - // { - // // Debug($"Found new skin type for description handling ({type})"); - // skinTypes.Add(type); - // } - // } - - // // save all dds images - // foreach (KeyValuePair pair in ddsManagers) - // { - // string texturePath = TextureNameToPath(pair.Key); - // if (texturePath == "") - // { - // // Logging.Logger.Error($"Failed to find texture path for {pair.Key}"); - // // return false; - // } - // string filePath = $"{repakTempFolderPath}/assets/{texturePath}.dds"; - // // writer doesnt create directories, so do it beforehand - // Directory.CreateDirectory(Path.GetDirectoryName(filePath)); - - // //Debug($"Saving texture (with {pair.Value.MipMapCount} mips) to path '{filePath}'"); - - // // create writer and save the image - // BinaryWriter writer = new(new FileStream(filePath, FileMode.Create)); - - // // generate missing mips - // if (pair.Value.HasMissingMips()) - // { - // // Debug($"Texture being saved to '{filePath}' has missing mip levels"); - // // Info($"Generating MipMaps... ({pair.Key})"); - - - - - - - - - - - - - - - - // // pair.Value.GenerateMissingMips(texconvPath); - - - // } - - // pair.Value.Convert(); - // pair.Value.SaveImage(writer); - - // // close the writer - // writer.Close(); - - // // add asset to map file - // map.AddTextureAsset(texturePath); - - // // add texturePath to tracked textures - // textures.Add(texturePath); - // } - - // // write the map json - // // - - - - - - - - - // //File.WriteAllText($"{repakTempFolderPath}/map.json", JsonSerializer.Serialize(map, jsonOptions)); - - - - - - - - - - - - - - - - // // string map = string.Format("{{\n\"name\":\"{0}\",\n\"assetsDir\":\"{1}\",\n\"outputDir\":\"{2}\",\n\"version\": 7,\n\"files\":[\n", Mod_Adv_Skin_Name, (repakTempFolderPath + "\\assets").Replace('\\', '/'), (modTempFolderPath + "\\packages\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + "\\paks").Replace('\\', '/')); - // //// this tracks the textures that we have already added to the json, so we can avoid duplicates in there - // //List textures = new(); - // //bool isFirst = true; - // //foreach (string skinPath in Directory.GetDirectories(skinTempFolderPath)) - // // {// some skins have random files and folders in here, like images and stuff, so I have to do sorting in an annoying way - // // List parsedDirs = new(); - // // foreach (string dir in Directory.GetDirectories(skinPath)) - // // { - // // // only add to the list of dirs - // // if (int.TryParse(Path.GetFileName(dir), out int val)) - // // { - // // parsedDirs.Add(dir); - // // } - // // } - // // foreach (string resolution in Directory.GetDirectories(skinPath).OrderBy(path => int.Parse(Path.GetFileName(path)))) - // // { - // // if (int.TryParse(Path.GetFileName(resolution), out int res)) - // // { - // // foreach (string texture in Directory.GetFiles(resolution)) - // // { - // // // move texture to temp folder for packing - // // // convert from skin tool syntax to actual texture path, gotta be hardcoded because pain - // // string texturePath = TextureNameToPath(Path.GetFileNameWithoutExtension(texture)); - // // if (texturePath == "") - // // { - // // // ConversionFailed(button, styleProperty, "Failed to convert texture '" + Path.GetFileNameWithoutExtension(texture) + "')"); - // // return; - // // } - - // // // avoid duplicate textures in the json - // // if (!textures.Contains(texturePath)) - // // { - // // // dont add a comma on the first one - // // if (!isFirst) - // // map += ",\n"; - // // map += $"{{\n\"$type\":\"txtr\",\n\"path\":\"{texturePath}\",\n\"disableStreaming\":true,\n\"saveDebugName\":true\n}}"; - // // // add texture to tracked textures - // // textures.Add(texturePath); - // // } - // // isFirst = false; - // // // copy file - // // TryCreateDirectory(Directory.GetParent($"{repakTempFolderPath}\\assets\\{texturePath}.dds").FullName); - - // // DdsHandler handler = new(texture); - // // handler.Convert(); - // // handler.Save($"{repakTempFolderPath}\\assets\\{texturePath}.dds"); - // // } - // // } - // // } - // //} - - // //// end the json - // //map += "\n]\n}"; - // //File.WriteAllText(repakTempFolderPath + "\\map.json", map); - - - // ////////////////////////// - // // pack using RePak.exe // - // ////////////////////////// - - // // Message = "Packing using RePak..."; - - // //var sb = new StringBuilder(); - - // Process P = new(); - - // //P.StartInfo.RedirectStandardOutput = true; - // //P.StartInfo.RedirectStandardError = true; - // //P.OutputDataReceived += (sender, args) => sb.AppendLine(args.Data); - // //P.ErrorDataReceived += (sender, args) => sb.AppendLine(args.Data); - // //P.StartInfo.UseShellExecute = false; - // P.StartInfo.FileName = Mod_Adv_Repak_Path; - // P.StartInfo.Arguments = "\"" + repakTempFolderPath + "\\map.json\""; - // P.Start(); - // //P.BeginOutputReadLine(); - // //P.BeginErrorReadLine(); - // P.WaitForExit(); - - // if (P.ExitCode == 1) - // { - // // ConversionFailed(button, styleProperty, "RePak failed to pack the rpak!"); - // return; - // } - - - // ////////////////////// - // // create rpak.json // - // ////////////////////// - - - // string rpakjson = string.Format("{{\n\"Preload\":\n{{\n\"{0}\":true\n}}\n}}", Mod_Adv_Skin_Name + ".rpak"); - - // File.WriteAllText(modTempFolderPath + "\\packages\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + "\\paks\\rpak.json", rpakjson); - - - // /////////////////// - // // zip up result // - // /////////////////// - - - // ZipFile.CreateFromDirectory(modTempFolderPath, tempFolderPath + "\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + ".zip"); - - - // //////////////////////////////////// - // // move result out of temp folder // - // //////////////////////////////////// - - - // TryMoveFile(tempFolderPath + "\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + ".zip", Mod_Adv_Output_Path + "\\" + Mod_Adv_Author_name + "." + Mod_Adv_Skin_Name + ".zip", true); - - // } - // catch (Exception ex) - // { - // //Removed PaperTrailSystem Due to lack of reliability. - - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = ex.Message; - // SnackBar.Show(); - // Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}"); - - // return; - // } - // finally - // { - // ///////////// - // // cleanup // - // ///////////// - - - // // delete temp folders - // // delete temp folders - // try - // { - // // delete temp folders - // if (Directory.Exists(tempFolderPath)) - // Directory.Delete(tempFolderPath, true); - // } - // catch (Exception ex) - // { - - // } - // } - - - // // everything is done and good - // SnackBar.Appearance = ControlAppearance.Success; - // SnackBar.Title = VTOL.Resources.Languages.Language.SUCCESS; - // SnackBar.Message = "Conversion Completed Successfully"; - // SnackBar.Show(); - - - // } - // catch (Exception ex) - // { - // //Removed PaperTrailSystem Due to lack of reliability. - // SnackBar.Appearance = ControlAppearance.Danger; - // SnackBar.Title = VTOL.Resources.Languages.Language.ERROR; - // SnackBar.Message = ex.Message; - // SnackBar.Show(); - // Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}"); - - // } - - - //} + private bool DdsToPng(string imagePath, string outputPath) { diff --git a/VTOL_2.0.0/Resources/Cursors/Leadwallcur.cur b/VTOL_2.0.0/Resources/Cursors/Leadwallcur.cur index 557be3e..232cec4 100644 Binary files a/VTOL_2.0.0/Resources/Cursors/Leadwallcur.cur and b/VTOL_2.0.0/Resources/Cursors/Leadwallcur.cur differ diff --git a/VTOL_2.0.0/Resources/Cursors/NormalCurTf2.cur b/VTOL_2.0.0/Resources/Cursors/NormalCurTf2.cur index 4ab9206..a8382c5 100644 Binary files a/VTOL_2.0.0/Resources/Cursors/NormalCurTf2.cur and b/VTOL_2.0.0/Resources/Cursors/NormalCurTf2.cur differ diff --git a/VTOL_2.0.0/VTOL.csproj b/VTOL_2.0.0/VTOL.csproj index 179f46e..4c7fa68 100644 --- a/VTOL_2.0.0/VTOL.csproj +++ b/VTOL_2.0.0/VTOL.csproj @@ -782,12 +782,12 @@ PreserveNewest - + Always - - - Always - + + + PreserveNewest + Always