This commit is contained in:
Kyle
2019-05-13 17:29:07 -07:00
parent 37fc82ab86
commit c6fb9bbfb2
6 changed files with 26 additions and 46 deletions

View File

@@ -2,6 +2,6 @@
// M15 Border // // M15 Border //
//============================================// //============================================//
//Loads the colors //Loads the colors
loadColors("white-White,blue-Blue,black-Black,red-Red,green-Green,gold-Gold,artifact-Artifact,colorless-Colorless,vehicle-Vehicle,clear-Clear,whiteLand-White Land,blueLand-Blue Land,blackLand-Black Land,redLand-Red Land,greenLand-Green Land,goldLand-Gold Land,colorlessLand-Colorless Land") loadColors("white-White,blue-Blue,black-Black,red-Red,green-Green,gold-Gold,artifact-Artifact,colorless-Colorless,vehicle-Vehicle,whiteLand-White Land,blueLand-Blue Land,blackLand-Black Land,redLand-Red Land,greenLand-Green Land,goldLand-Gold Land,colorlessLand-Colorless Land")
//Finishes loading the border style //Finishes loading the border style
finishChangingBorder() finishChangingBorder()

View File

@@ -10,6 +10,7 @@ cardData.rulesBox = false
cardData.pinline = false cardData.pinline = false
cardData.titleTypeBoxes = false cardData.titleTypeBoxes = false
cardData.rareStamp = false cardData.rareStamp = false
cardData.transparency = true
//Specific Values //Specific Values
cardData.manaSymbolDirection = "none" cardData.manaSymbolDirection = "none"
cardData.titleAlignment = "center" cardData.titleAlignment = "center"
@@ -49,14 +50,7 @@ function bottomInfoPlanechase() {
var infoSet = document.getElementById("inputInfoSet").value var infoSet = document.getElementById("inputInfoSet").value
var infoLanguage = document.getElementById("inputInfoLanguage").value var infoLanguage = document.getElementById("inputInfoLanguage").value
var infoArtist = document.getElementById("inputInfoArtist").value var infoArtist = document.getElementById("inputInfoArtist").value
var infoCopyright = "CC \u2014 " + document.getElementById("inputInfoCopyright").value var infoCopyright = "\u2122 & \u00a9 " + date.getFullYear() + " Wizards of the Coast"
if (infoCopyright == "CC \u2014 secretcode") {
var date = new Date()
var year = date.getFullYear()
infoCopyright = "\u2122 & \u00a9 " + year + " Wizards of the Coast"
} else if (infoCopyright == "CC \u2014 ") {
infoCopyright = ""
}
var infoNumberSetLanguage = infoNumber + " " + infoSet + " \u00b7 " + infoLanguage + " " var infoNumberSetLanguage = infoNumber + " " + infoSet + " \u00b7 " + infoLanguage + " "
textContext.fillStyle = "white" textContext.fillStyle = "white"
textContext.font = cheight(15) + "px gothammedium" textContext.font = cheight(15) + "px gothammedium"

View File

@@ -1,5 +1,5 @@
//============================================// //============================================//
// Miniplane Border // // Plane Border //
//============================================// //============================================//
//Change canvas size //Change canvas size
changeCanvasSize(1050, 750) changeCanvasSize(1050, 750)
@@ -11,6 +11,7 @@ cardData.legendary = false
cardData.creature = false cardData.creature = false
cardData.rareStamp = false cardData.rareStamp = false
cardData.pinline = false cardData.pinline = false
cardData.transparency = true
//Specific Values //Specific Values
cardData.manaSymbolDirection = "none" cardData.manaSymbolDirection = "none"
cardData.titleAlignment = "center" cardData.titleAlignment = "center"
@@ -55,14 +56,7 @@ function bottomInfoPlanechase() {
var infoSet = document.getElementById("inputInfoSet").value var infoSet = document.getElementById("inputInfoSet").value
var infoLanguage = document.getElementById("inputInfoLanguage").value var infoLanguage = document.getElementById("inputInfoLanguage").value
var infoArtist = document.getElementById("inputInfoArtist").value var infoArtist = document.getElementById("inputInfoArtist").value
var infoCopyright = "CC \u2014 " + document.getElementById("inputInfoCopyright").value var infoCopyright = "\u2122 & \u00a9 " + date.getFullYear() + " Wizards of the Coast"
if (infoCopyright == "CC \u2014 secretcode") {
var date = new Date()
var year = date.getFullYear()
infoCopyright = "\u2122 & \u00a9 " + year + " Wizards of the Coast"
} else if (infoCopyright == "CC \u2014 ") {
infoCopyright = ""
}
var infoNumberSetLanguage = infoNumber + " " + infoSet + " \u00b7 " + infoLanguage + " " var infoNumberSetLanguage = infoNumber + " " + infoSet + " \u00b7 " + infoLanguage + " "
textContext.fillStyle = "white" textContext.fillStyle = "white"
textContext.font = cheight(18) + "px gothammedium" textContext.font = cheight(18) + "px gothammedium"

View File

@@ -52,6 +52,8 @@ randomizeSampleCards(7)
//Define important variables //Define important variables
var sectionFrame = 0, sectionText = 0, sectionOther = 0 var sectionFrame = 0, sectionText = 0, sectionOther = 0
var cardWidth = 750, cardHeight = 1050 var cardWidth = 750, cardHeight = 1050
var date = new Date()
document.getElementById("inputInfoNumber").value = date.getFullYear()
var savedArtList = [], cardArtUrlList = [], cardArtArtistList = [] var savedArtList = [], cardArtUrlList = [], cardArtArtistList = []
//Create the object that stores data for convencience :) It's what keeps track of values necessary to change between card frames //Create the object that stores data for convencience :) It's what keeps track of values necessary to change between card frames
var defaultCardData = { var defaultCardData = {
@@ -688,38 +690,27 @@ function bottomInfoM15() {
var infoSet = document.getElementById("inputInfoSet").value var infoSet = document.getElementById("inputInfoSet").value
var infoLanguage = document.getElementById("inputInfoLanguage").value var infoLanguage = document.getElementById("inputInfoLanguage").value
var infoArtist = document.getElementById("inputInfoArtist").value var infoArtist = document.getElementById("inputInfoArtist").value
var infoCopyright = "CC \u2014 " + document.getElementById("inputInfoCopyright").value var infoMessage = "*" + document.getElementById("inputInfoMessage").value + "*"
var infoSetLanguage = infoSet + " \u00b7 " + infoLanguage var infoSetLanguage = infoSet + " \u00b7 " + infoLanguage
textContext.font = "18px gothammedium" textContext.font = "18px gothammedium"
textContext.fillStyle = "white" textContext.fillStyle = "white"
textContext.fillText(infoNumber, 47, 997) textContext.fillText(infoNumber, cwidth(47), cheight(997))
textContext.fillText(infoSetLanguage, 47, 1016) textContext.fillText(infoRarity, cwidth(54) + textContext.measureText(infoNumber).width, cheight(997))
//Takes the longer of the two strings and records its width textContext.fillText(infoMessage, cwidth(61) + textContext.measureText(infoNumber).width + textContext.measureText(infoRarity).width, cheight(997))
var rarityArtistShift = textContext.measureText(infoSetLanguage).width textContext.fillText(infoSetLanguage, cwidth(47), cheight(1016))
if (rarityArtistShift < textContext.measureText(infoNumber).width) { var rarityArtistShift = textContext.measureText(infoSetLanguage).width + 54
rarityArtistShift = textContext.measureText(infoNumber).width imgArtistBrush.load("none", rarityArtistShift, cheight(1003), cwidth(21), cheight(13))
}
rarityArtistShift += 7 + 47
textContext.fillText(infoRarity, rarityArtistShift, 997)
imgArtistBrush.load("none", rarityArtistShift, 1003, 21, 13)
textContext.mask(imgArtistBrush, "none", textContext.fillStyle) textContext.mask(imgArtistBrush, "none", textContext.fillStyle)
textContext.font = "18px belerenbsc" textContext.font = "18px belerenbsc"
textContext.fillText(infoArtist, rarityArtistShift + 25, 1016) textContext.fillText(infoArtist, rarityArtistShift + cwidth(25), cheight(1016))
//"\u2122 & \u00a9 " + year + " Wizards of the Coast"
textContext.font = "18px mplantin" textContext.font = "18px mplantin"
textContext.textAlign = "right" textContext.textAlign = "right"
if (infoCopyright == "CC \u2014 secretcode") { var copyrightMessage = "\u2122 & \u00a9 " + date.getFullYear() + " Wizards of the Coast"
var date = new Date() var copyrightY = cheight(997)
var year = date.getFullYear()
infoCopyright = "\u2122 & \u00a9 " + year + " Wizards of the Coast"
} else if (infoCopyright == "CC \u2014 ") {
infoCopyright = ""
}
var copyrightY = 997
if (document.getElementById("inputCheckboxPowerToughness").checked && cardData.creature) { if (document.getElementById("inputCheckboxPowerToughness").checked && cardData.creature) {
copyrightY = 1016 copyrightY = cheight(1016)
} }
textContext.fillText(infoCopyright, 700, copyrightY) textContext.fillText(copyrightMessage, cwidth(700), copyrightY)
textContext.textAlign = "left" textContext.textAlign = "left"
drawCard() drawCard()
} }

View File

@@ -5,8 +5,8 @@ Duplicates found and removed: ORI, W17, CED
Sets not found: Astral, Deckmasters, Duels of the Planeswalkers Sets not found: Astral, Deckmasters, Duels of the Planeswalkers
The codes have been resourced from the following: The codes have been resourced from the following:
https://en.wikipedia.org/wiki/List_of_Magic:_The_Gathering_sets https://en.wikipedia.org/wiki/List_of_Magic:_The_Gathering_sets
Last updated: 3-29-19 Last updated: 5-13-19
Last set added: Last set added: WAR
*/ */
//Common through Rare //Common through Rare
var setCodeListPreMythic = ['1E', '2E', '2U', '3E', '4E', '5E', '6E', '7E', '8ED', '9ED', '10E', 'AN', var setCodeListPreMythic = ['1E', '2E', '2U', '3E', '4E', '5E', '6E', '7E', '8ED', '9ED', '10E', 'AN',
@@ -23,7 +23,7 @@ var setCodeListPostMythic = ['M10', 'M11', 'M12', 'M13', 'M14', 'M15', 'ORI', 'M
'EMA', 'MM3', 'IMA', 'A25', 'UMA', 'HOP', 'PC2', 'PCA', 'ARC', 'E01', 'CMD', 'CM1', 'C13', 'C14', 'C15', 'EMA', 'MM3', 'IMA', 'A25', 'UMA', 'HOP', 'PC2', 'PCA', 'ARC', 'E01', 'CMD', 'CM1', 'C13', 'C14', 'C15',
'C16', 'CMA', 'C17', 'CM2', 'C18', 'CNS', 'CN2', 'E02', 'BBD', 'UST', 'VMA', 'TPR', 'W16', 'W17', 'C16', 'CMA', 'C17', 'CM2', 'C18', 'CNS', 'CN2', 'E02', 'BBD', 'UST', 'VMA', 'TPR', 'W16', 'W17',
'GK1_IZZET', 'GK1_SELESN', 'GK1_BOROS', 'GK1_GOLGAR', 'GK2_RAKDOS', 'GK2_AZORIU', 'GK2_SIMIC', 'GK1_IZZET', 'GK1_SELESN', 'GK1_BOROS', 'GK1_GOLGAR', 'GK2_RAKDOS', 'GK2_AZORIU', 'GK2_SIMIC',
'GK2_GRUUL', 'GK2_ORZHOV'] 'GK2_GRUUL', 'GK2_ORZHOV', 'WAR']
//Only Rare //Only Rare
var setCodeListRareOnly = ['DRB'] var setCodeListRareOnly = ['DRB']
//Only Mythic //Only Mythic

View File

@@ -272,7 +272,7 @@
<input id="inputInfoArtist" type="text" class="input" value="" oninput="sectionTextFunction()"> <input id="inputInfoArtist" type="text" class="input" value="" oninput="sectionTextFunction()">
<br> <br>
Other Information Other Information
<input id="inputInfoCopyright" type="text" class="input" value="Not a Real Card" oninput="sectionTextFunction()"> <input id="inputInfoMessage" type="text" class="input" value="Not For Sale" oninput="sectionTextFunction()">
</div> </div>
<div class="cmm" id="cmm-art"> <div class="cmm" id="cmm-art">
Upload an Image Upload an Image
@@ -359,7 +359,8 @@
</span> </span>
</div> </div>
<div class="cmm" id="cmm-download"> <div class="cmm" id="cmm-download">
<a onclick="downloadCardImage(this)" id="downloadCardImage" href="" target="_blank" download="card.png">Download</a> <a onclick="downloadCardImage(this)" id="downloadCardImage" href="" target="_blank" download="card.png">Download</a><br><br>
Remember to properly credit the artist (under 'Info') before downloading!
<br> <br>
<!-- <div class="adspace"> <!-- <div class="adspace">
Ads? Ads?