aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/app/index.html1
-rw-r--r--src/app/js/mods.js13
-rw-r--r--src/app/main.js1
3 files changed, 12 insertions, 3 deletions
diff --git a/src/app/index.html b/src/app/index.html
index 1297d0a..4b89999 100644
--- a/src/app/index.html
+++ b/src/app/index.html
@@ -333,7 +333,6 @@
</div>
<script src="main.js"></script>
- <script src="js/mods.js"></script>
<script src="js/toast.js"></script>
<script src="js/popups.js"></script>
<script src="js/tooltip.js"></script>
diff --git a/src/app/js/mods.js b/src/app/js/mods.js
index e105c7c..caa66a7 100644
--- a/src/app/js/mods.js
+++ b/src/app/js/mods.js
@@ -1,3 +1,10 @@
+const ipcRenderer = require("electron").ipcRenderer;
+
+const lang = require("../../lang");
+
+const version = require("./version");
+const set_buttons = require("./set_buttons");
+
let mods = {};
let mods_list = {
@@ -15,7 +22,7 @@ mods.load = (mods_obj) => {
modcount.innerHTML = `${lang("gui.mods.count")} ${mods_obj.all.length}`;
let normalized_names = [];
-
+
let set_mod = (mod) => {
let name = mod.name;
if (mod.package) {
@@ -185,7 +192,7 @@ mods.load = (mods_obj) => {
mods.toggle(mod_versions[mod].local_name);
}
})
-
+
mod_els[i].remove();
modsdiv.querySelector(".line").after(mod_el);
} else {
@@ -303,3 +310,5 @@ ipcRenderer.on("mods", (event, mods_obj) => {
mods.load(mods_obj);
})
+
+module.exports = mods;
diff --git a/src/app/main.js b/src/app/main.js
index 11f5853..fa4ec86 100644
--- a/src/app/main.js
+++ b/src/app/main.js
@@ -27,6 +27,7 @@ ipcRenderer.on("unknown-error", (event, err) => {
const json = require("../modules/json");
const kill = require("./js/kill");
+const mods = require("./js/mods");
const update = require("./js/update");
const events = require("./js/events");
const launch = require("./js/launch");