final commit

This commit is contained in:
glazenbol
2026-06-28 12:44:07 +02:00
parent ff58292273
commit 7b61244940
3 changed files with 23 additions and 12 deletions
+7 -1
View File
@@ -6,6 +6,7 @@ const params = {
fps: 60,
zoom: 1, //in pixels per pixel
backgroundTicks: 60,
disableScreen: false,
textSpread: 0,
maxSpawns: 1,
textAlpha: 0.0,
@@ -17,6 +18,11 @@ socket.on("paramUpdate", ({ key, value }) => {
console.log(`Updated param ${key} to ${value}`);
});
let bgTick = 0;
socket.on("pulse", () => {
bgTick = 0;
});
const poem =
"everybody is pretty ugly \
lover \
@@ -119,7 +125,6 @@ const sketch = (p) => {
// const stream = c.elt.captureStream(60);
};
let bgTick = 0;
let textTick = 0;
let sx, sy;
let cw, ch;
@@ -186,6 +191,7 @@ const sketch = (p) => {
function drawTiles(x, y, width, height) {
// clear screen
p.background(p.color(1, 0, 0, 0));
if (params.disableScreen) return;
p.shader(shaderProgram);
// p.ortho(0, p.width, -p.height, 0);