From 14852cc431c0c7876feb233ca1f3c402f6440f69 Mon Sep 17 00:00:00 2001 From: b Date: Thu, 7 Jan 2021 04:30:23 -0600 Subject: [PATCH] Change pipe to underscore character --- index.html | 2 +- test.js | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/index.html b/index.html index 400d66e..a080562 100644 --- a/index.html +++ b/index.html @@ -7,7 +7,7 @@ Wynn Clientside -
+
diff --git a/test.js b/test.js index 2ab2191..b8e6822 100644 --- a/test.js +++ b/test.js @@ -11,6 +11,10 @@ console.log(url_tag); * END testing section */ +const BUILD_VERSION = "1.0"; + +document.getElementById("header").textContent = "Wynn build calculator "+BUILD_VERSION+" (db version "+DB_VERSION+")"; + let player_build; // Set up item lists for quick access later. let armorTypes = [ "helmet", "chestplate", "leggings", "boots" ]; @@ -149,7 +153,7 @@ function populateFromURL() { let bracelet; let necklace; let weapon; - let info = url_tag.split("|"); + let info = url_tag.split("_"); let version = info[0]; if (version === "0") { let equipments = info[1]; @@ -189,7 +193,7 @@ function populateFromURL() { function encodeBuild() { if (player_build) { - let build_string = "0|" + Base64.fromIntN(player_build.helmet.id, 3) + + let build_string = "0_" + Base64.fromIntN(player_build.helmet.id, 3) + Base64.fromIntN(player_build.chestplate.id, 3) + Base64.fromIntN(player_build.leggings.id, 3) + Base64.fromIntN(player_build.boots.id, 3) + @@ -309,7 +313,7 @@ function expandItem(item){ } } }else{ //The item does not have fixed IDs. - for (const id in rolledIDs){ + for (const id in rolledID-){ console.log(id); if(item[rolledIDs[id]]){ if(item[rolledIDs[id]] > 0){ // positive rolled IDs