diff --git a/SPTInstaller/Installer Tasks/IntializationTask.cs b/SPTInstaller/Installer Tasks/IntializationTask.cs
index 5d9a163..b713465 100644
--- a/SPTInstaller/Installer Tasks/IntializationTask.cs
+++ b/SPTInstaller/Installer Tasks/IntializationTask.cs
@@ -34,11 +34,6 @@ public class InitializationTask : InstallerTaskBase
return Result.FromError("Unable to find original EFT directory, please make sure EFT is installed. Please also run EFT once");
}
- if (_data.OriginalGamePath == _data.TargetInstallPath)
- {
- return Result.FromError("Installer is located in EFT's original directory. Please move the installer to a seperate folder as per the guide");
- }
-
if (File.Exists(Path.Join(_data.TargetInstallPath, "EscapeFromTarkov.exe")))
{
return Result.FromError("Installer is located in a folder that has existing game files. Please make sure the installer is in a fresh folder as per the guide");
diff --git a/SPTInstaller/SPTInstaller.csproj b/SPTInstaller/SPTInstaller.csproj
index 263d4bf..b919a07 100644
--- a/SPTInstaller/SPTInstaller.csproj
+++ b/SPTInstaller/SPTInstaller.csproj
@@ -9,8 +9,8 @@
icon.ico
Assets\icon.ico
Debug;Release;TEST
- 2.12
- 2.12
+ 2.13
+ 2.13
diff --git a/SPTInstaller/ViewModels/MessageViewModel.cs b/SPTInstaller/ViewModels/MessageViewModel.cs
index 9d1b813..94f1acb 100644
--- a/SPTInstaller/ViewModels/MessageViewModel.cs
+++ b/SPTInstaller/ViewModels/MessageViewModel.cs
@@ -54,7 +54,7 @@ public class MessageViewModel : ViewModelBase
}
});
- public MessageViewModel(IScreen Host, IResult result, bool showCloseButton = true) : base(Host)
+ public MessageViewModel(IScreen Host, IResult result, bool showCloseButton = true, bool noLog = false) : base(Host)
{
ShowCloseButton = showCloseButton;
Message = result.Message;
@@ -75,6 +75,8 @@ public class MessageViewModel : ViewModelBase
}
HasErrors = true;
- Log.Error(Message);
+
+ if (!noLog)
+ Log.Error(Message);
}
}
\ No newline at end of file
diff --git a/SPTInstaller/ViewModels/PreChecksViewModel.cs b/SPTInstaller/ViewModels/PreChecksViewModel.cs
index e0ff8ca..13aa088 100644
--- a/SPTInstaller/ViewModels/PreChecksViewModel.cs
+++ b/SPTInstaller/ViewModels/PreChecksViewModel.cs
@@ -2,6 +2,7 @@
using System.Reflection;
using System.Threading.Tasks;
using System.Windows.Input;
+using Avalonia.Controls;
using Avalonia.Threading;
using DialogHostAvalonia;
using ReactiveUI;
@@ -78,6 +79,7 @@ public class PreChecksViewModel : ViewModelBase
if (data.OriginalGamePath == null)
{
NavigateTo(new MessageViewModel(HostScreen, Result.FromError("Could not find EFT install.\n\nDo you own and have the game installed?")));
+ return;
}
#endif
@@ -86,6 +88,26 @@ public class PreChecksViewModel : ViewModelBase
Log.Information($"Install Path: {FileHelper.GetRedactedPath(InstallPath)}");
+ if (data.OriginalGamePath == data.TargetInstallPath)
+ {
+ Log.CloseAndFlush();
+
+ var logFiles = Directory.GetFiles(InstallPath, "spt-aki-installer_*.log");
+
+ // remove log file from original game path if they exist
+ foreach (var file in logFiles)
+ {
+ try
+ {
+ File.Delete(file);
+ }
+ catch { }
+ }
+
+ NavigateTo(new MessageViewModel(HostScreen, Result.FromError("Installer is located in EFT's original directory. Please move the installer to a seperate folder as per the guide"), noLog: true));
+ return;
+ }
+
Task.Run(async () =>
{
if (FileHelper.CheckPathForProblemLocations(InstallPath))