Fix crafted sp (or any maxroll sp) override bug... spaghetti codes...

This commit is contained in:
b 2021-07-06 20:36:12 -07:00
parent 2032632021
commit 1bda93c08e
2 changed files with 5 additions and 2 deletions

View file

@ -484,7 +484,7 @@ class Build{
*/ */
initBuildStats(){ initBuildStats(){
let staticIDs = ["hp", "eDef", "tDef", "wDef", "fDef", "aDef"]; let staticIDs = ["hp", "eDef", "tDef", "wDef", "fDef", "aDef", "str", "dex", "int", "def", "agi"];
//Create a map of this build's stats //Create a map of this build's stats
let statMap = new Map(); let statMap = new Map();
@ -497,6 +497,9 @@ class Build{
let major_ids = new Set(); let major_ids = new Set();
for (const item of this.items){ for (const item of this.items){
for (let [id, value] of item.get("maxRolls")) { for (let [id, value] of item.get("maxRolls")) {
if (staticIDs.includes(id)) {
continue;
}
statMap.set(id,(statMap.get(id) || 0)+value); statMap.set(id,(statMap.get(id) || 0)+value);
} }
for (const staticID of staticIDs) { for (const staticID of staticIDs) {

View file

@ -3,7 +3,7 @@ const url_tag = location.hash.slice(1);
// console.log(url_tag); // console.log(url_tag);
const BUILD_VERSION = "7.0.15"; const BUILD_VERSION = "7.0.16";
function setTitle() { function setTitle() {
let text; let text;