mirror of
https://github.com/smogon/sprites.git
synced 2026-07-11 15:26:20 -05:00
Allow gaps in sheets
This commit is contained in:
parent
e5040be858
commit
ea2b48e77f
|
|
@ -13,6 +13,15 @@ if (!sheetjs || !dest) {
|
|||
(async() => {
|
||||
const {default: sheet} = await import(path.join(process.cwd(), sheetjs));
|
||||
|
||||
for (let i = 0; i < sheet.entries.length; i++) {
|
||||
if (sheet.entries[i] === undefined)
|
||||
throw new Error(`gap: ${i}`);
|
||||
if (sheet.entries[i] === null) {
|
||||
// ImageMagick blank entry
|
||||
sheet.entries[i] = "xc:transparent";
|
||||
}
|
||||
}
|
||||
|
||||
cp.execFileSync("montage", [
|
||||
...sheet.entries,
|
||||
"-background", "transparent",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user