A small script I made that takes any standard Decklist of magic the gathering cards and pulls all card images from scryfall at once!

Overview
README

This small script takes any decklist from an MTGO list and pulls all card images as jpg files into your directory.

This work is free of course, but if you like mtg, gadgetry, and nerd stuff feel free to follow me on https://www.twitter.com/izzitmichaela for more projects!

INSTRUCTIONS FOR USE

INSTALLING PYTHON:
If you have never used python before - yo'll need to install the environment. The environment I have is anaconda, which you can download below:
https://www.anaconda.com/products/individual

It might be too much for your needs - if you know of a simpler python environment feel free to use any one you like.

You may also need to install the requests package. You can use this link to download that once you have installed python.
Installing the requests package -  https://t.co/uQMeCcwCkC

Okay now that python is set up you're ready to go!

0-Download files included in the project. There should be two - a deck txt file and a python runner file

1-Go to https://scryfall.com/docs/api/bulk-data
2-Download the 'All Cards' File from the list.
3-Ensure that the name of the file is "all-cards.json".
4-Place file in the SAME folder as the other files.
5-Update the Deck txt file to include whatever cards you would wish.
	NOTE: Be sure they are in MTGO format, and be sure that only cards with single digit quantities are present
	This means you cannot have '15 Abrade' but you can have '9 Abrade'
6-Run the python file. If you want the little white corners cropped off, select the Runner_croppedBorders program. This stores them as png files rather than jpgs and are larger, but they look cleaner and dont have those silly white parts on the four corners.

The jpg files should appear in your directory after a moment or two!

Enjoy!


You might also like...
A Lego Mindstorm robot for dealing out cards based on a birds-eye view of a poker table and given ArUco fiducial tags.

A Lego Mindstorm robot for dealing out cards based on a birds-eye view of a poker table and given ArUco fiducial tags.

A tool to guide you for team selection based on mana and ruleset using your owned cards.

Splinterlands_Teams_Guide A tool to guide you for team selection based on mana and ruleset using your owned cards. Built With This project is built wi

Mnemosyne: efficient learning with powerful digital flash-cards.

Mnemosyne: Optimized Flashcards and Research Project Mnemosyne is: a free, open-source, spaced-repetition flashcard program that helps you learn as ef

Easily Generate Revolut Business Cards

RevBusinessCardGen Easily Generate Revolut Business Cards Prerequisites Before you begin, ensure you have met the following requirements: You have ins

Anki cards generator for Leetcode
Anki cards generator for Leetcode

Leetcode Anki card generator Summary By running this script you'll be able to generate Anki cards with all the leetcode problems. I personally use it

Build Xmas cards with user inputs
Build Xmas cards with user inputs

Automatically build Xmas cards with user inputs

This an Anki add on that automatically converts Notion notes into Anki flash cards. Currently in development!

NotionFlash This is an Anki add on in development that will allow automatically convert your Notion study notes into Anki flash cards. The Anki deck c

Anki Cards for the HSK vocabulary Chinese-German
Anki Cards for the HSK vocabulary Chinese-German

Anki-HanyuShuipingKaoshi Anki Cards for the HSK vocabulary Chinese-German Das Deck baut auf folgenden Quellen auf: China Endecken Wortschatz von wohok

DRF magic links

drf-magic-links Installation pip install drf-magic-links Add URL patterns # urls.py

Comments
  • More than nine

    More than nine

    Hi Michaela,

    I saw your script and decided to contribute some changes:

    1. Use regex for grabbing card names. The "can't have more than 9 copies of a card in the deck" restriction felt exclusionary to Persistent Petitioners players, so I decided to relax that constraint by using a regular expression to grab the card name. Regular expressions are bonkers, but this tool helps explain what's going on (though it isn't processing the newline characters right so I got rid of them for the demonstration).
    2. Use web request to grab card info. Making people go and fetch the all-cards JSON isn't necessary, and it's a little inconvenient -- they'd have to go get it again every time they want to make a video about new cards. So instead, I'm using the Scryfall /cards/collections endpoint to fetch the card data for all the cards in the user's deck at runtime.
    3. Handle double-faced cards. The way the Scryfall API handles fellows like Delver of Secrets (here) wasn't getting parsed correctly -- you'll note this card doesn't have an images_uris property, and instead it has a card_faces property which is a list of faces where each face has image URIs. So I added the appropriate parsing for that case.
    4. Changes to the README. It's a Markdown file now, so it has fancy styling and whatnot. Also I made a requirements.txt file so people can install the requests package from the command line with a simple command I've included in the README.
    5. Save card images to sub-folder. Maybe just a personal preference thing, but I think it's nicer.
    6. Select deck file with OS file dialog. Just a quality-of-life improvement so people don't have to copy-paste into Deck.txt :)

    Please let me know if you have any questions, and thanks for putting this together!

    opened by Ragaxus 0
Owner
null
Shopping-card - Shopping Card Project With Python

Shopping Card Project this application was built to handle problems with saving

moein98 1 May 6, 2022
OCR-ID-Card VietNamese (new id-card)

OCR-ID-Card VietNamese (new id-card) run project: download 2 file weights and pu

null 12 Jun 15, 2022
Donatus Prince 6 Feb 25, 2022
Islam - This is a simple python script.In this script I have written all the suras of Al Quran. As a result, by using this script, you can know the number of any sura at the moment.

Introduction: If you want to know sura number of al quran by just typing the name of sura than you can use this script. Usage in termux: $ pkg install

Fazle Rabbi 1 Jan 2, 2022
Automatically deletes Capital One Eno virtual cards for when you've made a couple too many.

eno-delete Automatically deletes Capital One Eno virtual cards for when you've made a couple too many. Warning: Program will delete ALL virtual cards

h3x 3 Sep 29, 2022
A python script made for personal use to monitor for sports card restocks on target.com since they are sold out often

TargetProductMonitor A python script made for personal use to monitor for sports card resocks on target.com since they are sold out often. When a rest

Bryan Lorden 2 Jul 31, 2022
A tool to replace all osu beatmap backgrounds at once.

OsuBgTool A tool to replace all osu beatmap backgrounds at once. Requirements You need to have python 3.6 or newer installed. That's it. How to Use Ju

Aditya Gupta 1 Oct 24, 2021
With Christmas and New Year ahead, it is time for some festive coding. Here is a Christmas Card for you all!

Christmas Card With Christmas and New Year ahead, it is time for some festive coding! Here is a Christmas Card for you all! NOTE: I have not made this

CodeMaster7000 1 Dec 25, 2021
A simple script written using symbolic python that takes as input a desired metric and automatically calculates and outputs the Christoffel Pseudo-Tensor, Riemann Curvature Tensor, Ricci Tensor, Scalar Curvature and the Kretschmann Scalar

A simple script written using symbolic python that takes as input a desired metric and automatically calculates and outputs the Christoffel Pseudo-Tensor, Riemann Curvature Tensor, Ricci Tensor, Scalar Curvature and the Kretschmann Scalar

null 2 Nov 27, 2021
🎴 LearnQuick is a flashcard application that you can study with decks and cards.

?? LearnQuick is a flashcard application that you can study with decks and cards. The main function of the application is to show the front sides of the created cards to the user and ask them to guess the back of the card. As a result of self-assessment of user's ability to guess the back sides of the displayed cards, the cards that user weak against are shown more often, and the cards that user strong against are shown less frequently.

Mehmet Güdük 7 Aug 21, 2022