Update card ID format and include in download data
This commit is contained in:
parent
f826e27523
commit
8cf3344bfe
1 changed files with 5 additions and 3 deletions
|
@ -189,7 +189,7 @@ function drawCard() {
|
|||
async function drawCardId() {
|
||||
const id = await generateCardId(packInput.value, nameInput.value, powerInput.value, charmInput.value, witInput.value, artistInput.value);
|
||||
ctx.font = "15px sans-serif";
|
||||
ctx.fillText("KC-" + id, canvas.width/2, canvas.height - 30);
|
||||
ctx.fillText("Kemoverse - " + id, canvas.width/2, canvas.height - 30);
|
||||
}
|
||||
|
||||
|
||||
|
@ -245,7 +245,8 @@ jsonBtn.onclick = () => {
|
|||
wit: witInput.value,
|
||||
flavor: flavorInput.value,
|
||||
artist: artistInput.value,
|
||||
frame: frameSelect.value
|
||||
frame: frameSelect.value,
|
||||
id: generateCardId(packInput.value, nameInput.value, powerInput.value, charmInput.value, witInput.value, artistInput.value)
|
||||
};
|
||||
const safeName = (nameInput.value || "card").replace(/[^a-z0-9_\-]/gi, "_");
|
||||
const safePack = (packInput.value || "pack").replace(/[^a-z0-9_\-]/gi, "_");
|
||||
|
@ -273,7 +274,8 @@ zipBtn.onclick = async () => {
|
|||
wit: witInput.value,
|
||||
flavor: flavorInput.value,
|
||||
artist: artistInput.value,
|
||||
frame: frameSelect.value
|
||||
frame: frameSelect.value,
|
||||
id: await generateCardId(packInput.value, nameInput.value, powerInput.value, charmInput.value, witInput.value, artistInput.value)
|
||||
};
|
||||
const safeName = (nameInput.value || "card").replace(/[^a-z0-9_\-]/gi, "_");
|
||||
const safePack = (packInput.value || "pack").replace(/[^a-z0-9_\-]/gi, "_");
|
||||
|
|
Loading…
Add table
Reference in a new issue