Add TARDIS (WHO) frame

This commit is contained in:
Josh birnholz
2023-07-21 14:12:24 -04:00
parent 8645b2deb4
commit 159ea0a0b2
35 changed files with 62 additions and 1 deletions

BIN
img/frames/tardis/a.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 707 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

BIN
img/frames/tardis/b.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 702 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

BIN
img/frames/tardis/g.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 709 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB

BIN
img/frames/tardis/m.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 726 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

BIN
img/frames/tardis/pt.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

BIN
img/frames/tardis/r.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 713 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB

BIN
img/frames/tardis/u.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 723 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB

BIN
img/frames/tardis/w.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 729 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.8 KiB

BIN
img/frames/ubold/r.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

View File

@@ -2676,6 +2676,7 @@ function writeText(textObject, targetContext) {
var textBounded = textObject.bounded || true;
var textOneLine = textObject.oneLine || false;
var textManaCost = textObject.manaCost || false;
var textAllCaps = textObject.allCaps || false;
var textManaSpacing = scaleWidth(textObject.manaSpacing) || 0;
//Buffers the canvases accordingly
var canvasMargin = 300;
@@ -2686,6 +2687,9 @@ function writeText(textObject, targetContext) {
//Preps the text string
var splitString = '6GJt7eL8';
var rawText = textObject.text
if (textAllCaps) {
rawText = rawText.toUpperCase();
}
if ((textObject.name == 'wizards' || textObject.name == 'copyright') && params.get('copyright') != null && (params.get('copyright') != '' || card.margins)) {
rawText = params.get('copyright'); //so people using CC for custom card games without WotC's IP can customize their copyright info
if (rawText == 'none') { rawText = ''; }
@@ -2704,7 +2708,7 @@ function writeText(textObject, targetContext) {
}
if (card.version == 'pokemon') {
rawText = rawText.replace(/{flavor}/g, '{oldflavor}{fontsize-20}{fontgillsansbolditalic}');
} else if (autoFramePack == 'Seventh' || autoFramePack == '8th' || card.version == 'invocation' || card.version == "storybook_mul") {
} else if (autoFramePack == 'Seventh' || autoFramePack == '8th' || card.version == 'invocation' || card.version == "storybook_mul" || card.version == 'tardis') {
rawText = rawText.replace(/{flavor}/g, '{oldflavor}');
}
rawText = rawText.replace(/ - /g, ' — ');

View File

@@ -31,6 +31,7 @@ const frameNames = new Map ([
['Colorshifted (Planar Chaos)', 'Colorshifted'],
['Brawl Legend Crowns', 'Brawl'],
//showcase
['TARDIS (WHO)', 'TARDIS'],
['Ring (LTR)', 'Ring'],
['Ixalan Coin (MOM)', 'IxalanCoin'],
['Ikoria Crystal (MOM)', 'Crystal'],

View File

@@ -1,5 +1,6 @@
loadFramePacks([
{name:'Set Showcase Frames (Chronological)', value:'disabled'},
{name:'TARDIS (WHO)', value:'TARDIS'},
{name:'Ring (LTR)', value:'Ring'},
{name:'Eldraine Storybooks (MOM)', value:'StorybookMUL'},
{name:'Ixalan Coin (MOM)', value:'IxalanCoin'},

55
js/frames/packTARDIS.js Normal file
View File

@@ -0,0 +1,55 @@
//Create objects for common properties across available frames
var masks = [];
var bounds = {x:115/1500, y:45/2100, width:1270/1500, height:450/2100};
//defines available frames
availableFrames = [
{name:'White Frame', src:'/img/frames/tardis/w.png', masks:masks},
{name:'Blue Frame', src:'/img/frames/tardis/u.png', masks:masks},
{name:'Black Frame', src:'/img/frames/tardis/b.png', masks:masks},
{name:'Red Frame', src:'/img/frames/tardis/r.png', masks:masks},
{name:'Green Frame', src:'/img/frames/tardis/g.png', masks:masks},
{name:'Multicolored Frame', src:'/img/frames/tardis/m.png', masks:masks},
{name:'Artifact Frame', src:'/img/frames/tardis/a.png', masks:masks},
{name:'Land Frame', src:'/img/frames/tardis/l.png', masks:masks},
{name:'Power/Toughness', src:'/img/frames/tardis/pt.png', bounds:{x:1133/1500, y:1850/2100, width:299/1500, height:173/2100}},
{name:'White Legendary Crown', src:'/img/frames/tardis/crowns/w.png', bounds:bounds},
{name:'Blue Legendary Crown', src:'/img/frames/tardis/crowns/u.png', bounds:bounds},
{name:'Black Legendary Crown', src:'/img/frames/tardis/crowns/b.png', bounds:bounds},
{name:'Red Legendary Crown', src:'/img/frames/tardis/crowns/r.png', bounds:bounds},
{name:'Green Legendary Crown', src:'/img/frames/tardis/crowns/g.png', bounds:bounds},
{name:'Multicolored Legendary Crown', src:'/img/frames/tardis/crowns/m.png', bounds:bounds},
{name:'Artifact Legendary Crown', src:'/img/frames/tardis/crowns/a.png', bounds:bounds},
{name:'Land Legendary Crown', src:'/img/frames/tardis/crowns/l.png', bounds:bounds}
];
//disables/enables the "Load Frame Version" button
document.querySelector('#loadFrameVersion').disabled = false;
//defines process for loading this version, if applicable
document.querySelector('#loadFrameVersion').onclick = async function() {
//resets things so that every frame doesn't have to
await resetCardIrregularities();
//sets card version
card.version = 'tardis';
//art bounds
card.artBounds = {x:115/1500, y:264/2100, width:1271/1500, height:898/2100};
autoFitArt();
//set symbol bounds
card.setSymbolBounds = {x:1337/1500, y:1241/2100, width:86/1500, height:86/2100, vertical:'center', horizontal: 'center'};
resetSetSymbol();
//watermark bounds
card.watermarkBounds = {x:0.5, y:0.7762, width:0.75, height:0.2305};
resetWatermark();
//text
loadTextOptions({
mana: {name:'Mana Cost', text:'', y:131/2100, width:1390/1500, height:71/2100, oneLine:true, size:71/1638, align:'right', manaCost:true, manaSpacing:0},
title: {name:'Title', text:'', x:0.0854, y:111/2100, width:0.8292, height:0.0543, oneLine:true, font:'belerenb', size:79/2100, font:'gillsans', color:'white', allCaps:true},
type: {name:'Type', text:'', x:0.0854, y:0.5664, width:1113/1500, height:0.0543, oneLine:true, font:'belerenb', size:0.0324, font:'gillsans', color:'white', allCaps:true},
rules: {name:'Rules Text', text:'', x:129/1500, y:1337/2100, width:1242/1500, height:578/2100, size:0.0362, color:'white'},
pt: {name:'Power/Toughness', text:'', x:1193/1500, y:1891/2100, width:195/1500, height:78/2100, size:0.0372, font:'belerenbsc', oneLine:true, align:'center', color:'white'}
});
}
//loads available frames
loadFramePack();
//Only for the main version as the webpage loads:
if (!card.text) {
document.querySelector('#loadFrameVersion').click();
}