From c92606840ac9228b307f038c770ca34e3746f469 Mon Sep 17 00:00:00 2001 From: Lucas Scharenbroich Date: Sat, 20 Nov 2021 11:09:57 -0600 Subject: [PATCH] Fix mask generation bug; mask was reversed --- tools/png2iigs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/png2iigs.js b/tools/png2iigs.js index 5d22e9a..da93a4c 100644 --- a/tools/png2iigs.js +++ b/tools/png2iigs.js @@ -322,7 +322,7 @@ function buildTile(options, buff, _mask, width, x, y) { const mask3 = swap(_mask[offset + dy * width + 3]); const data = [hex3, hex2, hex1, hex0]; - const mask = [mask0, mask1, mask2, mask3]; // raw.map(h => toMask(h, options.transparentIndex)); + const mask = [mask3, mask2, mask1, mask0]; // raw.map(h => toMask(h, options.transparentIndex)); // const data = raw.map((h, i) => h & ~mask[i]); tile.flipped.data.push(data);