From 06f59eeca86f2bf1a64a3d5e13d3d1e7e347a97b Mon Sep 17 00:00:00 2001 From: GGod Date: Tue, 29 Aug 2023 01:57:36 +0200 Subject: [PATCH] Update editTools.js --- mods/editTools.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/mods/editTools.js b/mods/editTools.js index 2c9af74c..83d57e5d 100644 --- a/mods/editTools.js +++ b/mods/editTools.js @@ -19,9 +19,12 @@ settingsManager.registerTab(settingsTab); runAfterLoadList.push(() => { // the game doesn't load without the setTimeout setTimeout(() => { - document.getElementById("elementButton-select").style.backgroundColor = "transparent"; - document.getElementById("elementButton-select").style.border = "2px dashed rgba(255, 255, 255, 0.75)"; - document.getElementById("elementButton-select").classList = ["elementButton"]; + // well apparently the game crashes anyway + try { + document.getElementById("elementButton-select").style.backgroundColor = "transparent"; + document.getElementById("elementButton-select").style.border = "2px dashed rgba(255, 255, 255, 0.75)"; + document.getElementById("elementButton-select").classList = ["elementButton"]; + } catch (_) {} }, 1) })