It is currently 05 Jun 2024, 23:03
   
Text Size

Gatherer Downloader App (v1.6.8) [hq pics / card database]

General Discussion of the Intricacies

Moderator: CCGHQ Admins

Re: Gatherer Downloader App (v1.4.0) [hq pics / card databas

Postby Ark » 24 Jan 2012, 17:44

Yeah, I see at http://gatherer.wizards.com/Pages/Card/ ... eid=150074 they have << instead of « in the flavor text. I can add a work around for that in the next release.

Can you give me an example of the set and which basic land specifically has a problem?
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.0) [hq pics / card databas

Postby skibulk » 24 Jan 2012, 21:05

Duplicates Bug Details:
Ok. Oddly this only occurs in a certain scinario: If I download a set in English with additional info, and then within the same database file download French text with additional info, some English entries are added to the set. For example, in New Phrexia the result is 175 French entries plus 5 English Entries left over: Plains, Island, Swamp, Forest, Mountain. No big deal really.

Suggestion 1:
If I download French, then English, I have a database with 350 entries. Actually, I think it would make since for the foreign text not to override English entries in the database at all. That way, when a user downloads the English cards, and then goes to append foreign cards to the database, they don't destroy the English entries.

Suggesion 2:
Also, say a user wants to download a French Database. Now the application pings wizards.com looking for foreign text on every card in the spoiler. You may be able to cut alot of bandwidth, processing, and time out of the picture by checking say, the last entry(or few entries) for the existence of said foreign text. If none, skip processing the rest of the set. As far as I can tell, wizards either has all of the translations for a set or none.

Suggestion 3, Low Priority:
I like how you setup an on/off checkmark next to Options > Additional Card Info. This could be implemented with the languages too, such that all the languages could be checked and downloaded in one pass by the app.

Thanks for reading, use whatever you want of my suggestions.
User avatar
skibulk
HQ Team Member
 
Posts: 995
Joined: 19 Jul 2010, 20:34
Location: Northeast USA
Has thanked: 379 times
Been thanked: 335 times

Re: Gatherer Downloader App (v1.4.0) [hq pics / card databas

Postby Ark » 25 Jan 2012, 03:47

I think all of this is by design. I went with the assumption that most people only care about their primary language (and you get English for free no matter what with any language setting anyway).

If you want multiple languages, you can do it safely by always doing English last. The reason for this is that the ID column is the unique identifier for the card, and downloading any other language requires fetching the spoiler in English first, because of limitations with Gatherer's design.

When you download English first, then French, the first pass of getting the French information will overwrite many of the existing English IDs. Basically everything but 3 of each basic land. Anything else with multiple versions will be affected the same too. Doing French then English for Tenth Edition gets you 766 total rows, while doing English then French leaves you with only 398 rows. There are 383 cards in the set. 383 + 15 = 398, which is 3x 5 basic lands.

I also think that having the program make assumptions and skip entire sets could be bad if wizards does get partial translations of anything in the future for whatever reason. I'd rather the program be complete and thorough than accidentally miss something.
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.0) [hq pics / card databas

Postby skibulk » 26 Jan 2012, 00:12

Thanks for explaining, it makes since by that logic. Then I guess I'd just be interested in the option to download multiple languages at once.
User avatar
skibulk
HQ Team Member
 
Posts: 995
Joined: 19 Jul 2010, 20:34
Location: Northeast USA
Has thanked: 379 times
Been thanked: 335 times

Re: Gatherer Downloader App (v1.4.1) [hq pics / card databas

Postby Ark » 27 Jan 2012, 16:52

v1.4.1 posted at http://ark42.com/mtg/progs/GathererDownloader-1.4.1.zip with up to Dark Ascension added to the default set list, and a work-around for the French flavor text problem.
Also updated the posted card databases (All sets, in English, with Additional Information already downloaded) at http://ark42.com/mtg/MTGCardInfo/ with Dark Ascension data now.
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.1) [hq pics / card databas

Postby woogerboy21 » 30 Jan 2012, 15:28

I noticed that the default set list does not include the "Premium Deck Series: Graveborn". Is this a whoops or was this for a reason?
User avatar
woogerboy21
HQ Team Member
 
Posts: 1136
Joined: 19 Jul 2009, 00:15
Location: USA
Has thanked: 21 times
Been thanked: 152 times

Re: Gatherer Downloader App (v1.4.1) [hq pics / card databas

Postby Ark » 30 Jan 2012, 16:10

Guess I missed it. I never buy those things, since you can't play Standard with any of the cards..
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.2) [hq pics / card databas

Postby Ark » 30 Jan 2012, 16:17

v1.4.2 posted at http://ark42.com/mtg/progs/GathererDownloader-1.4.2.zip
Added this line to the default sets list:
Special Sets,PD3,Premium Deck Series: Graveborn,,Premium Deck Series - Graveborn
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.2) [hq pics / card databas

Postby skibulk » 26 Feb 2012, 16:23

Hi Ark,

Gather Downloader 1.4.2 isn't extracting Simplified Chinese rules / flavor test at all. (Darksteel and forward) I haven't checked previous versions.
User avatar
skibulk
HQ Team Member
 
Posts: 995
Joined: 19 Jul 2010, 20:34
Location: Northeast USA
Has thanked: 379 times
Been thanked: 335 times

Re: Gatherer Downloader App (v1.4.2) [hq pics / card databas

Postby Ark » 26 Feb 2012, 16:56

On the language page on wizard's site like at http://gatherer.wizards.com/Pages/Card/ ... eid=143618 did they always say "Chinese Simplified" ?? because in my list of text for languages to look for, I have "Chinese Standard" and it's not being found now. I'm pretty sure that Simplified is the official standard, and what all kinds of non-MTG things would have used, and Wizard's was using a weird label of Standard instead in the past. I need to check more card language list pages to see if Wizard's is consistent. If they're using "Simplified" everywhere, I can just make the one change in my program and it will find it.
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times


Re: Gatherer Downloader App (v1.4.3) [hq pics / card databas

Postby Ark » 27 Feb 2012, 05:21

v1.4.3 posted at http://ark42.com/mtg/progs/GathererDownloader-1.4.3.zip
Fixed fetching Simplified Chinese text.
User avatar
Ark
Programmer
 
Posts: 350
Joined: 16 Jul 2008, 04:29
Has thanked: 10 times
Been thanked: 103 times

Re: Gatherer Downloader App (v1.4.3) [hq pics / card databas

Postby skibulk » 28 Feb 2012, 15:48

Here's a simple PHP script which checks the first card in each set on Gatherer for new translations (If they ever add any after today, 28 Feb 2012).

Code: Select all
<?php
set_time_limit(180); // 3 minutes

$array_pages = array(
   94      => array(0,0,0,0,0,0,0,0,0,0), // A  - Air Elemental
   389    => array(0,0,0,0,0,0,0,0,0,0), // B  - Air Elemental
   691    => array(0,0,0,0,0,0,0,0,0,0), // U  - Air Elemental
   1189   => array(0,0,0,0,0,0,0,0,0,0), // R  - Air Elemental
   968      => array(0,0,0,0,0,0,0,0,0,0), // AN - Abu Ja'far
   992      => array(0,0,0,0,0,0,0,0,0,0), // AQ - Amulet of Kroog
   1427   => array(0,0,0,0,0,0,0,0,0,0), // LG - Abomination
   1746   => array(0,0,0,0,0,0,0,0,0,0), // DK - Amnesia
   1827   => array(0,0,0,0,0,0,0,0,0,0), // FE - Aeolipile

   2084   => array(0,0,0,0,0,0,0,0,0,0), // 4E - Abomination
   2437   => array(0,0,0,0,0,0,0,0,0,0), // IA - Abyssal Specter
   2838   => array(0,0,0,0,0,0,0,0,0,0), // CH - Abu Ja'far
   3010   => array(0,0,0,0,0,0,0,0,0,0), // HL - Abbey Gargoyles
   3041   => array(0,0,0,0,0,0,0,0,0,0), // AL - Aesthir Glider
   3272   => array(0,0,0,0,0,0,0,0,0,0), // MI - Abyssal Hunter
   3608   => array(0,0,0,0,0,0,0,0,0,0), // VI - Aku Djinn

   4098   => array(0,0,0,0,0,0,0,0,0,0), // 5E - Abbey Gargoyles
   4369   => array(0,0,0,0,0,0,0,0,0,0), // P1 - Alabaster Dragon
   4476   => array(0,0,0,0,0,0,0,0,0,0), // WL - Abduction
   4635   => array(0,0,0,0,0,0,0,0,0,0), // TE - Abandon Hope
   5108   => array(0,0,0,0,0,0,0,0,0,0), // SH - Acidic Sliver
   6071   => array(0,0,0,0,0,0,0,0,0,0), // EX - Æther Tide
   6567   => array(0,0,0,0,0,0,0,0,0,0), // P2 - Abyssal Nightstalker
   9769   => array(0,0,0,0,0,0,0,0,0,0), // UG - Ashnod's Coupon
   5716   => array(0,0,0,0,0,0,0,0,0,0), // US - Absolute Grace
   12414   => array(0,0,0,0,0,0,0,0,0,0), // UL - About Face

   14526   => array(0,0,0,0,0,0,0,0,0,0), // 6E - Abduction
   15138   => array(0,0,0,0,0,0,0,0,0,0), // UD - Academy Rector
   10487   => array(0,0,0,0,0,0,0,0,0,0), // P3 - Alert Shu Infantry
   21019   => array(0,0,0,0,0,0,0,0,0,0), // S1 - Abyssal Horror
   19667   => array(0,0,0,0,0,0,0,0,0,0), // MM - Aerial Caravan
   21167   => array(0,0,0,0,0,0,0,0,0,0), // BR - Abyssal Specter
   21285   => array(0,0,0,0,0,0,0,0,0,0), // NE - Accumulated Knowledge
   25456   => array(0,0,0,0,0,0,0,0,0,0), // S2 - Angelic Blessing
   24561   => array(0,0,0,0,0,0,0,0,0,0), // PR - Abolish
   23155   => array(1,1,0,0,0,0,0,0,0,0), // IN - Absorb
   26654   => array(0,0,0,0,0,0,0,0,0,0), // BD - Air Elemental
   26383   => array(1,1,0,0,0,0,0,0,0,0), // PS - Allied Strategies

   13111   => array(1,1,1,0,0,0,0,0,0,0), // 7E - Abyssal Horror
   25856   => array(1,1,1,0,0,0,0,0,0,0), // AP - Ana Disciple
   31761   => array(1,1,1,1,1,0,0,0,0,0), // OD - Abandoned Outpost
   29857   => array(1,1,1,1,1,0,0,0,0,0), // TO - Accelerate
   34243   => array(1,1,1,1,1,0,0,0,0,0), // JU - Ancestor's Chosen
   26715   => array(1,1,1,1,1,0,0,0,0,0), // ON - Accursed Centaur
   44747   => array(1,1,1,1,1,0,0,0,0,0), // LE - Akroma's Devoted
   43539   => array(1,1,1,1,1,0,0,0,0,0), // SC - Accelerated Mutation

   45307   => array(1,1,1,1,1,0,0,0,0,0), // 8E  - Abyssal Specter
   49045   => array(1,1,1,1,1,1,0,0,0,0), // MR  - Alpha Myr
   49075   => array(1,1,1,1,1,1,0,1,0,0), // DS  - Aether Snap
   50164   => array(1,1,1,1,1,1,0,1,0,0), // FD  - Abuna's Chant
   75277   => array(1,1,1,1,1,1,0,1,0,0), // CHK - Akki Avalanchers
   73935   => array(1,0,0,0,0,0,0,0,0,0), // UNH - "Ach! Hans, Run!"
   74428   => array(1,1,1,1,1,1,0,1,0,0), // BOK - Akki Blizzard-Herder
   74187   => array(1,1,1,1,1,1,0,1,0,0), // SOK - Adamaro, First to Desire

   84635   => array(1,1,1,1,1,1,0,1,0,1), // 9E  - Adarkar Wastes
   89101   => array(1,1,1,1,1,1,0,1,0,1), // RAV - Agrus Kos, Wojek Veteran
   96953   => array(1,1,1,1,1,1,0,1,0,1), // GP  - Absolver Thrull
   111192   => array(1,1,1,1,1,1,0,1,0,1), // DIS - AEthermage's Touch
   121196   => array(1,1,1,1,1,1,0,1,0,1), // CS  - Adarkar Valkyrie
   116725   => array(1,1,1,1,1,1,0,1,0,1), // TSP - Academy Ruins
   106645   => array(1,1,1,1,1,1,0,1,0,1), // TSB - Akroma, Angel of Wrath
   122449   => array(1,1,1,1,1,1,0,1,0,1), // PCH - Aeon Chronicler
   136150   => array(1,1,1,1,1,1,0,1,0,1), // FUT - Akroma's Memorial

   130483   => array(1,1,1,1,1,1,1,1,0,1), // 10E - Abundance
   145992   => array(1,1,1,1,1,1,1,1,0,1), // LRW - Adder-Staff Boggart
   159328   => array(0,0,0,0,0,0,0,0,0,0), // EVG - Akki Coalflinger
   152998   => array(1,1,1,1,1,1,1,1,0,1), // MOR - Ambassador Oak
   154408   => array(1,1,1,1,1,1,1,1,0,1), // SHM - Advice from the Fae
   153427   => array(1,1,1,1,1,1,0,1,0,1), // EVE - Aerie Ouphes
   178014   => array(0,0,0,0,0,0,0,0,0,0), // DRG - Bladewing the Risen
   174915   => array(1,1,1,1,1,1,0,1,0,1), // SHA - Ad Nauseam
   189223   => array(0,0,0,0,0,1,0,0,0,0), // JVC - Air Elemental
   179513   => array(1,1,1,1,1,1,0,1,0,1), // CFX - Absorb Vis
   179538   => array(1,1,1,1,1,1,0,1,0,1), // ARB - Anathemancer

   189880   => array(1,1,1,1,1,1,0,1,0,1), // M10 - Acidic Slime
   194966   => array(0,0,0,0,0,0,0,0,0,0), // EXL - Balance
   198073   => array(1,1,1,1,0,1,0,0,0,0), // PLC - Academy at Tolaria West
   178135   => array(1,1,1,1,1,1,0,1,0,1), // ZEN - Adventuring Gear
   201781   => array(0,0,0,0,0,0,0,0,0,0), // GVL - Albino Troll
   207897   => array(0,0,0,0,0,0,0,0,0,0), // SLI - Acidic Sliver
   197869   => array(1,1,1,1,1,1,0,1,0,1), // WWK - Abyssal Persecutor
   209148   => array(0,0,0,0,0,1,0,0,0,0), // PVC - Allied Strategies
   198305   => array(1,1,1,1,1,1,0,1,0,1), // ROE - Affa Guard Hound
   220525   => array(0,0,0,0,0,0,0,0,0,0), // ARC - Æther Spellbomb

   207333   => array(1,1,1,1,1,1,1,1,0,1), // M11 - Acidic Slime
   212636   => array(0,0,0,0,0,0,0,0,0,0), // REL - Black Vise
   159328   => array(0,0,0,0,0,0,0,0,0,0), // EVT - Akki Coalflinger
   194371   => array(1,1,1,1,1,1,1,1,0,1), // SOM - Abuna Acolyte
   234722   => array(0,0,0,0,0,0,0,0,0,0), // FAL - Ball Lightning
   213818   => array(1,1,1,1,1,1,1,1,0,1), // MBS - Accorder Paladin
   243435   => array(1,1,1,1,0,1,0,0,0,0), // KVD - Alaborn Cavalier
   230076   => array(1,1,1,1,1,1,1,1,0,1), // NPH - Act of Aggression

   226906   => array(1,1,1,1,1,1,1,1,0,1), // M12 - Acidic Slime
   244670   => array(0,0,0,0,0,0,0,0,0,0), // LEG - Cao Cao, Lord of Wei
   249411   => array(1,1,1,1,0,0,0,0,0,0), // AVB - Ageless Entity
   222911   => array(1,1,1,1,1,1,1,1,0,1), // ISD - Abattoir Ghoul
   265167   => array(0,0,0,0,0,0,0,0,0,0), // GVB - Animate Dead
   262675   => array(1,1,1,1,1,1,1,1,1,1), // DKA - Afflicted Deserter
);

$array_search = array(
   "French",
   "German",
   "Italian",
   "Spanish",
   "Portuguese",
   "Japanese",
   "Chinese Traditional",
   "Chinese Simplified",
   "Korean",
   "Russian",
);

foreach ($array_pages as $id=>$array_lang) {
   $url = "http://gatherer.wizards.com/Pages/Card/Languages.aspx?multiverseid=$id";
   $html = file_get_contents($url);
   foreach ($array_search as $i=>$search) {
      $expected = $array_lang[$i];
      $actual = (bool) strpos($html, $search);
      if ($expected != $actual) {
         print "An unexpected $search translation was found! <a href=$url>View language page.</a><br />";
      }
   }
   sleep(.5);
}

Print 'Script Completed<br />';
?>
User avatar
skibulk
HQ Team Member
 
Posts: 995
Joined: 19 Jul 2010, 20:34
Location: Northeast USA
Has thanked: 379 times
Been thanked: 335 times

Re: Gatherer Downloader App (v1.4.3) [hq pics / card databas

Postby delslow » 12 Mar 2012, 20:55

Great app!

I've been dabbling with gigantic collages... I was wondering if this program can download specific "cropped" only pictures from some sort of ordered list or link?

i.e. I create some elaborate gatherer search (only black legendary creatures) and copy/paste the link into the app and have it download it specifically.
delslow
 
Posts: 1
Joined: 12 Mar 2012, 20:52
Has thanked: 0 time
Been thanked: 0 time

Re: Gatherer Downloader App (v1.4.3) [hq pics / card databas

Postby skibulk » 13 Mar 2012, 17:19

Wizards added their first Korean text with Dark Ascension! Could you add Korean to the language menu please? Also, Don't forget to add Dark Ascension to the set list:
Code: Select all
Expansions,DKA,Dark Ascension
User avatar
skibulk
HQ Team Member
 
Posts: 995
Joined: 19 Jul 2010, 20:34
Location: Northeast USA
Has thanked: 379 times
Been thanked: 335 times

PreviousNext

Return to Magic Rules Engine Programming

Who is online

Users browsing this forum: No registered users and 4 guests


Who is online

In total there are 4 users online :: 0 registered, 0 hidden and 4 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 4 guests

Login Form