Someone e-mailed me to let me know that the "Timeshifted" cards from Time Spiral were missing.
It looks like Wizards considers the Timeshifted cards in Time Spiral as a separate subset of cards.
They've given them their own expansion name (Time Spiral "Timeshifted") and code (TSB (instead of TSP for Time Spiral))
I'd like to point out that there aren't currently any MTG applications that fully support foreign card data. You've brought us half way there with the foreign names, but I'd love to see the card types and text as well. The data is available on Gatherer's foreign card pages, you just have to select "display: printed" to view it. Note that older foreign sets aren't included and each card has a unique multiverse id, in case you want to save those too. This app at the CCGHQ uses this data to render foreign MTG cards at 300dpi resolution, a much preferred alternative to gatherer images. Granted, it has not been updated lately, but it still works for 95% of everything. We would be thrilled if you could add support for foreign type and text.
I'd kind of like to see gatherer's community ratings on a whim too.
I'd like to point out that there aren't currently any MTG applications that fully support foreign card data. You've brought us half way there with the foreign names, but I'd love to see the card types and text as well. The data is available on Gatherer's foreign card pages, you just have to select "display: printed" to view it. Note that older foreign sets aren't included and each card has a unique multiverse id, in case you want to save those too. This app at the CCGHQ uses this data to render foreign MTG cards at 300dpi resolution, a much preferred alternative to gatherer images. Granted, it has not been updated lately, but it still works for 95% of everything. We would be thrilled if you could add support for foreign type and text.
I'd kind of like to see gatherer's community ratings on a whim too.
Thanks for this awesome resource!
Hello
I think this is the second or third request I've had for full foreign language text, so when I get back from vacation (early December) (and after I fix some MTGImage issues) I will look seriously into adding foreign language text.
As for the community ratings, I had thought about adding them in the past but decided against it. They feel too "gatherer specific", like that info belongs more to the gatherer social community and less about the card and it didn't feel right just copying it and sticking into the JSON. I try to keep the JSON about just the cards themselves as much as possible. Does that make sense? I dunno, maybe I'm just being silly.
Thanks a lot for the suggestions, I'll reply here once I have some updates to share on the foreign text.
Not including the community ratings makes sense when you put it like that. Thanks for considering the foreign text. It will make this resource the best on the internet! I look forward to the update.
Generally how soon after Gatherer adds new text to the database will it be available on your website? Also, do you keep your github source up-to-date with all the changes you make? Thanks!
Not including the community ratings makes sense when you put it like that. Thanks for considering the foreign text. It will make this resource the best on the internet! I look forward to the update.
Generally how soon after Gatherer adds new text to the database will it be available on your website? Also, do you keep your github source up-to-date with all the changes you make? Thanks!
I try and add the set the same day that Gatherer gets the set. In the past I've been pretty close to the day it gets added on gatherer, usually about 1 or 2 days after. I'm going to try and get as close to the same day as possible in the future
As for the source, yes, I update it whenever I make changes so it is up to date. (Some day I want to make the source a bit easier to run, right now it's still a bit tricky)
I'm currently working on a small PHP program to convert the json to a ready to go mysql db. It's not 100% yet, but soon I'll finish it. (Updated almost daily or weekly.)
I'm currently working on a small PHP program to convert the json to a ready to go mysql db. It's not 100% yet, but soon I'll finish it. (Updated almost daily or weekly.)
This is beautiful!! Been looking for something like this for ages... Was WAY too lazy to write my own scraping utility. Wrote a simple PHP class that takes your data and puts it in a MySQL database. Only took about 20 minutes to write!! That's how easy it was to use your format :). I appreciate it so much!! I'll let you know of any bugs I may come across...
This is beautiful!! Been looking for something like this for ages... Was WAY too lazy to write my own scraping utility. Wrote a simple PHP class that takes your data and puts it in a MySQL database. Only took about 20 minutes to write!! That's how easy it was to use your format :). I appreciate it so much!! I'll let you know of any bugs I may come across...
Thanks for the nice comments, I'm glad you find it useful!
This is an awesome resource. I wrote a Gatherer parser a while back, but Gatherer has some issues, especially with flip cards and transforming cards (I tried for a while to find a simple way to analytically determine what card was the reverse face of another.) I'm using this for a parser I'm writing in Java to create query-able objects, so I can do weird searches that I would never be able to do with Gatherer, like "What's the wordiest card?" or "What creature types are present in exactly one color?"
I do have one recommendation, though: an attribute for color indicator. I guess you could infer it by "subtracting" the the set of colors in the cost from the "color" attribute, but it might be nice to have. What do you think? (Edit: Actually, I think color indicator only applies to cards that would otherwise be colorless, in which case I guess this wouldn't be as useful.)
Again, this is very useful, thanks for putting it up. Where did you get the raw data from?
Oh yeah, one more thing: at least for my purposes, it would be better if the expansions and the cards were separate entities (i.e., an array of expansions followed by an array of cards.) This way, each card would only have to appear once, and it could have a printings attribute like it does in the "extra" version. Then you could combine the rarities with the printings, like Loxodon Warhammer would have "printings":[{"set":"MRD","rarity":""uncommon"},{"set":"10E","rarity":"rare"}] or something like that.
Obviously that won't be good for the set-only files, but for the full list it would reduce the size by a lot and make parsing it easier (at least for some applications.)
Well actually, the color field seems to be the value of the color indicator if present, otherwise the color based on the mana cost. Which is good. It just doesn't say whether the value of the color field is derived from the indicator or the cost.
Well actually, the color field seems to be the value of the color indicator if present, otherwise the color based on the mana cost. Which is good. It just doesn't say whether the value of the color field is derived from the indicator or the cost.
Yes, you are correct, this is exactly how it works on MTGJSON. I thought about providing a boolean field for colorIndiactor, but realized that as you mentioned, this can be deduced (if needed) from the colors field vs the casting cost colors. I try not to provide too much 'calculated' data above the base data in order to keep things more straightforward. I hope that makes sense
Oh yeah, one more thing: at least for my purposes, it would be better if the expansions and the cards were separate entities (i.e., an array of expansions followed by an array of cards.) This way, each card would only have to appear once, and it could have a printings attribute like it does in the "extra" version. Then you could combine the rarities with the printings, like Loxodon Warhammer would have "printings":[{"set":"MRD","rarity":""uncommon"},{"set":"10E","rarity":"rare"}] or something like that.
Obviously that won't be good for the set-only files, but for the full list it would reduce the size by a lot and make parsing it easier (at least for some applications.)
I see how that could be useful. However I'm trying to keep things as simple as possible, which means not presenting too many different formats of the data. I feel like it's pretty simple for a developer to take the data as is, and then convert it into a format that works better for them. My goal is to provide accurate data, then leave it up to the developers consuming that data to massage it into other formats/layouts.
Small issue I found that you might want to fix (which I assume is really an issue in your raw data): in Rise of the Eldrazi, Spawnsire of Ulamog's activated ability is listed as "{2}0:" rather than "{20}:".
Small issue I found that you might want to fix (which I assume is really an issue in your raw data): in Rise of the Eldrazi, Spawnsire of Ulamog's activated ability is listed as "{2}0:" rather than "{20}:".
Fixed! Thanks for reporting it. It was indeed a bug on gatherer.
Sembiance, have you considered making all sets available as a zip file? Compared to 10mb JSON download, a zip file with all sets is just 2mb. Just a thought
When you update MTGJSON, do you post incremental updates or full updates? In other words, are you saving all of the data from scratch or just adding the newest set release to the previously compiled data?
A thought on AllSets-x.json - in the "printings" array, wouldn't it drastically reduce the file size if you used set codes instead of listing the whole set names? Then in your separate sets.json file you could map the full names to the codes for easy cross reference.
Also, is it intentional that there are two line feeds between abilities? Wouldn't one be sufficient to reduce redundancy / the number of characters in the JSON?
"Enchant artifact\n\nAs long as enchanted artifact isn't a creature, it's an artifact creature with power and toughness each equal to its converted mana cost."
When you update MTGJSON, do you post incremental updates or full updates? In other words, are you saving all of the data from scratch or just adding the newest set release to the previously compiled data?
When a new set comes out, I add the new set and update any previous sets that contain those cards so their 'printings' field will be correct.
This should ensure the card data is up to date, except for possibly rulings. I'm not sure exactly how often WotC updates rulings so right now rulings only get updated when either a set has a card re-printed (as I re-scrape the old set to ensure the 'printings' field gets updated) or when someone lets me know that rulings are out of date for a card or set.
In fact I just posted an update a few seconds ago that has updated rulings for DGM.
A thought on AllSets-x.json - in the "printings" array, wouldn't it drastically reduce the file size if you used set codes instead of listing the whole set names? Then in your separate sets.json file you could map the full names to the codes for easy cross reference.
Yes, this is something I should have done from the beginning. It was a bit of a mistake to use the full set names here.
Unfortunately lots of apps/websites out there use this JSON and so I am hesitant to perform any changes that would break apps that use the data in the format it is in now.
I've thought about adding some sort of 'versioning' of the data format, but this would just complicate things and I really want to keep complexity down.
I'm ok with the data being larger from a bandwidth point of view, and if anyone out there wants to use this data but wants the size to be smaller, they can pretty simply convert the set names to codes on their side before they package it up in their app/website.
Also, is it intentional that there are two line feeds between abilities? Wouldn't one be sufficient to reduce redundancy / the number of characters in the JSON?
"Enchant artifact\n\nAs long as enchanted artifact isn't a creature, it's an artifact creature with power and toughness each equal to its converted mana cost."
Yes, this was intentional. When first parsing the data, I used double line feeds to denote different sections of text on the card that had a bit of space between them. I used two because I thought there may be some cards that have a single new line within a section of text, without it being part of a new section of text... if that all make sense.
It turns out that this doesn't happen and thus I could replace all double new lines with just single ones.
Again though, I'm not sure if any existing apps/sites rely on there being two newlines. Also in this case, the savings in size would be pretty tiny, only about 14k spread out over all the files.
I could mark italics, yes. At the time that I made the decision not to, I did it to keep things simpler. Italics only seem to be used in parenthesis (ability explanation text) and in flavor text. I didn't view that as important enough to warrant making the the text uglier and a bit more complex.
Dunno if this was the right call or not.
You are the first person to request italics Maybe there are others that would find them useful?
If I were to add them, I'd have to decide what sort of open/close tag system to use. I guess I could just use HTML style text but... dunno.
You can fix the italics with a regex. I actually use this '(\([^)]+\))' and '$1'. This is how can you replace the {T} and {U} with symbols etc...
The card updates (rulings) are released in bulk and usually not only one set changed but all the old prints what's reprinted in that set or all cards with a given ability etc...
Private Mod Note
():
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Someone e-mailed me to let me know that the "Timeshifted" cards from Time Spiral were missing.
It looks like Wizards considers the Timeshifted cards in Time Spiral as a separate subset of cards.
They've given them their own expansion name (Time Spiral "Timeshifted") and code (TSB (instead of TSP for Time Spiral))
I've just updated mtgjson.com with the new set
No problem! I'm glad you find it useful.
Also, thanks for the thank-you, it makes me smile to know that others are finding it useful
I'd kind of like to see gatherer's community ratings on a whim too.
Thanks for this awesome resource!
Hello
I think this is the second or third request I've had for full foreign language text, so when I get back from vacation (early December) (and after I fix some MTGImage issues) I will look seriously into adding foreign language text.
As for the community ratings, I had thought about adding them in the past but decided against it. They feel too "gatherer specific", like that info belongs more to the gatherer social community and less about the card and it didn't feel right just copying it and sticking into the JSON. I try to keep the JSON about just the cards themselves as much as possible. Does that make sense? I dunno, maybe I'm just being silly.
Thanks a lot for the suggestions, I'll reply here once I have some updates to share on the foreign text.
Generally how soon after Gatherer adds new text to the database will it be available on your website? Also, do you keep your github source up-to-date with all the changes you make? Thanks!
I try and add the set the same day that Gatherer gets the set. In the past I've been pretty close to the day it gets added on gatherer, usually about 1 or 2 days after. I'm going to try and get as close to the same day as possible in the future
As for the source, yes, I update it whenever I make changes so it is up to date. (Some day I want to make the source a bit easier to run, right now it's still a bit tricky)
I'm currently working on a small PHP program to convert the json to a ready to go mysql db. It's not 100% yet, but soon I'll finish it. (Updated almost daily or weekly.)
https://github.com/laxika/MTGJsonConverter
Cool! I know a lot of people use MySQL out there
This includes a bunch of assorted promo cards.
Added the 'Vanguard' set along with the 'plane' cards for both Planechase sets and the 'schemes' for the Archenemy set.
Masters Edition
Masters Edition II
Masters Edition III
Masters Edition IV
By the way, is it useful to folks that I post updates here when I update the site? Or is it not useful...
I refresh this thread daily when I'm at work so it's useful for me.
Thanks for the nice comments, I'm glad you find it useful!
I do have one recommendation, though: an attribute for color indicator. I guess you could infer it by "subtracting" the the set of colors in the cost from the "color" attribute, but it might be nice to have. What do you think? (Edit: Actually, I think color indicator only applies to cards that would otherwise be colorless, in which case I guess this wouldn't be as useful.)
Again, this is very useful, thanks for putting it up. Where did you get the raw data from?
Oh yeah, one more thing: at least for my purposes, it would be better if the expansions and the cards were separate entities (i.e., an array of expansions followed by an array of cards.) This way, each card would only have to appear once, and it could have a printings attribute like it does in the "extra" version. Then you could combine the rarities with the printings, like Loxodon Warhammer would have "printings":[{"set":"MRD","rarity":""uncommon"},{"set":"10E","rarity":"rare"}] or something like that.
Obviously that won't be good for the set-only files, but for the full list it would reduce the size by a lot and make parsing it easier (at least for some applications.)
I'm looking forward to the multi-lingual update
Yes, you are correct, this is exactly how it works on MTGJSON. I thought about providing a boolean field for colorIndiactor, but realized that as you mentioned, this can be deduced (if needed) from the colors field vs the casting cost colors. I try not to provide too much 'calculated' data above the base data in order to keep things more straightforward. I hope that makes sense
I see how that could be useful. However I'm trying to keep things as simple as possible, which means not presenting too many different formats of the data. I feel like it's pretty simple for a developer to take the data as is, and then convert it into a format that works better for them. My goal is to provide accurate data, then leave it up to the developers consuming that data to massage it into other formats/layouts.
Fixed! Thanks for reporting it. It was indeed a bug on gatherer.
Just updated the site with zips!
When you update MTGJSON, do you post incremental updates or full updates? In other words, are you saving all of the data from scratch or just adding the newest set release to the previously compiled data?
A thought on AllSets-x.json - in the "printings" array, wouldn't it drastically reduce the file size if you used set codes instead of listing the whole set names? Then in your separate sets.json file you could map the full names to the codes for easy cross reference.
Also, is it intentional that there are two line feeds between abilities? Wouldn't one be sufficient to reduce redundancy / the number of characters in the JSON?
"Enchant artifact\n\nAs long as enchanted artifact isn't a creature, it's an artifact creature with power and toughness each equal to its converted mana cost."
Can you mark italics too? Many cards have italic reminder text, and alternating italic - roman flavor text. It would be useful to have this information.
IE: http://gatherer.wizards.com/Pages/Card/Details.aspx?multiverseid=3758
IE: http://gatherer.wizards.com/Pages/Card/Details.aspx?multiverseid=190165
You also see weird italics with the il-dal creatures, etc, in the flavor text.
When a new set comes out, I add the new set and update any previous sets that contain those cards so their 'printings' field will be correct.
This should ensure the card data is up to date, except for possibly rulings. I'm not sure exactly how often WotC updates rulings so right now rulings only get updated when either a set has a card re-printed (as I re-scrape the old set to ensure the 'printings' field gets updated) or when someone lets me know that rulings are out of date for a card or set.
In fact I just posted an update a few seconds ago that has updated rulings for DGM.
Yes, this is something I should have done from the beginning. It was a bit of a mistake to use the full set names here.
Unfortunately lots of apps/websites out there use this JSON and so I am hesitant to perform any changes that would break apps that use the data in the format it is in now.
I've thought about adding some sort of 'versioning' of the data format, but this would just complicate things and I really want to keep complexity down.
I'm ok with the data being larger from a bandwidth point of view, and if anyone out there wants to use this data but wants the size to be smaller, they can pretty simply convert the set names to codes on their side before they package it up in their app/website.
So for now I plan to just keep it as is.
Yes, this was intentional. When first parsing the data, I used double line feeds to denote different sections of text on the card that had a bit of space between them. I used two because I thought there may be some cards that have a single new line within a section of text, without it being part of a new section of text... if that all make sense.
It turns out that this doesn't happen and thus I could replace all double new lines with just single ones.
Again though, I'm not sure if any existing apps/sites rely on there being two newlines. Also in this case, the savings in size would be pretty tiny, only about 14k spread out over all the files.
I could mark italics, yes. At the time that I made the decision not to, I did it to keep things simpler. Italics only seem to be used in parenthesis (ability explanation text) and in flavor text. I didn't view that as important enough to warrant making the the text uglier and a bit more complex.
Dunno if this was the right call or not.
You are the first person to request italics Maybe there are others that would find them useful?
If I were to add them, I'd have to decide what sort of open/close tag system to use. I guess I could just use HTML style text but... dunno.
You can fix the italics with a regex. I actually use this '(\([^)]+\))' and '$1'. This is how can you replace the {T} and {U} with symbols etc...
The card updates (rulings) are released in bulk and usually not only one set changed but all the old prints what's reprinted in that set or all cards with a given ability etc...