From 33d2cfbfed3a90e0405abcef798dde4a300a39fb Mon Sep 17 00:00:00 2001 From: "Gabriel T. Nardy" Date: Sat, 12 Jun 2021 12:00:41 -0300 Subject: [PATCH] Fixed some typos and minor bugs --- Client/Index.lua | 5 ++++- Client/UI/index.js | 10 +++++----- Package.toml | 2 +- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/Client/Index.lua b/Client/Index.lua index ba57677..90b6f5a 100644 --- a/Client/Index.lua +++ b/Client/Index.lua @@ -65,7 +65,10 @@ end) -- When package loads, verify if LocalPlayer already exists (eg. when reloading the package), then try to get and store it's controlled character Package:Subscribe("Load", function() - Events:CallRemote("PlayerReady", {}) + Timer:SetTimeout(200, function() + Events:CallRemote("PlayerReady", {}) + return false + end) if (NanosWorld:GetLocalPlayer() ~= nil) then UpdateLocalCharacter(NanosWorld:GetLocalPlayer():GetControlledCharacter()) diff --git a/Client/UI/index.js b/Client/UI/index.js index 6abd2e0..bfba085 100644 --- a/Client/UI/index.js +++ b/Client/UI/index.js @@ -96,22 +96,22 @@ function SortScoreboard() { } // Fix the scoreboard at the top of the screen with the sorted data - for (let i = 0,; i < 10; i++) { + for (let i = 0; i < 10; i++) { let name = ""; let score = ""; if (i < store.length) { - name = store[i][1].cells[1]; - score = store[i][1].cells[2]; + name = store[i][1].cells[1].innerText; + score = store[i][1].cells[2].innerText; } const rank_entry = document.getElementById(`scoreboard_rank_entry_${i}`); const rank_entry_image = rank_entry.querySelector(".scoreboard_rank_image"); - rank_entry_image.innerHTML = name.innerText.substring(0, 3).toUpperCase(); + rank_entry_image.innerHTML = name.substring(0, 3).toUpperCase(); const rank_entry_score = rank_entry.querySelector(".scoreboard_rank_score"); - rank_entry_score.innerHTML = score.innerText; + rank_entry_score.innerHTML = score; } } diff --git a/Package.toml b/Package.toml index 88fb238..272485c 100644 --- a/Package.toml +++ b/Package.toml @@ -5,7 +5,7 @@ # Contributors author = "nanos™" # Version - version = "1.0.1" + version = "1.0.2" # Image URL image = "https://i.imgur.com/vW4rOb3.jpg" # Package Type: 'executable' (normal package) | 'library' (doesn't run - useful for code library)