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...
Type: Posts; User: Stormin
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...
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...
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.
* ...
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...
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...
Sorry the list would be all char except for 10 right? Way to get around this? cheers
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...
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...