Enlarge spell projectile placeholders to 16×16.
Keeps the centred magenta diamond; extra margin for tip/tail art. Right side remains the facing direction.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
The contents of this binary file are not shown.
@@ -3,6 +3,9 @@
* Magenta placeholder projectile art: one PNG per spell under
* client/assets/fx/projectile/spell-<spellId>.png
*
* Canvas is 16×16. Facing: the RIGHT side (+X) is the front/tip — the same
* convention as arrow.png. Runtime rotates with atan2(dy, dx) so 0° = flying east.
*
* Magenta (R≈B, G < R) is recolored at runtime via spellProjectileTint(element).
* Replace any file with hand-drawn art; keep magenta for tintable regions.
*
@@ -14,7 +17,10 @@ import { fileURLToPath } from "node:url";
import { writeRgbaPng, makeRgba, fillRect } from "../../server/src/assets/placeholderPng.js";
import { SPELL_DEFINITIONS } from "../../shared/definitions/spells.js";
const SIZE = 8;
const SIZE = 16;
/** Offset so the original 8×8 diamond sits centred on the 16×16 canvas. */
const OX = 4;
const OY = 4;
const OUT_DIR = join(dirname(fileURLToPath(import.meta.url)), "..", "assets", "fx", "projectile");
/** Pure magenta mask + a lighter magenta highlight (G channel → white at runtime). */
@@ -44,16 +50,16 @@ for (const def of Object.values(SPELL_DEFINITIONS))
{
const file = join(OUT_DIR, `spell-${def.spellId}.png`);
const image = makeRgba(SIZE, SIZE, [0, 0, 0, 0]);
// Diamond body
fillRect(image, 3, 1, 2, 1, MAGENTA);
fillRect(image, 2, 2, 4, 1, MAGENTA);
fillRect(image, 1, 3, 6, 2, MAGENTA);
fillRect(image, 2, 5, 4, 1, MAGENTA);
fillRect(image, 3, 6, 2, 1, MAGENTA);
// Diamond body (same pixels as the old 8×8 art, centred)
fillRect(image, OX + 3, OY + 1, 2, 1, MAGENTA);
fillRect(image, OX + 2, OY + 2, 4, 1, MAGENTA);
fillRect(image, OX + 1, OY + 3, 6, 2, MAGENTA);
fillRect(image, OX + 2, OY + 5, 4, 1, MAGENTA);
fillRect(image, OX + 3, OY + 6, 2, 1, MAGENTA);
// Center highlight
fillRect(image, 3, 3, 2, 2, MAGENTA_HI);
fillRect(image, OX + 3, OY + 3, 2, 2, MAGENTA_HI);
writeRgbaPng(file, SIZE, SIZE, image.pixels);
wrote += 1;
}
console.log(`Wrote ${wrote} magenta spell projectile placeholders in ${OUT_DIR}`);
console.log(`Wrote ${wrote} magenta spell projectile placeholders (${SIZE}×${SIZE}) in ${OUT_DIR}`);
@@ -3,6 +3,9 @@ * Magenta placeholder projectile art: one PNG per spell under * Magenta placeholder projectile art: one PNG per spell under * client/assets/fx/projectile/spell-<spellId>.png * client/assets/fx/projectile/spell-<spellId>.png * * * Canvas is 16×16. Facing: the RIGHT side (+X) is the front/tip — the same * convention as arrow.png. Runtime rotates with atan2(dy, dx) so 0° = flying east. * * Magenta (R≈B, G < R) is recolored at runtime via spellProjectileTint(element). * Magenta (R≈B, G < R) is recolored at runtime via spellProjectileTint(element). * Replace any file with hand-drawn art; keep magenta for tintable regions. * Replace any file with hand-drawn art; keep magenta for tintable regions. * *@@ -14,7 +17,10 @@ import { fileURLToPath } from "node:url";import { writeRgbaPng, makeRgba, fillRect } from "../../server/src/assets/placeholderPng.js";import { writeRgbaPng, makeRgba, fillRect } from "../../server/src/assets/placeholderPng.js";import { SPELL_DEFINITIONS } from "../../shared/definitions/spells.js";import { SPELL_DEFINITIONS } from "../../shared/definitions/spells.js";const SIZE = 8;const SIZE = 16;/** Offset so the original 8×8 diamond sits centred on the 16×16 canvas. */const OX = 4;const OY = 4;const OUT_DIR = join(dirname(fileURLToPath(import.meta.url)), "..", "assets", "fx", "projectile");const OUT_DIR = join(dirname(fileURLToPath(import.meta.url)), "..", "assets", "fx", "projectile");/** Pure magenta mask + a lighter magenta highlight (G channel → white at runtime). *//** Pure magenta mask + a lighter magenta highlight (G channel → white at runtime). */@@ -44,16 +50,16 @@ for (const def of Object.values(SPELL_DEFINITIONS)){{ const file = join(OUT_DIR, `spell-${def.spellId}.png`); const file = join(OUT_DIR, `spell-${def.spellId}.png`); const image = makeRgba(SIZE, SIZE, [0, 0, 0, 0]); const image = makeRgba(SIZE, SIZE, [0, 0, 0, 0]); // Diamond body // Diamond body (same pixels as the old 8×8 art, centred) fillRect(image, 3, 1, 2, 1, MAGENTA); fillRect(image, OX + 3, OY + 1, 2, 1, MAGENTA); fillRect(image, 2, 2, 4, 1, MAGENTA); fillRect(image, OX + 2, OY + 2, 4, 1, MAGENTA); fillRect(image, 1, 3, 6, 2, MAGENTA); fillRect(image, OX + 1, OY + 3, 6, 2, MAGENTA); fillRect(image, 2, 5, 4, 1, MAGENTA); fillRect(image, OX + 2, OY + 5, 4, 1, MAGENTA); fillRect(image, 3, 6, 2, 1, MAGENTA); fillRect(image, OX + 3, OY + 6, 2, 1, MAGENTA); // Center highlight // Center highlight fillRect(image, 3, 3, 2, 2, MAGENTA_HI); fillRect(image, OX + 3, OY + 3, 2, 2, MAGENTA_HI); writeRgbaPng(file, SIZE, SIZE, image.pixels); writeRgbaPng(file, SIZE, SIZE, image.pixels); wrote += 1; wrote += 1;}}console.log(`Wrote ${wrote} magenta spell projectile placeholders in ${OUT_DIR}`);console.log(`Wrote ${wrote} magenta spell projectile placeholders (${SIZE}×${SIZE}) in ${OUT_DIR}`);