diff --git a/assets/js/serverselector.js b/assets/js/serverselector.js index 0c38438..e05c75a 100644 --- a/assets/js/serverselector.js +++ b/assets/js/serverselector.js @@ -26,20 +26,20 @@ function disableServerListButtons() { } function getAppVersion() { - appversion = remote.require("app").getVersion(); - - // simplify version, ex. 1.4.0 -> 1.4, - // but only if a revision number isn't present - if(appversion.endsWith(".0")){ - return appversion.substr(0, appversion.length - 2) - } else { - return appversion - } + appversion = remote.require("app").getVersion(); + + // simplify version, ex. 1.4.0 -> 1.4, + // but only if a revision number isn't present + if (appversion.endsWith(".0")) { + return appversion.substr(0, appversion.length - 2); + } else { + return appversion; + } } function setAppVersionText() { - $("#of-aboutversionnumber").text("Version " + getAppVersion()); - $("#of-versionnumber").text("v" + getAppVersion()); + $("#of-aboutversionnumber").text("Version " + getAppVersion()); + $("#of-versionnumber").text("v" + getAppVersion()); } function addServer() { diff --git a/build/afterpack.js b/build/afterpack.js index b142d88..915f15c 100644 --- a/build/afterpack.js +++ b/build/afterpack.js @@ -4,7 +4,7 @@ const exefile = './dist/win-ia32-unpacked/OpenFusionClient.exe' exports.default = function() { // remove leftover files from default electron app - fs.rm(dir, { recursive: true }, (err) => { + fs.rm(defaultdir, { recursive: true }, (err) => { if (err) { throw err; } diff --git a/index.html b/index.html index 53c771f..7fb39a5 100644 --- a/index.html +++ b/index.html @@ -151,7 +151,12 @@
APP_VERSION_NUMBER
++ APP_VERSION_NUMBER +
©2020-2023 OpenFusion Contributors
OpenFusion
is licensed under MIT.
diff --git a/index.js b/index.js
index 3715fc2..9cd98f1 100644
--- a/index.js
+++ b/index.js
@@ -43,10 +43,8 @@ function installUnity(callback) {
child.on("exit", function () {
// overwrite 3.5.2 loader/player with FF's custom version
var dstfolder =
- app.getPath("appData") + "..\\LocalLow\\Unity\\WebPlayer";
- fs.copySync(utilsdir + "\\WebPlayer", dstfolder, {
- clobber: true,
- });
+ app.getPath("appData") + "\\..\\LocalLow\\Unity\\WebPlayer";
+ fs.copySync(utilsdir + "\\WebPlayer", dstfolder, { clobber: true });
// avoids error reporter popping up when closing Electron
fs.removeSync(dstfolder + "\\UnityBugReporter.exe");
console.log("Unity Web Player installed successfully.");