Page 1 of 1

Drafting with Manalink 2.0

PostPosted: 02 Apr 2009, 17:52
by jatill
Today I believe I've written my best 385 lines of code ever. For these 385 lines of code enable you to draft using the manalink software.

Requirements:
>Perl must be installed on your machine (free download at http://www.activestate.com/activeperl/ or http://www.softpedia.com/get/Authoring- ... lBox.shtml
>You must have Internet Explorer with ActiveX enabled.

Instructions:
>Download the draft script: http://www.savefile.com/files/2063805 and put the .pl file into c:\magic\draft
>From the command line, run 'perl c:\magic\draft\draft.pl'
>Open the .html file that the script tells you in Internet Explorer. Make sure ActiveX is enabled (in your internet settings). The browser may give you a warning, so just allow blocked content. (it complains because the html writes a cookie file to your computer)
>Do the drafting, and then play out the games using Duel mode in Manalink. Your deck is Draft.dck, and your opponents are Draft Opponent 1-7 (score).dck.

This should be considered in BETA mode for now, until the kinks are worked out. Please post questions and bugs here, and most importantly, let me know if you get this running successfully.

Hopefully someone with some GUI programming experience can take this from HTML into a real application. Also, it would be great if someone figured out how the AI builds decks in Sealed. I wrote my own deck generation routine, which is not very advanced right now.

Re: Drafting with Manalink 2.0

PostPosted: 02 Apr 2009, 21:12
by Bog Wraith
This is a very cool idea and I will look into it this weekend or next week.

I know this is a bit off topic, but really, this could apply to this app you created.

Has ANYONE gotten two computers either through a LAN or whatever to actually work and get a game going!. I've tried for what seems like forever and I can't. This drafting module and of course both Sealed and Constructed play would be awesome if we could play vs live opponents as well.

If not, is there anyone who can figure out how to achieve this? [-o<

Re: Drafting with Manalink 2.0

PostPosted: 03 Apr 2009, 12:41
by jatill
Edit: small changes - remove ante cards, etc

Re: Drafting with Manalink 2.0

PostPosted: 04 Apr 2009, 04:13
by Rockman
It let me pick a card from the two first booster, then the explorer don't found C:\Magic\draft\draft2.html. That file is not in the folder, only appear draft0 and 1.

Also this shows up in the command line: "Use of uninitialized value $current_time in numeric ne (!=) at c:\magic\draft\draft.pl line 243."

Re: Drafting with Manalink 2.0

PostPosted: 04 Apr 2009, 13:01
by jatill
Rockman wrote:It let me pick a card from the two first booster, then the explorer don't found C:\Magic\draft\draft2.html. That file is not in the folder, only appear draft0 and 1.

Also this shows up in the command line: "Use of uninitialized value $current_time in numeric ne (!=) at c:\magic\draft\draft.pl line 243."
You need to do the whole 'allow access to activeX' thing in IE. If your settings are correct, there will be a draft.txt in c:\magic\draft after you make your first pick. If you open it, it should have the id of your pick.

Re: Drafting with Manalink 2.0

PostPosted: 17 Apr 2009, 03:38
by Rockman
jatill wrote:
Rockman wrote:It let me pick a card from the two first booster, then the explorer don't found C:\Magic\draft\draft2.html. That file is not in the folder, only appear draft0 and 1.

Also this shows up in the command line: "Use of uninitialized value $current_time in numeric ne (!=) at c:\magic\draft\draft.pl line 243."
You need to do the whole 'allow access to activeX' thing in IE. If your settings are correct, there will be a draft.txt in c:\magic\draft after you make your first pick. If you open it, it should have the id of your pick.
I enabled absolute everything in IE just in case, and keep getting the same error. I get the draft.txt, just is always empty -even if I do the first two picks-, and the program never generates draft2.html, justo draft0 and draft 1 (the first two boosters).

Re: Drafting with Manalink 2.0

PostPosted: 15 Sep 2010, 10:35
by STARPOWER
Does this still exist/did it ever work? the savefile.com link doesnt seem to link to a file.

Re: Drafting with Manalink 2.0

PostPosted: 15 Sep 2010, 11:57
by jatill
STARPOWER wrote:Does this still exist/did it ever work? the savefile.com link doesnt seem to link to a file.
Drafting is now built in to the most recent version.
http://www.slightlymagic.net/wiki/Drafting