LotR TCG Wiki → Card Sets:  All 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 → Forums:  TLHH CC

 
Cobra Cards Player Community Forum Index
 Forum index » Lord of the Rings TCG » Open Lord of the Rings Discussion
Author Message
NBarden
Posted: Mon Jul 23, 2007 8:16 pm
Joined: 28 Dec 2006 Posts: 5468 Location: I don't know...
Take the code, and type the title of the card right above the link to the appropriate card image. Then, pm it to me.

Oh, and I made an application that generated all this code, I didn’t sit down and type it, as some people think...
Exclamation-Trade With MeExclamation
Popcorn Add the popcorn smiley to your sig, help it achieve world domination.
What if the hokey pokey really IS what its all about? Shocked
As I lay in bed staring at the stars last night, I thought to myself, "where the heck is the ceiling?"
Arrow Spotlight on....Sense of Obligation.
Celebrimbor
Posted: Mon Jul 23, 2007 9:18 pm
Joined: 12 Sep 2006 Posts: 953 Location: UNKNOWN
Ohhh, Nbarden...Thanks, what could we do with it? I mean if I needed the image of a specific card, I’d just type the address in the browser.

But I see for database purposes.

Visual basic did you use?
My Trading List
Popcorn is not gooey like fat, and also not crunchy like potato chips, but crispy like lettuce which makes it a healthy snack. Popcorn
NBarden
Posted: Mon Jul 23, 2007 9:36 pm
Joined: 28 Dec 2006 Posts: 5468 Location: I don't know...
Java. Simple code. Here, let me get it.

Code:
import javax.swing.*;

public class LotRCodeGenerator extends JFrame
{
   public LotRCodeGenerator()
   {
      super();
   }
   public static void main(String[] args)
   {
      String setString = "1"; //set number, this one is for FotR
      String cardString = new String();
      String imgBBC = new String();
      
      for(int card = 1; card <= 365; card++ ) //number of cards in set.
      {
         if (card < 100 && card >= 10)
         {
            cardString = "0" + Integer.toString(card);
         }
         else if ( card < 10)
         {
            cardString = "00" + Integer.toString(card);
         }
         else
         {
            cardString = Integer.toString(card);
         }
         
         imgBBC = "[img]http://lotrtcg.fanhq.com/Resources/CardImages/LOTR-EN" + setString + cardString +".jpg[/img]";
      
         System.out.println(imgBBC);
      }
   }   
}


Simple String construction loop. Took about 2-3 minutes to program. My IDE captures the output an puts it in an easily copyable form.
Last edited by NBarden on Mon Jul 23, 2007 9:42 pm; edited 5 times in totalExclamation-Trade With MeExclamation
Popcorn Add the popcorn smiley to your sig, help it achieve world domination.
What if the hokey pokey really IS what its all about? Shocked
As I lay in bed staring at the stars last night, I thought to myself, "where the heck is the ceiling?"
Arrow Spotlight on....Sense of Obligation.
Celebrimbor
Posted: Mon Jul 23, 2007 9:38 pm
Joined: 12 Sep 2006 Posts: 953 Location: UNKNOWN
OK i gotcha you used in infinitely repeating algorithm to get what you wanted.

GP for your *hard* work.
My Trading List
Popcorn is not gooey like fat, and also not crunchy like potato chips, but crispy like lettuce which makes it a healthy snack. Popcorn
NBarden
Posted: Mon Jul 23, 2007 9:43 pm
Joined: 28 Dec 2006 Posts: 5468 Location: I don't know...
Loops are sweet. Cool

And its not infinite, its a for loop. You familiar with java?

(The *hard* part was copying and pasting the code from the output to the forums. Wink )
Exclamation-Trade With MeExclamation
Popcorn Add the popcorn smiley to your sig, help it achieve world domination.
What if the hokey pokey really IS what its all about? Shocked
As I lay in bed staring at the stars last night, I thought to myself, "where the heck is the ceiling?"
Arrow Spotlight on....Sense of Obligation.
Celebrimbor
Posted: Tue Jul 24, 2007 1:59 pm
Joined: 12 Sep 2006 Posts: 953 Location: UNKNOWN
No, I’m not familiar with java, but with PHP which is almost the same thing.

PHP is a logic, open-sourced database language. Good stuff.
My Trading List
Popcorn is not gooey like fat, and also not crunchy like potato chips, but crispy like lettuce which makes it a healthy snack. Popcorn
MADG0BLIN
Posted: Sun Jul 29, 2007 6:58 am
Joined: 18 May 2007 Posts: 108 Location: The Netherlands, Emmeloord
To bad not all sets are complete. I have a database of my own with all the info, but I’’m missing some cards. Sad
My haves and wants:

Display posts from previous:  

 Forum index » Lord of the Rings TCG » Open Lord of the Rings Discussion
All times are UTC - 4
Page 3 of 3 [27 Posts]   Goto page: Previous 1, 2, 3
View previous topic   View next topic