From 4948bcc200c935c77a4c647eb6f459298c271ed8 Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Fri, 12 Nov 2021 19:22:33 -0800
Subject: [PATCH 13/19] Update calculate.js
---
calculate.js | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/calculate.js b/calculate.js
index 0fe482d..1da7ba7 100644
--- a/calculate.js
+++ b/calculate.js
@@ -3,23 +3,20 @@ function getURL() {
document.getElementById("mainpage").style.display = "none";
var searches = window.location.search;
var poskey = searches.search("&key=");
- if (searches.slice(poskey) != "&key=") {
- getUser(searches.slice(5,poskey), searches.slice(poskey+5,));
- } else {
- getUser(searches.slice(5,poskey), "8688c07f-e1c2-4f47-ae37-01013664ce6f");
- }
+ getUser(searches.slice(5,poskey), searches.slice(poskey+5,));
} else {
- document.getElementById("main").innerHTML = "
";
+ document.getElementById("main").innerHTML = "
";
}
}
async function getUser(username, key) {
let uuidURL = 'https://api.ashcon.app/mojang/v2/user/' + username;
const uuidData = await fetch(uuidURL);
+
if (uuidData.ok == false) {
- console.log("Invalid Minecraft Username.");
- return 0;
- }
+ console.log("Invalid Minecraft Username.");
+ return 0;
+ }
const uuidjson = await uuidData.json();
let uuid = uuidjson.uuid;
uuid = uuid.replace(/-/g, '');
From bb996311a2a6584ce68fa8e5e92e2b1085f88388 Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Fri, 12 Nov 2021 19:26:27 -0800
Subject: [PATCH 14/19] Update calculate.js
---
calculate.js | 1 -
1 file changed, 1 deletion(-)
diff --git a/calculate.js b/calculate.js
index 1da7ba7..bce90f3 100644
--- a/calculate.js
+++ b/calculate.js
@@ -1,6 +1,5 @@
function getURL() {
if (window.location.search) {
- document.getElementById("mainpage").style.display = "none";
var searches = window.location.search;
var poskey = searches.search("&key=");
getUser(searches.slice(5,poskey), searches.slice(poskey+5,));
From 492a6563c46ae51b2e29ef451db0c0f73013bbcf Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Fri, 12 Nov 2021 19:27:39 -0800
Subject: [PATCH 15/19] Update calculate.js
---
calculate.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/calculate.js b/calculate.js
index bce90f3..bea76b3 100644
--- a/calculate.js
+++ b/calculate.js
@@ -4,7 +4,7 @@ function getURL() {
var poskey = searches.search("&key=");
getUser(searches.slice(5,poskey), searches.slice(poskey+5,));
} else {
- document.getElementById("main").innerHTML = "
";
+ document.getElementById("main").innerHTML = "
";
}
}
From 0eccea00d0aad76f51decaa455112ced8dc9f505 Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Sat, 13 Nov 2021 20:49:32 -0800
Subject: [PATCH 16/19] Update calculate.js
---
calculate.js | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/calculate.js b/calculate.js
index bea76b3..718d443 100644
--- a/calculate.js
+++ b/calculate.js
@@ -4,7 +4,7 @@ function getURL() {
var poskey = searches.search("&key=");
getUser(searches.slice(5,poskey), searches.slice(poskey+5,));
} else {
- document.getElementById("main").innerHTML = "
";
+ create_form();
}
}
@@ -220,3 +220,7 @@ function draw_slot(slot) {
return "";
}
}
+
+function create_form() {
+ document.getElementById("main").innerHTML = "
";
+}
From 6e3081b4a7815ff53911c9aa4f8dad8421849b95 Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Thu, 6 Jan 2022 00:03:08 -0800
Subject: [PATCH 17/19] Update calculate.js
---
calculate.js | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/calculate.js b/calculate.js
index 718d443..e281487 100644
--- a/calculate.js
+++ b/calculate.js
@@ -113,6 +113,7 @@ async function getStats(username, key, uuid, uuidjson, profilenum, profilejson)
let nbtinventory = profilejson.profiles[profilenum].members[uuid].inv_contents.data;
let json_inventory = convertNbtToJson(nbtinventory);
console.log(json_inventory);
+ document.getElementById('main').innerHTML = '
';
for (let i=0; i<36; i++) {
if (i < 9) {
let command = "write_slot(" + JSON.stringify(json_inventory[i]) + ")";
@@ -124,7 +125,11 @@ async function getStats(username, key, uuid, uuidjson, profilenum, profilejson)
document.getElementsByClassName("inventoryslot")[i-9].setAttribute("onmouseover", command);
document.getElementsByClassName("inventoryslot")[i-9].setAttribute("onmouseout", "document.getElementById('itemview').innerHTML = '';");
document.getElementsByClassName("inventoryslot")[i-9].innerHTML = draw_slot(json_inventory[i]);
- }
+ }
+ document.getElementById('inventoryview').innerHTML = document.getElementById('inventoryview').innerHTML + '
';
+ if (i == 26) {
+ document.getElementById('inventoryview').innerHTML = document.getElementById('inventoryview').innerHTML + '
';
+ }
}
}
From c17d3d246d4f23583da0bef4b2dc9e0baffd8cbd Mon Sep 17 00:00:00 2001
From: TheTrueShaman <68354378+The-Shaman@users.noreply.github.com>
Date: Thu, 6 Jan 2022 00:03:10 -0800
Subject: [PATCH 18/19] Update index.html
---
index.html | 42 ------------------------------------------
1 file changed, 42 deletions(-)
diff --git a/index.html b/index.html
index 87c18d6..af24172 100644
--- a/index.html
+++ b/index.html
@@ -99,47 +99,5 @@
Bad Skyblock Data Viewer
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-