From 86c06010d44690305b75e31cbe3647b5e4d1bce9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BD=D1=82=D0=BE=D0=BD=20=D0=A2=D1=80=D0=BE=D1=88?= =?UTF-8?q?=D0=B8=D0=BD?= Date: Mon, 27 Jul 2026 01:35:24 +0300 Subject: [PATCH] fix: napalm destruction of terrain glitches sometimes --- src/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.js b/src/main.js index 3824e93..8ff38d7 100644 --- a/src/main.js +++ b/src/main.js @@ -965,7 +965,7 @@ function updateNapalm(dt) { const deadFireCells = fireCells.filter(f => f.timeLeft <= 0); fireCells = fireCells.filter(f => f.timeLeft > 0); for (let f of deadFireCells) { - clipTerrain(terrain, (ctx) => { ctx.fillStyle = '#000'; ctx.fillRect(f.x, f.y + 1, 1, 1); }); + clipTerrain(terrain, (ctx) => ctx.clearRect(f.x, f.y + 1, 1, 1)); for (let dx = -2; dx <= 2; dx++) { for (let dy = 0; dy <= 2; dy++) { if (dx === 0 && dy === 0) continue;