Build for caps

This commit is contained in:
Christopher Monsanto
2023-06-15 00:57:06 -04:00
parent e083002e27
commit da89396842
2 changed files with 26 additions and 0 deletions

View File

@@ -55,6 +55,19 @@ foreach_rule(
"build/gen9-modelslike/%B.gif"
)
-- Gen 5 CAPs...
foreach_rule(
"src/sprites/gen5/*.png",
{
-- TODO, add customizable compression for gif
-- ... or investigate using webp instead of both png/gif here
"magick convert %f %o",
"gifsicle -O3 -b %o"
},
"build/gen5-gif/%B.gif"
)
-- PS spritesheet
rule(

View File

@@ -66,7 +66,10 @@ function newspritecopy(f, {dir, ext}) {
}
}
let seenModels = new Set;
for (const f of list("src/models")) {
seenModels.add(f.name);
spritecopy(f, {dir: "xy"});
}
@@ -74,6 +77,16 @@ for (const f of list("build/gen9-modelslike")) {
spritecopy(f, {dir: "xy"});
}
// Non-model CAPs
for (const f of list("src/sprites/gen5")) {
if (f.ext !== 'gif' || seenModels.has(f.name)) continue;
spritecopy(f, {dir: "xy"});
}
for (const f of list("build/gen5-gif")) {
spritecopy(f, {dir: "xy"});
}
for (const f of list("build/gen6-minisprites-trimmed")) {
spritecopy(f, {dir: "xyicons"});
}