$card->flavor .= ' // ' . $card2->flavor; $card->pt .= '//' . $card2->pt; $card->set = $card2->set; $card->rarity = $card2->rarity; } else if ($cardType == 'f' || $cardType == 'fl') { $card = promptCardInfo($cardType, false); $card2 = promptCardInfo($cardType, true); $card->legal .= "\n-----\n" . $card2->title . "\n" . $card2->type . "\n" . $card2->pt . "\n" . $card2->legal; } else $card = promptCardInfo($cardType); $writer->addCard($card); echo "Generating image...\n"; $writer->writeCards(); echo "Image generation complete.\n"; function promptCardInfo ($cardType, $isLastCard = true) { global $writer; $card = new Card(); echo "Title:\n"; $card->title = upperCaseWords(trim(fgets(STDIN))); if (!$card->title) error('Invalid title.'); if ($cardType != 'v' && $cardType != 'l' && $cardType != 'fl' && ($cardType != 'f' || !$isLastCard)) { echo "Casting cost (ex: 4R, {4}{R}, 1RWU, {10}{WU}):\n";