Search:

Type: Posts; User: Stormin

Search: Search took 0.17 seconds.

  1. Replies
    7
    Views
    2,922

    Re: ArrayList confusion

    Thanks for the replies guys. much appreciated.

    Yeah I have my Card Constructor in my Card Class.

    public class Card
    {
    private char suit, value;
    private String SuitName;
    private...
  2. Replies
    7
    Views
    2,922

    Re: ArrayList confusion

    Using the 'add' method now gives me this error:
    cannot find symbol - constructor Card(java.lang.String)

    My Card object consists of 2 char attributes; value & suit. So I would need the array list...
  3. Replies
    7
    Views
    2,922

    Re: ArrayList confusion

    import java.util.Random;
    import java.util.ArrayList;


    /**
    * Stores the details of all 52 cards in an ArrayList.
    * A card is selected from random from the ArrayList for the current game.
    * ...
  4. Replies
    7
    Views
    2,922

    ArrayList confusion

    Basically, I am creating a CardGuessing game (A user tries to guess a card by choosing whether to guess the suit,value or card, the target card changes for each game and the details of the 52 cards...
  5. Replies
    9
    Views
    2,396

    Re: CardGuesser. Stuck on Card class HELP!

    Where would I state this.

    CompareValues seems to work fine excpet when I compare against 'A'.
    If I compare it to '2' it thinks that 'A' is higher, however 'A' is lower(Ace is low). I've...
  6. Replies
    9
    Views
    2,396

    Re: CardGuesser. Stuck on Card class HELP!

    Sorry the list would be all char except for 10 right? Way to get around this? cheers
  7. Replies
    9
    Views
    2,396

    Re: CardGuesser. Stuck on Card class HELP!

    Thanks for the replies guys!
    Would this work with compareValue though as It contains int and char so is there a way to compare in this order?
    (A,2,3,4,5,6,7,8,9,10,J,Q,K)... Btw this is the...
  8. Replies
    9
    Views
    2,396

    CardGuesser. Stuck on Card class HELP!

    Hey guys i'm in a bit of a pickle.
    I am quite new to Java programming but I am capable of basic tasks. I'm creating a CardGuessing game which includes 3 classes; Game,Pack and Card. In the Card...
Results 1 to 8 of 8