diff --git a/sq2bs.js b/sq2bs.js index 47c641d..1daf968 100644 --- a/sq2bs.js +++ b/sq2bs.js @@ -133,7 +133,7 @@ function update_field(field) { // call calc build } - +/* tabulars */ let tabs = ['all-stats', 'minimal-offensive-stats', 'minimal-defensive-stats']; @@ -168,6 +168,19 @@ function collapse_element(eq) { document.querySelector("#"+eq+"-tooltip").style.display = ""; } +// disable boosts + +function reset_powder_specials() { + let specials = ["Quake", "Chain_Lightning", "Curse", "Courage", "Wind_Prison"] + for (const special of specials) { + for (i = 1; i < 6; i++) { + if (document.querySelector("#"+special+"-"+i).classList.contains("toggleOn")) { + document.querySelector("#"+special+"-"+i).classList.remove("toggleOn"); + } + } + } +} + // autocomplete initialize function init_autocomplete() { let dropdowns = new Map() diff --git a/sq2builder.js b/sq2builder.js index 1c3b8d7..fa34bfc 100644 --- a/sq2builder.js +++ b/sq2builder.js @@ -306,6 +306,7 @@ function calculateBuild(save_skp, skp){ if(player_build){ updateBoosts("skip", false); updatePowderSpecials("skip", false); + reset_powder_specials(); } let weaponName = getValue(equipmentInputs[8]); if (weaponName.startsWith("Morph-")) {