Skip to content

Commit 7a05de5

Browse files
committed
bump to 1.1.4 : v1 killswitch
1 parent e351d05 commit 7a05de5

File tree

3 files changed

+54
-37
lines changed

3 files changed

+54
-37
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@arenareturns/launcher",
33
"productName": "Arena Returns Launcher",
4-
"version": "1.1.3",
4+
"version": "1.1.4",
55
"description": "Le launcher officiel d'Arena Returns",
66
"main": ".webpack/main",
77
"scripts": {

src/index.ts

+52-35
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { app, BrowserWindow } from "electron";
1+
import { app, BrowserWindow, dialog, shell } from "electron";
22
import { CdnService } from "./main/cdnService";
33
import { IPC } from "./main/ipc";
44
// This allows TypeScript to pick up the magic constants that's auto-generated by Forge's Webpack
@@ -14,56 +14,74 @@ if (require("electron-squirrel-startup")) {
1414
}
1515

1616
// Automatic updates
17-
require("update-electron-app")();
17+
// require("update-electron-app")();
1818

1919
export let mainWindow: BrowserWindow;
2020

2121
const createWindow = async () => {
22-
await CdnService.loadManifest();
22+
// await CdnService.loadManifest();
2323

24-
// Create the browser window.
25-
mainWindow = new BrowserWindow({
26-
minWidth: 1024,
27-
minHeight: 576,
28-
width: 1024,
29-
height: 576,
30-
maxWidth: 1366,
31-
maxHeight: 768,
32-
maximizable: false,
33-
fullscreenable: false,
34-
icon: "assets/icon/icon.png",
35-
webPreferences: {
36-
nodeIntegration: false,
37-
contextIsolation: true,
38-
preload: MAIN_WINDOW_PRELOAD_WEBPACK_ENTRY,
39-
devTools: process.env.NODE_ENV === "development",
40-
},
41-
frame: false,
42-
titleBarStyle: "hidden",
43-
backgroundColor: "#3B180E",
44-
show: false,
24+
const response = await dialog.showMessageBox({
25+
type: "error",
26+
buttons: ["Discord", "Site web"],
27+
title: "Information importante !",
28+
message:
29+
"Cette version du launcher est dépréciée.\nVous utilisiez une version Alpha du launcher, nous vous invitons à la désinstaller !\nUne version stable du launcher est disponible sur arena-returns.com\n\nPour plus d'informations, rejoignez nous sur Discord.",
4530
});
4631

47-
if (process.platform === "linux") {
48-
console.log("Linux system detected. Disabling resizing as it causes issues with Gnome.");
49-
mainWindow.setResizable(false);
32+
if (response) {
33+
if (response.response === 0) {
34+
shell.openExternal("https://discord.gg/arenareturns");
35+
} else if (response.response === 1) {
36+
shell.openExternal("https://arena-returns.com");
37+
}
5038
}
5139

52-
mainWindow.setAspectRatio(16 / 9);
40+
app.quit();
41+
42+
// Create the browser window.
43+
// mainWindow = new BrowserWindow({
44+
// minWidth: 1024,
45+
// minHeight: 576,
46+
// width: 1024,
47+
// height: 576,
48+
// maxWidth: 1366,
49+
// maxHeight: 768,
50+
// maximizable: false,
51+
// fullscreenable: false,
52+
// icon: "assets/icon/icon.png",
53+
// webPreferences: {
54+
// nodeIntegration: false,
55+
// contextIsolation: true,
56+
// preload: MAIN_WINDOW_PRELOAD_WEBPACK_ENTRY,
57+
// devTools: process.env.NODE_ENV === "development",
58+
// },
59+
// frame: false,
60+
// titleBarStyle: "hidden",
61+
// backgroundColor: "#3B180E",
62+
// show: false,
63+
// });
64+
65+
// if (process.platform === "linux") {
66+
// console.log("Linux system detected. Disabling resizing as it causes issues with Gnome.");
67+
// mainWindow.setResizable(false);
68+
// }
69+
70+
// mainWindow.setAspectRatio(16 / 9);
5371

5472
// and load the index.html of the app.
55-
mainWindow.loadURL(MAIN_WINDOW_WEBPACK_ENTRY);
73+
// mainWindow.loadURL(MAIN_WINDOW_WEBPACK_ENTRY);
5674

5775
// Prevent the white screen while loading the front-end
58-
mainWindow.once("ready-to-show", () => {
59-
mainWindow.show();
60-
});
76+
// mainWindow.once("ready-to-show", () => {
77+
// mainWindow.show();
78+
// });
6179

6280
// Open the DevTools.
6381
//mainWindow.webContents.openDevTools();
6482

65-
IPC.registerEvents(mainWindow);
66-
IPC.registerHandlers(mainWindow);
83+
// IPC.registerEvents(mainWindow);
84+
//IPC.registerHandlers(mainWindow);
6785
};
6886

6987
// Prevent multiple launchers from being opened at the same time
@@ -80,4 +98,3 @@ if (!app.requestSingleInstanceLock()) {
8098
// initialization and is ready to create browser windows.
8199
// Some APIs can only be used after this event occurs.
82100
app.on("ready", createWindow);
83-

src/main/constants.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { app } from "electron";
22
import path from "path";
33

44
export class Constants {
5-
public static readonly CURRENT_LAUNCHER_VERSION = "1.1.2";
5+
public static readonly CURRENT_LAUNCHER_VERSION = "1.1.4";
66
public static readonly CDN_URL = "https://launcher.arena-returns.com";
77
public static readonly GAME_PATH = path.join(app.getPath("appData"), "Arena Returns Client");
88
}

0 commit comments

Comments
 (0)