diff --git a/VTOL_2.0.0/.vs/VTOL/DesignTimeBuild/.dtbcache.v2 b/VTOL_2.0.0/.vs/VTOL/DesignTimeBuild/.dtbcache.v2
index 5ac81567..7bf34cfe 100644
Binary files a/VTOL_2.0.0/.vs/VTOL/DesignTimeBuild/.dtbcache.v2 and b/VTOL_2.0.0/.vs/VTOL/DesignTimeBuild/.dtbcache.v2 differ
diff --git a/VTOL_2.0.0/MainWindow.xaml.cs b/VTOL_2.0.0/MainWindow.xaml.cs
index 5382e50f..06ccd0ce 100644
--- a/VTOL_2.0.0/MainWindow.xaml.cs
+++ b/VTOL_2.0.0/MainWindow.xaml.cs
@@ -107,7 +107,8 @@ public MainWindow()
NotificationManager = new NotificationManager();
minimize_to_tray = Properties.Settings.Default.Minimize_to_Tray;
Profile_TAG.Content = Properties.Settings.Default.Profile_Name;
-
+ Properties.Settings.Default.Profile_Name = "";
+ Properties.Settings.Default.Save();
if (!File.Exists(AppDataFolder + @"\VTOL_DATA\Settings\User_Settings.Json"))
{ string DocumentsFolder = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
@@ -718,9 +719,22 @@ private void NORTHSTAR_BUTTON_Click(object sender, RoutedEventArgs e)
private void Changelog_Click(object sender, RoutedEventArgs e)
{
+ try {
string url = @"https://github.com/R2Northstar/Northstar/releases/tag/v" + NORTHSTAR_BUTTON.Content.ToString().Replace("Northstar Version", "").Replace("-", "").Trim().Replace(" ", "");
OPEN_WEBPAGE(url);
+
+ }
+
+
+ catch (Exception ex)
+ {
+ MessageBox.Show("Exception Encountered! - " + ex.Message);
+ Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}");
+ logger2.Open();
+ logger2.Log($"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}" + ex.Message + Environment.NewLine + ex.StackTrace + Environment.NewLine + ex.Source + Environment.NewLine + ex.InnerException + Environment.NewLine + ex.TargetSite + Environment.NewLine + "From VERSION - " + Assembly.GetExecutingAssembly().GetName().Version.ToString() + Environment.NewLine);
+ logger2.Close();
+ }
}
private void Troubleshoot_Click(object sender, RoutedEventArgs e)
diff --git a/VTOL_2.0.0/Pages/Page_Home.xaml.cs b/VTOL_2.0.0/Pages/Page_Home.xaml.cs
index 00d88450..88699095 100644
--- a/VTOL_2.0.0/Pages/Page_Home.xaml.cs
+++ b/VTOL_2.0.0/Pages/Page_Home.xaml.cs
@@ -45,10 +45,7 @@
using System.Globalization;
using Ionic.Zip;
using VTOL.Scripts;
-using GameFinder.StoreHandlers.Steam;
using System.Runtime.InteropServices;
-using GameFinder.RegistryUtils;
-using GameFinder.StoreHandlers.Origin;
using VTOL.Properties;
using Pixelmaniac.Notifications;
using System.Xml;
@@ -836,62 +833,7 @@ async void Auto_Install_(bool resart_ = false)
}
- public string Search_Using_Game_Lib()
- {
- try
- {
- //////SteamFirst///
- // use the Windows registry on Windows
- // Linux doesn't have a registry
- var handler = RuntimeInformation.IsOSPlatform(OSPlatform.Windows)
- ? new SteamHandler(new WindowsRegistry())
- : new SteamHandler(null);
-
- // method 1: iterate over the game-error result
- SteamGame? steamgame = handler.FindOneGameById(432912, out string[] errors);
-
- if (steamgame != null && steamgame.Name.Count() > 2)
- {
- return steamgame.Path;
- }
- else
- {
- /////Failed/////
- return null;
-
- }
-
-
-
- ///////Origin////
- var Origin_handler = new OriginHandler();
-
- // method 1: iterate over the game-error result
- foreach (var (game, error) in Origin_handler.FindAllGames())
- {
- if (game.InstallPath.Contains("Titanfall2") || game.InstallPath.Contains("TitanFall2"))
- {
- return game.InstallPath;
- }
- else
- {
- /////Failed/////
- return null;
- }
- }
- }
-
- catch (Exception ex)
- {
- Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}");
- Main.logger2.Open();
- Main.logger2.Log($"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}" + ex.Message + Environment.NewLine + ex.StackTrace + Environment.NewLine + ex.Source + Environment.NewLine + ex.InnerException + Environment.NewLine + ex.TargetSite + Environment.NewLine + "From VERSION - " + Assembly.GetExecutingAssembly().GetName().Version.ToString() + Environment.NewLine + System.Reflection.MethodBase.GetCurrentMethod().Name);
- Main.logger2.Close();
-
- }
- return null;
-
- }
+
void Restart()
{
var currentExecutablePath = Process.GetCurrentProcess().MainModule.FileName;
@@ -4221,8 +4163,9 @@ private void Button_MouseLeave_1(object sender, MouseEventArgs e)
void ShowBanner()
{
-
- WARNING_BANNER.Visibility = Visibility.Visible;
+
+
+ WARNING_BANNER.Visibility = Visibility.Visible;
}
@@ -4230,6 +4173,14 @@ void ShowWelcome()
{
DispatchIfNecessary(() =>
{
+ DispatchIfNecessary(async () =>
+ {
+ Main.Profile_TAG.Content = "";
+ Properties.Settings.Default.Profile_Name = "";
+ Properties.Settings.Default.Save();
+ Main.Profile_TAG.Content = Properties.Settings.Default.Profile_Name;
+ Main.Profile_TAG.Refresh();
+ });
WELCOME_BANNER.Visibility = Visibility.Visible;
Main.RootNavigation.IsEnabled = false;
diff --git a/VTOL_2.0.0/Pages/Page_Profiles.xaml b/VTOL_2.0.0/Pages/Page_Profiles.xaml
index c3d2e1a8..9469dd68 100644
--- a/VTOL_2.0.0/Pages/Page_Profiles.xaml
+++ b/VTOL_2.0.0/Pages/Page_Profiles.xaml
@@ -123,7 +123,7 @@
-
+
diff --git a/VTOL_2.0.0/Pages/Page_Profiles.xaml.cs b/VTOL_2.0.0/Pages/Page_Profiles.xaml.cs
index e8738728..dd918a1e 100644
--- a/VTOL_2.0.0/Pages/Page_Profiles.xaml.cs
+++ b/VTOL_2.0.0/Pages/Page_Profiles.xaml.cs
@@ -16,7 +16,6 @@
using System.Runtime.Serialization.Formatters.Binary;
using System.IO.Compression;
using System.Threading;
-using NLog.Targets;
using System.Text.RegularExpressions;
using HandyControl.Tools;
using System.Windows.Media.Animation;
@@ -2000,6 +1999,21 @@ private void Page_Loaded(object sender, RoutedEventArgs e)
try {
DispatchIfNecessary(async () =>
{
+ if (Main.Profile_TAG.Content == null || Main.Profile_TAG.Content == "" || Main.Profile_TAG.Content.ToString().Length < 1)
+ {
+ Clear_Profile.IsEnabled = false;
+
+ }else if (Properties.Settings.Default.Profile_Name == "" || Properties.Settings.Default.Profile_Name == null || Properties.Settings.Default.Profile_Name.Length < 1)
+ {
+ Clear_Profile.IsEnabled = false;
+
+ }
+ else
+ {
+ Clear_Profile.IsEnabled = true;
+
+
+ }
LoadProfiles();
//PopulateListBoxWithRandomPaths();
});
@@ -2232,11 +2246,15 @@ private void I_Backup_Mods_Checked(object sender, RoutedEventArgs e)
private void Clear_Profile_Click(object sender, RoutedEventArgs e)
{
- try {
-
- Properties.Settings.Default.Profile_Name = "";
- Properties.Settings.Default.Save();
- Main.Profile_TAG.Content = Properties.Settings.Default.Profile_Name;
+ try {
+ DispatchIfNecessary(async () =>
+ {
+ Main.Profile_TAG.Content = "";
+ Properties.Settings.Default.Profile_Name = "";
+ Properties.Settings.Default.Save();
+ Main.Profile_TAG.Content = Properties.Settings.Default.Profile_Name;
+ Main.Profile_TAG.Refresh();
+ });
}
catch (Exception ex)
@@ -2251,30 +2269,12 @@ private void Clear_Profile_Click(object sender, RoutedEventArgs e)
private void Clear_Profile_Initialized(object sender, EventArgs e)
{
- try
- {
-
-
- if(Main.Profile_TAG.Content != null || Main.Profile_TAG.Content != ""){
- Clear_Profile.IsEnabled = false;
-
- }
- else
- {
- Clear_Profile.IsEnabled = true;
-
-
- }
- }
-
- catch (Exception ex)
- {
- Main.logger2.Open();
- Main.logger2.Log($"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}" + ex.Message + Environment.NewLine + ex.StackTrace + Environment.NewLine + ex.Source + Environment.NewLine + ex.InnerException + Environment.NewLine + ex.TargetSite + Environment.NewLine + "From VERSION - " + Assembly.GetExecutingAssembly().GetName().Version.ToString() + Environment.NewLine + System.Reflection.MethodBase.GetCurrentMethod().Name);
- Main.logger2.Close();
-
+
+ }
- }
+ private void Clear_Profile_Loaded(object sender, RoutedEventArgs e)
+ {
+
}
}
}
diff --git a/VTOL_2.0.0/Pages/Page_Tools.xaml b/VTOL_2.0.0/Pages/Page_Tools.xaml
index bf30df59..30da36a2 100644
--- a/VTOL_2.0.0/Pages/Page_Tools.xaml
+++ b/VTOL_2.0.0/Pages/Page_Tools.xaml
@@ -436,7 +436,7 @@
-
+
diff --git a/VTOL_2.0.0/Pages/Page_Tools.xaml.cs b/VTOL_2.0.0/Pages/Page_Tools.xaml.cs
index f3e60e16..4a5d9313 100644
--- a/VTOL_2.0.0/Pages/Page_Tools.xaml.cs
+++ b/VTOL_2.0.0/Pages/Page_Tools.xaml.cs
@@ -23,7 +23,6 @@
using SixLabors.ImageSharp;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Processing;
-using Syncfusion;
using Wpf.Ui.Common;
using Brushes = System.Windows.Media.Brushes;
using Image = SixLabors.ImageSharp.Image;
@@ -39,7 +38,6 @@
using System.Diagnostics;
using System.Windows.Media.Animation;
using System.Text.RegularExpressions;
-using NLog;
using System.Reflection;
using Downloader;
using System.ComponentModel;
@@ -404,6 +402,7 @@ public partial class Page_Tools : Page
public Page_Tools()
{
InitializeComponent();
+ try {
string defualt_repak = @"for %%i in ("+'\u0022' + @"%~dp0maps\*" + '\u0022'+ ") do " + '\u0022'+ @"% ~dp0RePak.exe" + '\u0022' + " "+ '\u0022' + "%%i"+ '\u0022' + Environment.NewLine + "pause";
if (Properties.Settings.Default.RePak_Launch_Args == "" || Properties.Settings.Default.RePak_Launch_Args == null)
{
@@ -579,6 +578,14 @@ YOUR DESCRIPTION
Output_Directory.Text = Environment.CurrentDirectory;
Output_Box.Text = Environment.CurrentDirectory;
Tools_Dir = Main.User_Settings_Vars.NorthstarInstallLocation + @"VTOL_ExternalTools\";
+ }
+ catch (Exception ex)
+ {
+ Log.Error(ex, $"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}");
+ Main.logger2.Open();
+ Main.logger2.Log($"A crash happened at {DateTime.Now.ToString("yyyy - MM - dd HH - mm - ss.ff", CultureInfo.InvariantCulture)}{Environment.NewLine}" + ex.Message + Environment.NewLine + ex.StackTrace + Environment.NewLine + ex.Source + Environment.NewLine + ex.InnerException + Environment.NewLine + ex.TargetSite + Environment.NewLine + "From VERSION - " + Assembly.GetExecutingAssembly().GetName().Version.ToString() + Environment.NewLine + System.Reflection.MethodBase.GetCurrentMethod().Name);
+ Main.logger2.Close();
+ }
}
private static MainWindow GetMainWindow()
@@ -2872,34 +2879,47 @@ await Task.Run(() =>
}
private void Tabs_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
-
- if (Tabs.SelectedItem.ToString() != null)
- {
-
- if (Tabs.SelectedValue.ToString().Contains("External Tools"))
+ if (Directory.Exists(Tools_Dir)) {
+ if (Tabs.SelectedItem.ToString() != null)
{
- Check_For_Tools();
- fade_dav(false);
- }
- else if (Tabs.SelectedValue.ToString().Contains("Advocate"))
- {
- fade_dav(true);
- if (Directory.Exists(Tools_Dir + @"RePak") && File.Exists(Tools_Dir + @"RePak\" + "RePak.exe") && !File.Exists(Mod_Adv_Repak_Path))
+ if (Tabs.SelectedValue.ToString().Contains("External Tools"))
{
- Properties.Settings.Default.REpak_Folder_Path = Tools_Dir + @"RePak\" + "RePak.exe"; ;
- Properties.Settings.Default.Save();
- Mod_Adv_Repak_Path = Tools_Dir + @"RePak\" + "RePak.exe";
- Zip_Box_Advocate_Copy.Text = Mod_Adv_Repak_Path;
+ Check_For_Tools();
+ fade_dav(false);
+
}
+ else if (Tabs.SelectedValue.ToString().Contains("Advocate"))
+ {
+ fade_dav(true);
+ if (Directory.Exists(Tools_Dir + @"RePak") && File.Exists(Tools_Dir + @"RePak\" + "RePak.exe") && !File.Exists(Mod_Adv_Repak_Path))
+ {
+ Properties.Settings.Default.REpak_Folder_Path = Tools_Dir + @"RePak\" + "RePak.exe"; ;
+ Properties.Settings.Default.Save();
+ Mod_Adv_Repak_Path = Tools_Dir + @"RePak\" + "RePak.exe";
+ Zip_Box_Advocate_Copy.Text = Mod_Adv_Repak_Path;
+ }
+
}
- else
+ else
+ {
+ fade_dav(false);
+ }
+
+
+ }
+ }
+ else
+ {
+ TryCreateDirectory(Tools_Dir);
+ if (!Directory.Exists(Tools_Dir))
{
- fade_dav(false);
+ SnackBar.Icon = SymbolRegular.ErrorCircle20;
+ SnackBar.Appearance = ControlAppearance.Danger; SnackBar.Title = "ERROR";
+ SnackBar.Message = "Tools Directory Empty and could not be created!";
+ SnackBar.Show();
}
-
-
}
diff --git a/VTOL_2.0.0/VTOL.csproj b/VTOL_2.0.0/VTOL.csproj
index f35238fb..681aa3c0 100644
--- a/VTOL_2.0.0/VTOL.csproj
+++ b/VTOL_2.0.0/VTOL.csproj
@@ -267,27 +267,21 @@
-
-
-
-
-
+
-
+
-
+
-
-
@@ -299,15 +293,13 @@
-
-
-
+
diff --git a/[Titanfall2_Downloadable_Tools]/LEGION+.zip b/[Titanfall2_Downloadable_Tools]/LEGION+.zip
index fddd5dbe..4e059041 100644
Binary files a/[Titanfall2_Downloadable_Tools]/LEGION+.zip and b/[Titanfall2_Downloadable_Tools]/LEGION+.zip differ