aboutsummaryrefslogtreecommitdiff
path: root/src/utils.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils.js')
-rw-r--r--src/utils.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/utils.js b/src/utils.js
index 85db119..872320e 100644
--- a/src/utils.js
+++ b/src/utils.js
@@ -42,6 +42,11 @@ function setpath(win) {
ipcMain.emit("newpath", null, false);
return;
}
+ if (! fs.existsSync(path.join(res.filePaths[0], "Titanfall2.exe"))) {
+ ipcMain.emit("wrongpath");
+ return;
+ }
+
settings.gamepath = res.filePaths[0];
settings.zip = path.join(settings.gamepath + "/northstar.zip");
saveSettings();