From d15fd272ca69f140ac92b14a9c7cf35fb821a1aa Mon Sep 17 00:00:00 2001 From: biglyderv Date: Tue, 11 Mar 2025 06:29:48 -0400 Subject: [PATCH] slight UI changes --- docs/js/idle.js | 3 +++ docs/js/index.js | 3 --- docs/js/upgrade.js | 10 +++++----- docs/main.css | 5 ++++- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/docs/js/idle.js b/docs/js/idle.js index 91628ea..d103400 100644 --- a/docs/js/idle.js +++ b/docs/js/idle.js @@ -1,3 +1,4 @@ +let hud = document.querySelector('.main-hud'); var nothingness = (window.localStorage.getItem('nothings') || 1) * 1, nGain = 0.003; var getBonus = 0; @@ -42,6 +43,8 @@ setInterval(function () { nGain = 0.003 + 0.003 * cubePos.length; getBonus *= 0.93; + hud.textContent = `${numify(nothingness)} nil; ${numify((nGain + getBonus) * 60)} nil/sec` + for (let ab in cubePos) { let a = cubePos[ab]; let bonus = 1 + counts.doNothing / (ab* .02 + 2); diff --git a/docs/js/index.js b/docs/js/index.js index 7191562..776f5c9 100644 --- a/docs/js/index.js +++ b/docs/js/index.js @@ -113,8 +113,6 @@ function renderThing() { gl.uniformMatrix4fv(matBuffer, false, new Float32Array(MDN.perspectiveMatrix(Math.PI * 100 / 180, ratio, 0.01, 1000))); - hud.textContent = `${numify(nothingness)} nil; ${numify((nGain + getBonus) * 60)} nil/sec` - gl.uniform1f(sizeBuffer, -Math.log(nothingness)); let am = (nGain + getBonus) / (nGain + getBonus + nothingness); @@ -154,7 +152,6 @@ function renderThing() { requestAnimationFrame(renderThing); } -let hud = document.querySelector('.main-hud'); main(); requestAnimationFrame(renderThing) \ No newline at end of file diff --git a/docs/js/upgrade.js b/docs/js/upgrade.js index 23168de..038c4a7 100644 --- a/docs/js/upgrade.js +++ b/docs/js/upgrade.js @@ -15,19 +15,19 @@ exec.addCube = function () { } upgrades = [ { - 'name': 'Set', + 'name': 'Void Set', 'price': 30, 'exec': 'addCube', 'desc': 'Clicks and waiting generate more nil' }, { - 'name': 'Union', + 'name': 'Void-Void Union', 'price': 1000, 'exec': 'doNothing', - 'desc': 'Earlier-bought Sets are more powerful' + 'desc': 'Earlier-bought Sets pool together' }, { - 'name': 'Intersection', + 'name': 'Void-Input Intersection', 'price': 1000, 'exec': 'intersectThings', 'desc': 'Sets become easier to click' @@ -37,7 +37,7 @@ upgrades = [ let hud2 = document.querySelector('.hud'); function updateText(button, price, name, cc) { - button.textContent = `Buy ${name} (${cc}x) for ${numify(price)} nil` + button.textContent = `${name}\n${cc}x inventory\n${numify(price)} nil to construct` } for (let upgrade of upgrades) { diff --git a/docs/main.css b/docs/main.css index 625116f..38e9e80 100644 --- a/docs/main.css +++ b/docs/main.css @@ -44,8 +44,11 @@ html { margin-top: 5px; } -.desc { +.item, .desc { white-space: pre-wrap; +} + +.desc { font-size: 0.5em; background: rgb(204, 191, 209);