diff --git a/api/icon.js b/api/icon.js index b57744f..f9213d3 100644 --- a/api/icon.js +++ b/api/icon.js @@ -43,6 +43,7 @@ module.exports = async (app, req, res) => { let outline = req.query.glow || account[28] || "0"; let topless = form == "bird" && req.query.topless + let drawLegs = !(req.query.noLegs > 0) let autoSize = req.query.size == "auto" let sizeParam = autoSize || (req.query.size && !isNaN(req.query.size)) if (outline == "0" || outline == "false") outline = false; @@ -57,7 +58,7 @@ module.exports = async (app, req, res) => { glow = genImageName(isSpecial && '01', '2'); extra = genImageName(isSpecial && '01', 'extra'); } - const isSpecial = ['robot', 'spider'].includes(form); + let isSpecial = ['robot', 'spider'].includes(form); setBaseIcons(); if (!fs.existsSync(fromIcons(icon)) || (isSpecial && !fs.existsSync(fromIcons(genImageName('02'))))) { @@ -85,10 +86,9 @@ module.exports = async (app, req, res) => { let iconCode = `${req.query.form == "cursed" ? "cursed" : form}${topless ? "top" : ""}-${iconID}-${col1}-${col2}-${colG || "x"}-${colW || "x"}-${outline ? 1 : 0}` - if (!sizeParam && cache[iconCode]) return res.end(cache[iconCode].value) + if (!sizeParam && (!isSpecial || drawLegs) && cache[iconCode]) return res.end(cache[iconCode].value) let useExtra = false - let originalOffset = icons[icon].spriteOffset; let minusOrigOffset = function(x, y) { return x - originalOffset[y] } let offset = icons[glow].spriteOffset.map(minusOrigOffset); @@ -148,7 +148,7 @@ module.exports = async (app, req, res) => { if (!outline) ic.composite(await Jimp.read(ufoSprite), ufoCoords[0], ufoCoords[1], {mode: Jimp.BLEND_DESTINATION_OVER}) } - if (form == "robot" || req.query.form == "cursed") { + if (drawLegs && (form == "robot" || req.query.form == "cursed")) { ic.contain(iconSize[0], 300, Jimp.HORIZONTAL_ALIGN_CENTER | Jimp.VERTICAL_ALIGN_TOP) ic.contain(iconSize[0] + 200, 300, Jimp.HORIZONTAL_ALIGN_CENTER | Jimp.VERTICAL_ALIGN_TOP) @@ -203,7 +203,7 @@ module.exports = async (app, req, res) => { } - else if (form == "spider") { + else if (drawLegs && form == "spider") { let spiderBody; ic.contain(iconSize[0], 300, Jimp.HORIZONTAL_ALIGN_CENTER | Jimp.VERTICAL_ALIGN_TOP) @@ -297,7 +297,7 @@ module.exports = async (app, req, res) => { img.resize(imgSize, Jimp.AUTO) } img.getBuffer(Jimp.AUTO, (err, buffer) => { - if (!sizeParam) { + if (!sizeParam && drawLegs) { cache[iconCode] = { value: buffer, timeoutID: setTimeout(function() {delete cache[iconCode]}, 10000000) } // 3 hour cache if (usercode) cache[usercode] = { value: buffer, timeoutID: setTimeout(function() {delete cache[usercode]}, 300000) } // 5 min cache for player icons } diff --git a/api/leaderboards/accurate.js b/api/leaderboards/accurate.js index d405bb3..046b757 100644 --- a/api/leaderboards/accurate.js +++ b/api/leaderboards/accurate.js @@ -28,7 +28,7 @@ module.exports = async (app, req, res, post) => { let cell = tab.getCell(1, cellIndex).value if (cell.startsWith("GoogleSpreadsheetFormulaError")) return res.send("-1") - let leaderboard = JSON.parse(cell) + let leaderboard = JSON.parse(cell.replace(/~( |$)/g, "")) let gdFormatting = "" leaderboard.forEach(x => { diff --git a/assets/css/browser.css b/assets/css/browser.css index 9b0ac28..2fbdf00 100644 --- a/assets/css/browser.css +++ b/assets/css/browser.css @@ -720,6 +720,17 @@ input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { height: 25%; } +.weeklyStuff { + display: none; +} + +.ranking { + transform:scale(0.82) translate(-20.7vh, -20vh); + position: absolute; + height: 10%; + width: 12.5%; +} + #collectibles, .leaderboardStats { font-size: 4.3vh; white-space: nowrap; @@ -736,7 +747,7 @@ input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { .leaderboardStats img { transform: translate(-20%, -7%); - height: 22%; + width: 4.3%; } #boomling { diff --git a/assets/gdps/ausk_icon.png b/assets/gdps/ausk_icon.png new file mode 100644 index 0000000..8c59ab3 Binary files /dev/null and b/assets/gdps/ausk_icon.png differ diff --git a/assets/gdps/ausk_logo.png b/assets/gdps/ausk_logo.png new file mode 100644 index 0000000..fa4fa9e Binary files /dev/null and b/assets/gdps/ausk_logo.png differ diff --git a/assets/sort-week-on.png b/assets/sort-week-on.png new file mode 100644 index 0000000..641dad4 Binary files /dev/null and b/assets/sort-week-on.png differ diff --git a/assets/sort-week.png b/assets/sort-week.png new file mode 100644 index 0000000..4da087b Binary files /dev/null and b/assets/sort-week.png differ diff --git a/html/leaderboard.html b/html/leaderboard.html index ef1850c..e9d0eaf 100644 --- a/html/leaderboard.html +++ b/html/leaderboard.html @@ -1,7 +1,7 @@
Delete all saved online levels?