diff --git a/data/borders/old/artifact/frame.png b/data/borders/old/artifact/frame.png new file mode 100644 index 00000000..7f73073a Binary files /dev/null and b/data/borders/old/artifact/frame.png differ diff --git a/data/borders/old/artifact/pt.png b/data/borders/old/artifact/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/artifact/pt.png differ diff --git a/data/borders/old/black/frame.png b/data/borders/old/black/frame.png new file mode 100644 index 00000000..bdb806be Binary files /dev/null and b/data/borders/old/black/frame.png differ diff --git a/data/borders/old/black/pt.png b/data/borders/old/black/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/black/pt.png differ diff --git a/data/borders/old/blackLand/frame.png b/data/borders/old/blackLand/frame.png new file mode 100644 index 00000000..1e23ba19 Binary files /dev/null and b/data/borders/old/blackLand/frame.png differ diff --git a/data/borders/old/blackLand/pt.png b/data/borders/old/blackLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/blackLand/pt.png differ diff --git a/data/borders/old/blue/frame.png b/data/borders/old/blue/frame.png new file mode 100644 index 00000000..7ff32780 Binary files /dev/null and b/data/borders/old/blue/frame.png differ diff --git a/data/borders/old/blue/pt.png b/data/borders/old/blue/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/blue/pt.png differ diff --git a/data/borders/old/blueLand/frame.png b/data/borders/old/blueLand/frame.png new file mode 100644 index 00000000..9c76a47d Binary files /dev/null and b/data/borders/old/blueLand/frame.png differ diff --git a/data/borders/old/blueLand/pt.png b/data/borders/old/blueLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/blueLand/pt.png differ diff --git a/data/borders/old/border.js b/data/borders/old/border.js new file mode 100644 index 00000000..4a1ff4f5 --- /dev/null +++ b/data/borders/old/border.js @@ -0,0 +1,64 @@ +//============================================// +// OLD Border // +//============================================// +//General Booleans +cardData.miracle = false +cardData.nyx = false +cardData.rareStamp = false +cardData.legendary = false +cardData.pinline = false +cardData.titleTypeBoxes = false +cardData.bottomInfoFunction = "none" +//Specific Values +cardData.cardArtX = cwidth(89) +cardData.cardArtY = cheight(103) +cardData.manaSymbolX = cwidth(655) +cardData.manaSymbolY = cheight(50) +document.getElementById("inputTitleColor").value = "#ffffff" +cardData.titleFont = "goudymedieval" +cardData.titleShadow = cwidth(2) +cardData.titleFontSize = cwidth(43) +cardData.titleX = cwidth(81) +cardData.titleY = cheight(81) +document.getElementById("inputTypeColor").value = "#ffffff" +cardData.typeFont = "mplantin" +cardData.typeShadow = cwidth(2) +cardData.typeX = cwidth(76) +cardData.typeY = cheight(616) +cardData.textX = cwidth(92) +cardData.textY = cheight(657) +document.getElementById("inputCreatureColor").value = "#ffffff" +cardData.ptFont = "46px mplantin" +cardData.ptShadow = cwidth(2) +cardData.ptX = cwidth(655) +cardData.ptY = cheight(984) +cardData.setSymbolX = cwidth(671) +cardData.setSymbolY = cheight(603) +cardData.bottomInfoFunction = "bottomInfoOld" +//Images +imgArtMask.load("data/borders/old/imgArtMask.png") +imgFrameMask.load("data/borders/old/imgFrameMask.png") +imgRulesMask.load("data/borders/old/imgRulesMask.png") +imgBorderMask.load("data/borders/old/imgBorderMask.png") + +//Loads the colors +loadColors("white-White,blue-Blue,black-Black,red-Red,green-Green,gold-Gold,artifact-Artifact,whiteLand-White Land,blueLand-Blue Land,blackLand-Black Land,redLand-Red Land,greenLand-Green Land,colorlessLand-Colorless Land") +//Finishes loading the border style +finishChangingBorder() + +function bottomInfoOld() { + var infoArtist = "Illus. " + document.getElementById("inputInfoArtist").value + var copyrightNumber = "\u2122 & \u00a9 1993-" + date.getFullYear() + " Wizards of the Coast, Inc. " + document.getElementById("inputInfoNumber").value + textContext.textAlign = "center" + textContext.fillStyle = "black" + textContext.font = "31px mplantin" + textContext.fillText(infoArtist, cwidth(377), cheight(970)) + textContext.fillStyle = "white" + textContext.fillText(infoArtist, cwidth(375), cheight(968)) + if (document.getElementById("inputFrameColor").value.includes("white")) { + textContext.fillStyle = "black" + } + textContext.font = "17px mplantin" + textContext.fillText(copyrightNumber, cwidth(375), cheight(989)) + drawCard() +} \ No newline at end of file diff --git a/data/borders/old/colorlessLand/frame.png b/data/borders/old/colorlessLand/frame.png new file mode 100644 index 00000000..21b4d6cd Binary files /dev/null and b/data/borders/old/colorlessLand/frame.png differ diff --git a/data/borders/old/colorlessLand/pt.png b/data/borders/old/colorlessLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/colorlessLand/pt.png differ diff --git a/data/borders/old/gold/frame.png b/data/borders/old/gold/frame.png new file mode 100644 index 00000000..8d22a92b Binary files /dev/null and b/data/borders/old/gold/frame.png differ diff --git a/data/borders/old/gold/pt.png b/data/borders/old/gold/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/gold/pt.png differ diff --git a/data/borders/old/green/frame.png b/data/borders/old/green/frame.png new file mode 100644 index 00000000..af2d965e Binary files /dev/null and b/data/borders/old/green/frame.png differ diff --git a/data/borders/old/green/pt.png b/data/borders/old/green/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/green/pt.png differ diff --git a/data/borders/old/greenLand/frame.png b/data/borders/old/greenLand/frame.png new file mode 100644 index 00000000..e24955fb Binary files /dev/null and b/data/borders/old/greenLand/frame.png differ diff --git a/data/borders/old/greenLand/pt.png b/data/borders/old/greenLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/greenLand/pt.png differ diff --git a/data/borders/old/imgArtMask.png b/data/borders/old/imgArtMask.png new file mode 100644 index 00000000..48acf937 Binary files /dev/null and b/data/borders/old/imgArtMask.png differ diff --git a/data/borders/old/imgBorderMask.png b/data/borders/old/imgBorderMask.png new file mode 100644 index 00000000..213bee59 Binary files /dev/null and b/data/borders/old/imgBorderMask.png differ diff --git a/data/borders/old/imgFrameMask.png b/data/borders/old/imgFrameMask.png new file mode 100644 index 00000000..55b00a7f Binary files /dev/null and b/data/borders/old/imgFrameMask.png differ diff --git a/data/borders/old/imgRulesMask.png b/data/borders/old/imgRulesMask.png new file mode 100644 index 00000000..7f0fbd09 Binary files /dev/null and b/data/borders/old/imgRulesMask.png differ diff --git a/data/borders/old/red/frame.png b/data/borders/old/red/frame.png new file mode 100644 index 00000000..f2e34555 Binary files /dev/null and b/data/borders/old/red/frame.png differ diff --git a/data/borders/old/red/pt.png b/data/borders/old/red/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/red/pt.png differ diff --git a/data/borders/old/redLand/frame.png b/data/borders/old/redLand/frame.png new file mode 100644 index 00000000..2aab3b4c Binary files /dev/null and b/data/borders/old/redLand/frame.png differ diff --git a/data/borders/old/redLand/pt.png b/data/borders/old/redLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/redLand/pt.png differ diff --git a/data/borders/old/white/frame.png b/data/borders/old/white/frame.png new file mode 100644 index 00000000..7906316f Binary files /dev/null and b/data/borders/old/white/frame.png differ diff --git a/data/borders/old/white/pt.png b/data/borders/old/white/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/white/pt.png differ diff --git a/data/borders/old/whiteLand/frame.png b/data/borders/old/whiteLand/frame.png new file mode 100644 index 00000000..7a7ad8c1 Binary files /dev/null and b/data/borders/old/whiteLand/frame.png differ diff --git a/data/borders/old/whiteLand/pt.png b/data/borders/old/whiteLand/pt.png new file mode 100644 index 00000000..fd7ace80 Binary files /dev/null and b/data/borders/old/whiteLand/pt.png differ diff --git a/data/fonts/goudy-medieval.ttf b/data/fonts/goudy-medieval.ttf new file mode 100644 index 00000000..3f0c59e3 Binary files /dev/null and b/data/fonts/goudy-medieval.ttf differ diff --git a/data/fonts/goudy-medieval/Goudy Mediaeval DemiBold.ttf b/data/fonts/goudy-medieval/Goudy Mediaeval DemiBold.ttf new file mode 100644 index 00000000..67667056 Binary files /dev/null and b/data/fonts/goudy-medieval/Goudy Mediaeval DemiBold.ttf differ diff --git a/data/fonts/goudy-medieval/Goudy Mediaeval Regular.ttf b/data/fonts/goudy-medieval/Goudy Mediaeval Regular.ttf new file mode 100644 index 00000000..3f0c59e3 Binary files /dev/null and b/data/fonts/goudy-medieval/Goudy Mediaeval Regular.ttf differ diff --git a/data/fonts/goudy-medieval/Goudy Medieval Alternate.ttf b/data/fonts/goudy-medieval/Goudy Medieval Alternate.ttf new file mode 100644 index 00000000..58813bff Binary files /dev/null and b/data/fonts/goudy-medieval/Goudy Medieval Alternate.ttf differ diff --git a/data/main.js b/data/main.js index 87fc61f5..a9c850c2 100644 --- a/data/main.js +++ b/data/main.js @@ -59,10 +59,10 @@ var savedArtList = [], cardArtUrlList = [], cardArtArtistList = [] var defaultCardData = { version:"m15", manaSymbolX:cwidth(659), manaSymbolY:cheight(60), manaSymbolRadius:cwidth(17.5), manaSymbolDirection:"left", - titleX:cwidth(63), titleY:cheight(94), titleRight:cwidth(687), titleFont:"belerenb", titleFontSize:cwidth(40), titleAlignment:"left", - typeX:cwidth(63), typeY:cheight(630), typeRight:cwidth(687), typeFont:"belerenb", typeFontSize:cwidth(34), typeAlignment:"left", + titleX:cwidth(63), titleY:cheight(94), titleRight:cwidth(687), titleFont:"belerenb", titleFontSize:cwidth(40), titleAlignment:"left", titleShadow:"none", + typeX:cwidth(63), typeY:cheight(630), typeRight:cwidth(687), typeFont:"belerenb", typeFontSize:cwidth(34), typeAlignment:"left", typeShadow:"none", textX:cwidth(63), textY:cheight(690), textRight:cwidth(690), textFont:"mplantin", - ptFont:"39px belerenb", ptX:cwidth(645), ptY:cheight(975), + ptFont:"39px belerenb", ptX:cwidth(645), ptY:cheight(975), ptShadow:"none", ptBoxX:cwidth(571), ptBoxY:cheight(929), ptBoxWidth:cwidth(135), ptBoxHeight:cheight(76), setSymbolWidth:cwidth(77), setSymbolHeight:cheight(42), setSymbolX:cwidth(693), setSymbolY:cheight(620), setSymbolAlignment:"right", watermarkWidth:cwidth(520), watermarkHeight:cheight(250), watermarkY:cheight(815), @@ -185,7 +185,7 @@ CanvasRenderingContext2D.prototype.mask = function(image, masks, color, maskOpac } //Text processor... kind of? -CanvasRenderingContext2D.prototype.writeText = function(text, inputX, inputY, inputRightLimit, textFont, textFontSize, textColor, skipLines, outline, outlineColor, textAlignment = "left") { +CanvasRenderingContext2D.prototype.writeText = function(text, inputX, inputY, inputRightLimit, textFont, textFontSize, textColor, skipLines, outline, outlineColor, textAlignment = "left", shadow = "none") { this.font = textFontSize + "px " + textFont this.fillStyle = textColor this.strokeStyle = outlineColor @@ -210,6 +210,11 @@ CanvasRenderingContext2D.prototype.writeText = function(text, inputX, inputY, in textFontSize -= 0.5 this.font = textFontSize + "px " + textFont } + if (shadow != false) { + this.fillStyle = "black" + this.fillText(text, x + shadow, y + shadow) + this.fillStyle = textColor + } if (outline) { this.strokeText(text, x, y) } @@ -661,8 +666,8 @@ function sectionTextFunction() { textContext.clearRect(0, 0, cardWidth, cardHeight) //mana cost, name, type, text var manaSymbolWidth = textContext.manaCost(document.getElementById("inputCost").value, cardData.manaSymbolX, cardData.manaSymbolY, cardData.manaSymbolRadius, cardData.manaSymbolDirection) - textContext.writeText(document.getElementById("inputName").value, cardData.titleX, cardData.titleY, cardData.titleRight - manaSymbolWidth, cardData.titleFont, cardData.titleFontSize, document.getElementById("inputTitleColor").value, false, document.getElementById("inputCheckboxTitleOutline").checked, document.getElementById("inputTitleOutlineColor").value, cardData.titleAlignment) - textContext.writeText(document.getElementById("inputType").value, cardData.typeX, cardData.typeY, cardData.typeRight, cardData.typeFont, cardData.typeFontSize, document.getElementById("inputTypeColor").value, false, document.getElementById("inputCheckboxTypeOutline").checked, document.getElementById("inputTypeOutlineColor").value, cardData.typeAlignment) + textContext.writeText(document.getElementById("inputName").value, cardData.titleX, cardData.titleY, cardData.titleRight - manaSymbolWidth, cardData.titleFont, cardData.titleFontSize, document.getElementById("inputTitleColor").value, false, document.getElementById("inputCheckboxTitleOutline").checked, document.getElementById("inputTitleOutlineColor").value, cardData.titleAlignment, cardData.titleShadow) + textContext.writeText(document.getElementById("inputType").value, cardData.typeX, cardData.typeY, cardData.typeRight, cardData.typeFont, cardData.typeFontSize, document.getElementById("inputTypeColor").value, false, document.getElementById("inputCheckboxTypeOutline").checked, document.getElementById("inputTypeOutlineColor").value, cardData.typeAlignment, cardData.typeShadow) textContext.writeText(document.getElementById("inputText").value, cardData.textX, cardData.textY + parseInt(document.getElementById("inputTextDown").value), cardData.textRight, cardData.textFont, parseInt(document.getElementById("inputTextSize").value), document.getElementById("inputRulesColor").value, true, document.getElementById("inputCheckboxRulesOutline").checked, document.getElementById("inputRulesOutlineColor").value) //Power Toughness if (document.getElementById("inputCheckboxPowerToughness").checked && cardData.creature) { @@ -674,6 +679,11 @@ function sectionTextFunction() { textContext.textAlign = "center" textContext.font = cardData.ptFont textContext.fillStyle = document.getElementById("inputCreatureColor").value + if (cardData.ptShadow != "none") { + textContext.fillStyle = "black" + textContext.fillText(document.getElementById("inputPowerToughness").value, cardData.ptX + parseInt(cardData.ptShadow), cardData.ptY + parseInt(cardData.ptShadow)) + textContext.fillStyle = document.getElementById("inputCreatureColor").value + } textContext.fillText(document.getElementById("inputPowerToughness").value, cardData.ptX, cardData.ptY) textContext.textAlign = "left" } @@ -1036,20 +1046,14 @@ function checkCookies() { alert("Thanks for using Card Conjurer! Unfortunately different browsers treat custom fonts differently and it appears that you are using a browser other than Chrome. Everything may work perfectly, but if you notice that the text looks odd try switching to Chrome.") } setCookie("visited", "true") - setCookie("cookieUpdated4", "true") + setCookie("cookieUpdated5", "true") } else { console.log("Welcome back to Card Conjurer!") - if (getCookie("cookieUpdated4") != "true") { - alert("Card Conjurer has been updated since your last visit. After reworking the system I haven't had time to add all the old border styles back, but feel free to contact me at CardConjurerMTG@gmail.com if you would like to request a border style or have any questions. \r\n\r\nNewest border style: Plane") - setCookie("cookieUpdated4", "true") + if (getCookie("cookieUpdated5") != "true") { + alert("Card Conjurer has been updated since your last visit. Feel free to contact me at CardConjurerMTG@gmail.com if you would like to request a border style or have any questions. \r\n\r\nNewest border style: Old") + setCookie("cookieUpdated5", "true") } else { console.log("There are no new updates since your last visit.") - if (getCookie("donationRequest") != "true") { - alert("Card Conjurer is now hosted with the custom domain cardconjurer.com! That means that running this website currently costs $10 per year. It's not much, but any donation, even if it's just dollar, would be greatly appreciated :) \r\n\r\nAnyways, thanks for using Card Conjurer! I hope you enjoy making some sweet custom Magic cards!") - setCookie("donationRequest", "true") - } else { - console.log("I hope you enjoy making custom cards!") - } } } } @@ -1076,7 +1080,7 @@ setTimeout(function(){sectionTextFunction()}, 500) setTimeout(function(){sectionTextFunction()}, 1000) // Only for working on frames n' stuff :) // setTimeout(function(){ -// document.getElementById("inputCardVersion").value = "plane" +// document.getElementById("inputCardVersion").value = "old" // document.getElementById("inputCardVersion").onchange() // }, 500) diff --git a/data/other/setCodeList.js b/data/other/setCodeList.js index a01f0665..130b0e1e 100644 --- a/data/other/setCodeList.js +++ b/data/other/setCodeList.js @@ -13,14 +13,14 @@ var setCodeListPreMythic = ['1E', '2E', '2U', '3E', '4E', '5E', '6E', '7E', '8ED 'AQ', 'LE', 'DK', 'FE', 'HM', 'IA', 'AL', 'MI', 'VI', 'WL', 'TE', 'ST', 'EX', 'UZ', 'GU', 'AP', 'OD', 'TOR', 'JUD', 'ONS', 'LGN', 'SCG', 'MRD', 'DST', '5DN', 'CHK', 'BOK', 'SOK', 'RAV', 'GPT', 'DIS', 'CSP', 'TSP', 'PLC', 'FUT', 'LRW', 'MOR', 'SHM', 'EVE', 'PO', 'P2', 'PK', 'P3', 'P4', 'CH', 'BR', 'BD', 'EVG', -'UG', 'UNH', 'MED', 'ME2', 'ME3', 'ME4'] +'UG', 'UNH', 'MED', 'ME2', 'ME3', 'ME4', 'HOP'] //Common through Mythic var setCodeListPostMythic = ['M10', 'M11', 'M12', 'M13', 'M14', 'M15', 'ORI', 'M19', 'ALA', 'CON', 'ARB', 'ZEN', 'WWK', 'ROE', 'SOM', 'MBS', 'NPH', 'ISD', 'DKA', 'AVR', 'RTR', 'GTC', 'DGM', 'THS', 'BNG', 'JOU', 'KTK', 'FRF', 'DTK', 'BFZ', 'OGW', 'SOI', 'EMN', 'KLD', 'AER', 'AKH', 'HOU', 'XLN', 'RIX', 'DOM', 'GRN', 'RNA', /*'MH1',*/ 'GS1', 'MD1', 'DD2', 'DDC', 'DDD', 'DDE', 'DDF', 'DDG', 'DDH', 'DDI', 'DDJ', 'DDK', 'DDL', 'DDM', 'DDN', 'DDP', 'DDQ', 'DDR', 'DDS', 'DDT', 'DDU', 'SS1', 'H09', 'PD2', 'PD3', 'MMA', 'MM2', -'EMA', 'MM3', 'IMA', 'A25', 'UMA', 'HOP', 'PC2', 'PCA', 'ARC', 'E01', 'CMD', 'CM1', 'C13', 'C14', 'C15', +'EMA', 'MM3', 'IMA', 'A25', 'UMA', 'PC2', 'PCA', 'ARC', 'E01', 'CMD', 'CM1', 'C13', 'C14', 'C15', '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', 'GK2_GRUUL', 'GK2_ORZHOV', 'WAR'] diff --git a/index.html b/index.html index 6ff5fa0e..fd3e2fbb 100644 --- a/index.html +++ b/index.html @@ -88,6 +88,7 @@ - +

Rules Text

Rules Text Font Size - +
Pixels Between Paragraphs @@ -476,10 +477,10 @@