It is currently 05 Nov 2025, 18:43
   
Text Size

Pricing (Scripts and Notes)

Moderators: charmer, CCGHQ Admins

Re: Card Pricing

Postby woogerboy21 » 10 Jun 2010, 03:40

Alright so after I dont know how long, btw did I mention how much I dislike lua's patterns ](*,) , here is another script for the http://www.tcgplayers.com site. Currently this script only detects the "high" value of the card(s). I may work in either mid or low prices but for now this is it :)
Attachments
TCGPlayer.zip
(2.3 KiB) Downloaded 775 times
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: Card Pricing

Postby kristijanH » 12 Jul 2010, 17:51

How do I make other prices available? I copied the csv's and lua files to prices but when I try to update the prices nothing happens: I have TCG player, MTG Fanatic and ABU games.
kristijanH
 
Posts: 218
Joined: 24 Nov 2009, 13:49
Has thanked: 52 times
Been thanked: 11 times

Re: Card Pricing

Postby Goblin Hero » 12 Jul 2010, 18:36

Put .lua into Prices folder, restart the program, go to Price-Manage, select price, press update.
When you´re a goblin, you don´t have to step forward to be a hero -- everyone else just has to step back.
User avatar
Goblin Hero
Site Admin
Site Admin
 
Posts: 1996
Joined: 23 Oct 2005, 09:37
Location: Russia
Has thanked: 237 times
Been thanked: 353 times

Re: Card Pricing

Postby kristijanH » 12 Jul 2010, 19:21

Looks like it's working. I just got inpatient. How long does it last to fully update? 10min? 30 min? More?

Edit: I use MA on 2 computers. Can I just copy the csv files so I don't have to download it twice?
kristijanH
 
Posts: 218
Joined: 24 Nov 2009, 13:49
Has thanked: 52 times
Been thanked: 11 times

Re: Card Pricing

Postby Goblin Hero » 12 Jul 2010, 19:30

kristijanH wrote:long does it last to fully update?
Depends on your internet speed.
kristijanH wrote:Edit: I use MA on 2 computers. Can I just copy the csv files so I don't have to download it twice?
Yes.
When you´re a goblin, you don´t have to step forward to be a hero -- everyone else just has to step back.
User avatar
Goblin Hero
Site Admin
Site Admin
 
Posts: 1996
Joined: 23 Oct 2005, 09:37
Location: Russia
Has thanked: 237 times
Been thanked: 353 times

Re: Card Pricing

Postby woogerboy21 » 15 Jul 2010, 02:21

Hey Goblin Hero, has anything changed in the 1.1.1 release in regards to the card names or card name formating in the database? The reason I ask is it looks like all the pricing scripts now fail to add a price to any card with a quotation mark in its name (such as angel's feather). It worked in previous versions and I know I haven't changed any code in any of the pricing scripts I have been working with.
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: Card Pricing

Postby Goblin Hero » 15 Jul 2010, 08:26

woogerboy21 wrote:has anything changed in the 1.1.1 release in regards to the card names or card name formating in the database?
Yes. Redownload update package again - I've made the fixes.
When you´re a goblin, you don´t have to step forward to be a hero -- everyone else just has to step back.
User avatar
Goblin Hero
Site Admin
Site Admin
 
Posts: 1996
Joined: 23 Oct 2005, 09:37
Location: Russia
Has thanked: 237 times
Been thanked: 353 times

Re: Card Pricing

Postby rjp14 » 20 Jul 2010, 18:40

Could anyone please do card pricing scripts for the following sites:

gamingetc.com
channelfireball.com
http://www.oldschoolgaming.net

This would be greatly appreciated as I find these sites to be some of the most price point competitive.

Thanks in advance
rjp14
 
Posts: 67
Joined: 13 Jul 2010, 03:34
Has thanked: 0 time
Been thanked: 0 time

Re: Card Pricing

Postby woogerboy21 » 20 Jul 2010, 22:24

rjp14 wrote:Could anyone please do card pricing scripts for the following sites:

gamingetc.com
channelfireball.com
http://www.oldschoolgaming.net

This would be greatly appreciated as I find these sites to be some of the most price point competitive.

Thanks in advance
Looks like the HTML responses from those sites are parseable. If anyone else wants to pitch in feel free to. If not I will add it to the list of things to do. (sorry backed up at the moment with other priorities)
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: Card Pricing

Postby woogerboy21 » 26 Jul 2010, 03:35

Every time I work on a pricing script its like I have to relearn lua's pattern matching functionality (guess thats what happens when you dont typically use something.)

A recent online trade caused me to throw together a script for starcitygames. Attached is the (messy but functional) file. I have the groundwork laid out for the set structure but have not populated each set id to there database. It only has the M10 and beyond set's configured. If you want the rest feel free to populate it or wait till I get around to doing it.

Also I still am working on the other pricing script requests, I haven't forgot :)
Attachments
StarCityGames.zip
(2.25 KiB) Downloaded 699 times
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: Card Pricing

Postby rjp14 » 26 Jul 2010, 17:54

I updated two of the pricing scripts to grab the info for M11. I have attached them below.
Attachments
MTGFanatic.rar
MTGFanactic M11
(2.3 KiB) Downloaded 507 times
ABUGames.rar
ABUgames M11
(2.37 KiB) Downloaded 510 times
rjp14
 
Posts: 67
Joined: 13 Jul 2010, 03:34
Has thanked: 0 time
Been thanked: 0 time

Re: Card Pricing

Postby woogerboy21 » 26 Jul 2010, 19:02

rjp14 wrote:I updated two of the pricing scripts to grab the info for M11. I have attached them below.
Thanks. I had them updated locally just hadn't got around to posting them. Wouldn't happen to want to work on the starcitygames pricing script would you? Its functional just needs the structure updated to include all the url information for each set on there site. I got it working last night and posted it but moved on to the 3 sites you had requested. Which I have collecting data and identifying card names and prices. I'm having trouble getting the pattern matching working for the blocks of data that contains both name and price for those 3 sites for some reason. They all look like they use the same exact backend database / html format. I'll figure it out, just doesnt seem to be liking the patterns I thought would work. :D
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: Card Pricing

Postby woogerboy21 » 26 Jul 2010, 20:27

Alright Goblin Hero. I am stumped and could use some help from someone that might have more lua experience than I once again. :( I've been working on this pattern all day and just cant figure out why its not finding it. Here is the code:

Code: Select all
<tr id="product_40544" class="odd">
 
 
 
  <td valign="top">
   
      <a id="thumb40544" href="http://hive.crystalcommerce.com/photo/file/2018/344515/large/Act_of_Treason.jpg" class="highslide thumbnail" onclick="return hs.expand(this)"><img src="http://hive.crystalcommerce.com/photo/file/2018/344515/thumb/Act_of_Treason.jpg" title="Click to enlarge" /></a>
      <div class="highslide-caption product_controls" id="caption-for-thumb40544">
        Use arrow keys to navigate.<br />
        <a href="/catalog/magic_singles-core_sets-magic_2011_/act_of_treason/40544">View Details</a>
      </div>
   
  </td>
 
  <td width="100%" valign="top">
    <a href="/catalog/magic_singles-core_sets-magic_2011_/act_of_treason/40544">Act of Treason</a><br />
   
      <span style='font-size:84%'>
     
       
          <strong>Rarity</strong>: <a href='/catalog/magic_singles-core_sets-magic_2011_/280?filter[8]=U'>U</a>
          |
         
       
     
       
          <strong>Color</strong>: <a href='/catalog/magic_singles-core_sets-magic_2011_/280?filter[5]=Red'>Red</a>
         
       
     
      </span>
   
    <table class="invisible-table" width="100%">
     
       
          <tr id="variant_355212" class="variantRow">
            <td class="variantInfo" width="47%">Condition: English | Unplayed</td>
            <td align="right" width="13%">$0.03</td>
            <td align="right" width="10%">x 82</td>
            <td align="right" width="30%"><form action="/cart/add/40544?vid=355212" method="GET" onsubmit="new Ajax.Request('/cart/add/40544?vid=355212', {asynchronous:true, evalScripts:true, method:'get', parameters:Form.serialize(this)});return false;"><input id="item_40544_355212_qty" name="qty" size="1" tabindex="2" type="text" value="0" /><a href="#" onclick="add_amount_to_field($('item_40544_355212_qty'),1); return false"><img src="/images/icons/16x16/shadow/add.png" class="plus_button"></a><input class="add_to_cart catalog" name="commit" type="submit" value="Add to Cart" /></form></td>
          </tr>
       
     
    </table>
  </td>
</tr>
What pattern would you use to identify the name and price of from this block of html response? If I use single line patterns such as ">([%w,-:/' ]+)</a><br />" for the name it finds what I am looking for or ">$([\.%d]+)</td>" for the price it finds that as well but when I try and put them into a patter such as ">([%w,-:/' ]+)</a><br />->$([\.%d]+)</td>" it finds nothing.
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: Card Pricing

Postby rjp14 » 26 Jul 2010, 20:43

I'll see if I can't figure it out and update it.
rjp14
 
Posts: 67
Joined: 13 Jul 2010, 03:34
Has thanked: 0 time
Been thanked: 0 time

Re: Card Pricing

Postby woogerboy21 » 26 Jul 2010, 22:46

Alright I give up ... I f'n hate lua (or maybe its my lack of knowledge). So I read and read and read and read and I have a simple line of:

Code: Select all
<td align="right" width="13%">$0.04</td>
What do you think the pattern would be? I have no idea. It seems that when I try and break the % character in the string like the LUA documentation says all it does is crash the magic album applicatoin. Example: "[<%w =]+.right.[ %w=]+.%d%d%%" ... crash... :oops:

Or how about "<td align=.right. width=.13%%.>$0.04</td>" ... crash! :oops:

/ragequit!
User avatar
woogerboy21
HQ Team Member
 
Posts: 1136
Joined: 19 Jul 2009, 00:15
Location: USA
Has thanked: 21 times
Been thanked: 152 times

PreviousNext

Return to Magic Album

Who is online

Users browsing this forum: No registered users and 11 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 11 users online :: 0 registered, 0 hidden and 11 guests (based on users active over the past 10 minutes)
Most users ever online was 9298 on 10 Oct 2025, 12:54

Users browsing this forum: No registered users and 11 guests

Login Form