Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 23 of 23

Thread: Help Generating a level

  1. #1
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Question Help Generating a level [SOLVED]

    Hey Everyone

    So I am basically creating a simple 2D game which will consist of a maze/level. I need to print out multiple images without having to print out the same line hundreds of times within different 2D coordinates. The only problem is I have no idea what else i need in my program to do this. I want to print an image wherever I have a '#' in my maze class. Something like this:

    private String level =
    	            "####################################\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"####################################\n";

    So Wherever there is a blank space, nothing is printed. '\n' starts a new line of the maze and the '#' prints out my cobblestone image.
    I will give you the code to my current executable program:

    package outrun;
     
    import java.awt.Image;
    import java.awt.event.KeyEvent;
     
    import javax.swing.ImageIcon;
     
    public class Person {
     
    	private String person = "/images/person.png";
     
    	private int dx;
    	private int dy;
    	private int x;
    	private int y;
     
    	private Image image;
     
    	public Person() {
    		ImageIcon i = new ImageIcon(this.getClass().getResource(person));
    		image = i.getImage();
     
    		x = 10;
    	    y = 10;	
    	}
     
    	public void move() {
    		x += dx;
    		y += dy;
    	}
     
        public int getX() {
        	return x;
        }
     
        public int getY() {
        	return y;
     
        }
     
        public Image getImage() {
        	return image;
        }
     
        public void KeyPressed(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 1;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = -1;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = -1;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 1;
            }
        }
     
        public void KeyReleased(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 0;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = 0;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = 0;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 0;
            }
        }
    }

    That is the person class.

    package outrun;
     
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import java.awt.Color;
    import java.awt.Toolkit;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.awt.event.KeyAdapter;
    import java.awt.event.KeyEvent;
     
    import javax.swing.JPanel;
    import javax.swing.Timer;
     
    public class Board extends JPanel implements ActionListener {
     
    private String maze =
    			"####################################\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"#                                  #\n"
    		   +"####################################\n";
    	private Timer timer;
    	private Person person;
     
    	public Board() {
     
    		addKeyListener(new TAdapter());
    		setFocusable(true);
    		setBackground(Color.BLACK);
    		setDoubleBuffered(true);
     
    		setSize(600, 400);
     
    		person = new Person();
    		timer = new Timer(5, this);
            timer.start();
    	}
     
    	public void paint(Graphics g) {
        	super.paint(g);
     
        	Graphics2D m = (Graphics2D)g;
        	m.drawImage(person.getImage(), person.getX(), person.getY(), this);
     
        	Toolkit.getDefaultToolkit().sync();
        	g.dispose();
        }
     
        public void actionPerformed(ActionEvent e) {
        	person.move();
        	repaint();
        }
     
        private class TAdapter extends KeyAdapter {
     
        	public void keyReleased(KeyEvent e) {
        		person.KeyReleased(e);
        	}
     
        public void keyPressed(KeyEvent e) {
        	person.KeyPressed(e);
        }
        }
    }

    That is the Board Class.

    package outrun;
     
    import javax.swing.JFrame;
     
    public class Outrun extends JFrame {
     
    	public Outrun() {
    		add(new Board());
    		setTitle("Outrun");
    		setDefaultCloseOperation(EXIT_ON_CLOSE);
    		setSize(600, 400);
    		setResizable(false);
    		setVisible(true);
    		setLocationRelativeTo(null);
    	}
    	public static void main(String[] args) {
    		new Outrun();
    	}
     
    }

    That is the Outrun Class (Outrun being the name of the game).

    This is the Cobblestone Image I will be using:
    Cobblestone.png

    Any help given would be appreciated. Thanks!
    Last edited by Montario; April 12th, 2012 at 07:26 AM.


  2. #2
    Forum VIP
    Join Date
    Jul 2010
    Posts
    1,676
    Thanks
    25
    Thanked 329 Times in 305 Posts

    Default Re: Help Generating a level

    loop it. Based on your code, you already know how to paint an image, so the only hurdle you have is looping it. To do this, you will need to know the size of the image (height and width) and the pattern you will use. Then create a loop of some kind where you increment the X and Y coordinates of each image.

    For example, let's say the cobblestone image had a height of 10 pixels and a width of 10 pixels, and we wanted to make a 3x3 box out of them with nothing in the middle. We can do that using the following code (in the Board class):
    //Assume: the variable: "image" is the cobblestone.png and the variable: "g2" is a Graphics2D object. "maxX" and "maxY" are both 3 cobblestone images, so 3*10+1=31
    for(int x=0;x<maxX;x+=10)
    {
         for(int y=0;y<maxY;y+=10)
         {
              if(x!=10 && y!=10)
                   g2.drawImage(image,x,y,this);
         }
    }
    NOTE: I have NOT compiled or ran the code. This may not be an "exact" solution, but merely one that proves the general concept I was explaining.
    NOTE TO NEW PEOPLE LOOKING FOR HELP ON FORUM:

    When asking for help, please follow these guidelines to receive better and more prompt help:
    1. Put your code in Java Tags. To do this, put [highlight=java] before your code and [/highlight] after your code.
    2. Give full details of errors and provide us with as much information about the situation as possible.
    3. Give us an example of what the output should look like when done correctly.

    Join the Airline Management Simulation Game to manage your own airline against other users in a virtual recreation of the United States Airline Industry. For more details, visit: http://airlinegame.orgfree.com/

  3. The Following User Says Thank You to aussiemcgr For This Useful Post:

    Montario (April 10th, 2012)

  4. #3
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Thanks so much for your reply aussiemcgr, I have a greater understanding of what I need to do. I still do not understand however what 'maxX' and 'maxY' are representing exactly. Please can you expand on them? (I'm still quite new to java 2D programming). Or mabye if it is not too much, could you show me a working example of how the for loop can produce multiple identical images like you are saying? It would be MUCH easier for me to grasp. Thanks!

  5. #4
    Junior Member
    Join Date
    Apr 2012
    Location
    Missouri, United States
    Posts
    17
    Thanks
    4
    Thanked 2 Times in 2 Posts

    Default Re: Help Generating a level

    Here is another example, similar to aussiemcgr's example:
    public void paint(Graphics g) {
        	.........
            drawMaze((Graphics2D) g);
        	.........
    }
    private void drawMaze(Graphics2D g){
            int width = 5; //number of images to be drawn along x-axis
            int height = 5; //number of images to be drawn along y axis
            int xOffset = 10; //width of image
            int yOffset = 10; //height of image
            int currentX = 0; //current x coordinate to draw image to
            int currentY = 0; //current y coordinate to draw image to
            for(int i = 0; i < width; i++) {
                 for(int j = 0; j < height; j++) {
                       g2.drawImage(image, currentX, currentY,this);
                       currentY += yOffset;
                 }
                 currentX += xOffset;
                 currentY = 0;
            }
    }

    I hope that helps make the concept a little clearer.

  6. #5
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Thanks Giggas! I understand now. I have taken both your ideas and altered it to suit my situation. Now however, when I try to compile and run the program the images do not show. I think it must be an issue as to how i painted my cobblestone image. There is one error but I have no idea how to fix it.
    package outrun;
     
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import java.awt.Color;
    import java.awt.Image;
    import javax.swing.ImageIcon;
    import java.awt.Toolkit;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.awt.event.KeyAdapter;
    import java.awt.event.KeyEvent;
     
    import javax.swing.JPanel;
    import javax.swing.Timer;
     
    public class Board extends JPanel implements ActionListener {
     
    	private Timer timer;
    	private Person person;
    	private Cobblestone cobblestone;
     
    	public Board() {
     
    		addKeyListener(new TAdapter());
    		setFocusable(true);
    		setBackground(Color.BLACK);
    		setDoubleBuffered(true);
     
    		setSize(600, 400);
     
    		person = new Person();
    		cobblestone = new Cobblestone();
    		timer = new Timer(5, this);
            timer.start();
    	}
     
    	public void paint(Graphics g) {
        	super.paint(g);
     
        	Graphics2D m = (Graphics2D)g;
        	m.drawImage(person.getImage(), person.getX(), person.getY(), this);
     
            drawMaze((Graphics2D) g);
     
        }
        private void drawMaze(Graphics2D g){
        	Graphics2D g2 = (Graphics2D)g;
     
        	    int width = 10; 
                int height = 10; 
                int xOffset = 20; 
                int yOffset = 20; 
                int currentX = 0; 
                int currentY = 0; 
                for(int i = 0; i < width; i++) {
                     for(int j = 0; j < height; j++) {
                           g2.drawImage(cobblestone, currentX, currentY,this);
                           currentY += yOffset;
                     }
                     currentX += xOffset;
                     currentY = 0;
     
                     Toolkit.getDefaultToolkit().sync();
                 	g.dispose();
                }
        }
     
     
        public void actionPerformed(ActionEvent e) {
        	person.move();
        	repaint();
        }
     
        private class TAdapter extends KeyAdapter {
     
        	public void keyReleased(KeyEvent e) {
        		person.KeyReleased(e);
        	}
     
        public void keyPressed(KeyEvent e) {
        	person.KeyPressed(e);
        }
     
        }
    }

    The error is on line 58 stating: 'The method drawImage(Image, int, int, ImageObserver) in the type Graphics is not applicable for the arguments (Cobblestone, int, int, Board)'.

    I'm pretty sure that is not the only reason behind the absence of my cobblestone images printing out. I will also show you my cobblestone class.

    package outrun;
     
    import java.awt.Image;
    import javax.swing.ImageIcon;
     
    public class Cobblestone {
     
    	private String cobblestone = "/images/cobblestone.png";
     
    private Image image;
     
     
    	public Cobblestone() {
    		ImageIcon ii = new ImageIcon(this.getClass().getResource(cobblestone));
    		image = ii.getImage();
    	}
     
    		 public Image getImage() {
    		    	return image;
    		    }
    }

    What is wrong? The main thing is I now know how to generate multiple images which is what I really wanted. Now I just need to see where I have gone wrong so I can visually see what I have learnt. Thanks for the answers so far!

  7. #6
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    The method drawImage(Image, int, int, ImageObserver)
    in the type Graphics is not applicable for the arguments (Cobblestone, int, int, Board)'.
    The compiler is looking for an Image as the first argument to drawImage(). It is finding a Cobblestone object which is not an Image.
    Does the Cobblestone class have a method that returns an Image? Call that method in the drawImage() method call.
    If you don't understand my answer, don't ignore it, ask a question.

  8. #7
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Quote Originally Posted by Norm View Post
    Does the Cobblestone class have a method that returns an Image? Call that method in the drawImage() method call.
    Yes, it has a method that returns an image for getImage(). I renamed getImage() to drawImage() but the error is still there. Is there something still wrong with the way I have drawn the image or written my Cobblestone class?

  9. #8
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    Please post the full text of the error message and the source code causing it.

    The Graphics class's drawImage() requires an Image, not a Cobblestone object.
    If you don't understand my answer, don't ignore it, ask a question.

  10. #9
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Ah ok, sorry that will be much easier:
     g2.drawImage(cobblestone, currentX, currentY,this);

    This code belongs to Board.class

    Error Message: The method drawImage(Image, int, int, ImageObserver)
    in the type Graphics is not applicable for the arguments (Cobblestone, int, int, Board)'.

    It is still the same error message as before.

  11. #10
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    Is g2 a Graphics object?
    If it is, then is cobblestone an Image object? It must be, the drawImage() method requires an Image.
    Replace cobblestone with a reference to an Image object.

    Where is the Image you want to draw?
    If you don't understand my answer, don't ignore it, ask a question.

  12. #11
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    This is where I'm creating my image:
    private String cobblestone = "/images/cobblestone.png";
     
    private Image image;
     
     
    	public Cobblestone() {
    		ImageIcon ii = new ImageIcon(this.getClass().getResource(cobblestone));
    		image = ii.getImage();
    	}
     
    		 public Image getImage() {
    		    	return image;
    		    }
    Here is the image I want to draw: cobblestone.png

    Hope this helps you understand the problem!

  13. #12
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    The compiler wants you to code a variable name in the Graphics class's drawImage() method that has a data type of Image. Cobblestone is NOT an Image. IThe Cobblestone class has a getImage() method that you should call because it returns an Image and that will make the compiler happy.
    If you don't understand my answer, don't ignore it, ask a question.

  14. #13
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    I understand more now but it is still a tad bit hazy. How do I alter my Cobblestone Class so that it IS an image? I am a bit confused as it worked perfectly fine for my other class which is an image.
    package outrun;
     
    import java.awt.Image;
    import java.awt.event.KeyEvent;
     
    import javax.swing.ImageIcon;
     
    public class Person {
     
    	private String person = "/images/person.png";
     
    	private int dx;
    	private int dy;
    	private int x;
    	private int y;
     
    	private Image image;
     
    	public Person() {
    		ImageIcon i = new ImageIcon(this.getClass().getResource(person));
    		image = i.getImage();
     
    		x = 10;
    	    y = 10;	
    	}
     
    	public void move() {
    		x += dx;
    		y += dy;
    	}
     
        public int getX() {
        	return x;
        }
     
        public int getY() {
        	return y;
     
        }
     
        public Image getImage() {
        	return image;
        }
     
        public void KeyPressed(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 1;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = -1;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = -1;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 1;
            }
        }
     
        public void KeyReleased(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 0;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = 0;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = 0;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 0;
            }
        }
    }

    EDIT: I just replaced the cobblestone I used in the line which returned the error with my other working image 'person'. Weirdly, It also returned the same error making me think that it is the way I am painting my images in Board.class is wrong.
    Last edited by Montario; April 11th, 2012 at 05:21 PM.

  15. #14
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    How do I alter my Cobblestone Class so that it IS an image?
    That could be very hard. You would need to define the methods in the Image class.
    Why do you want to make it an Image? Where do you want to use instances of the class that absolutely require it to be an Image vs using the class's getImage() method to return the Image.

    it worked perfectly fine for my other class which is an image.
    Post the code that shows what you are talking about.
    If you don't understand my answer, don't ignore it, ask a question.

  16. #15
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Sorry, I meant my class which CONTAINS and image. The following is person.java

    package outrun;
     
    import java.awt.Image;
    import java.awt.event.KeyEvent;
     
    import javax.swing.ImageIcon;
     
    public class Person {
     
    	private String person = "/images/person.png";
     
    	private int dx;
    	private int dy;
    	private int x;
    	private int y;
     
    	private Image image;
     
    	public Person() {
    		ImageIcon i = new ImageIcon(this.getClass().getResource(person));
    		image = i.getImage();
     
    		x = 10;
    	    y = 10;	
    	}
     
    	public void move() {
    		x += dx;
    		y += dy;
    	}
     
        public int getX() {
        	return x;
        }
     
        public int getY() {
        	return y;
     
        }
     
        public Image getImage() {
        	return image;
        }
     
        public void KeyPressed(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 1;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = -1;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = -1;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 1;
            }
        }
     
        public void KeyReleased(KeyEvent e) {
        	int key = e.getKeyCode();
     
        	if (key == KeyEvent.VK_RIGHT) {
        		dx = 0;
        	}
     
            if (key == KeyEvent.VK_LEFT) {
            	dx = 0;
            }
     
            if (key == KeyEvent.VK_UP) {
            	dy = 0;
            }
     
            if (key == KeyEvent.VK_DOWN) {
            	dy = 0;
            }
        }
    }

    In the Board.class, my graphics method paints the person image in this person.java perfectly. I don't understand why my cobblestone images aren't being painted.

  17. #16
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    m.drawImage(person.getImage(), person.getX(), person.getY(), this);
    Is this where the image is being drawn?
    If you don't understand my answer, don't ignore it, ask a question.

  18. #17
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    Quote Originally Posted by Norm View Post
    m.drawImage(person.getImage(), person.getX(), person.getY(), this);
    Is this where the image is being drawn?
    Yes, exactly. I don't know where I have gone wrong with the cobblestone image drawing though.

  19. #18
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    Where do you call the Cobblestone class's getImage() method?
    If you don't understand my answer, don't ignore it, ask a question.

  20. #19
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    I call it in my Cobblestone class here:
    private String cobblestone = "/images/cobblestone.png";
     
    private Image image;
     
     
    	public Cobblestone() {
    		ImageIcon ii = new ImageIcon(this.getClass().getResource(cobblestone));
    		image = ii.getImage();
    	}
     
    		 public Image getImage() {
    		    	return image;
    		    }
    }

    You can see the full cobblestone class in my earlier posts on this thread.

  21. #20
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    Can you explain why you call the getImage() method of the Person class, but won't call the getImage() method of the Cobblestone class?
    If you don't understand my answer, don't ignore it, ask a question.

  22. #21
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    I don't understand. I thought I have called the getImage() method of the cobblestone class. Isn't it right here or am I getting mixed up:
     public Image getImage() {
    		    	return image;
    		    }
    }

  23. #22
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: Help Generating a level

    The problem is where you are using an instance of the Cobblestone class in the drawImage() method. That is where you need to call the Cobblestone class's getImage() method.
    Look at where you are using an instance of the Person class in the drawImage() method. I posted the code in post#16
    If you don't understand my answer, don't ignore it, ask a question.

  24. #23
    Member
    Join Date
    Mar 2012
    Location
    Billings, MT
    Posts
    47
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help Generating a level

    oh yes, I see exactly what you mean Norm. I never called it in the board.class! Thank you very much for your help, it works! Sorry I wasted your time not to notice that little detail I forgot.

Similar Threads

  1. Generating array (or arraylist) matrix from txt file
    By benjalizana in forum What's Wrong With My Code?
    Replies: 2
    Last Post: November 14th, 2011, 08:09 PM
  2. Generating a Random Coprime Number
    By phleep in forum What's Wrong With My Code?
    Replies: 0
    Last Post: March 15th, 2011, 12:12 AM
  3. Generating random numbers
    By abelned in forum Object Oriented Programming
    Replies: 1
    Last Post: September 1st, 2010, 07:24 AM
  4. Generating random letters and numbers together
    By newJava in forum Java Theory & Questions
    Replies: 3
    Last Post: March 19th, 2010, 04:08 AM
  5. Programming partner that can earn revenue
    By Jay in forum Project Collaboration
    Replies: 0
    Last Post: May 25th, 2009, 02:33 PM