It should have counted the flush - either 4 or 5, dependin on if the cut card matches. If it didn't, and you can reproduce let me know, I will try to find it...
43 is my highest, but thats after a lot of games! On some of the cards (eg Jack and Queen of Clubs) the black areas have become transparent, and you can see through them.
Very impressive - though as with all complex projects it is quite hard to work out what is happening from the code. Can you give us a breakdown of how the cards are shuffled? I had some ideas of how I would simulate a shortening array using 52 sprites, so that rather than pre-shuffling the cards they would be selected in a random order, but you apparently pre-shuffle them.
As a benchmark, if you can get 30 you would be doing well. The original game required this full 4-hand round to be played 4 times, and you win if you make to the end of the cribbage board, which is 121 points. So 30 per round should be a good goal...
This is a variation on a Solitaire version of Cribbage that I used to play as a kid. You are given a hand of 5 cards. Select one for your crib, and the other 4 become a hand. Repeat the process 3 more times, and you end up with 4 hands + the crib, giving you 5 hands. Then, a cut card is drawn and the hands are scored. See http://en.wikipedia.org/wiki/Cribbage#The_show for details on scoring.
This game was a challenging forray into the world of "arrays without arrays". Check out the ValueHandler and SuitHandler sprites. Other projects have been here to represent a deck of cards ((link to project) for example), but I had a specific need where I needed to keep track of where the cards ended up, too. Feel free to reuse this deck of cards wherever you need it!
Comments
You need to be logged in to post comments
Add a Comment
:( i have java but it wont work so i cant see it, but, i think i love it anyway!
(view all replies)Comment Reply
It should have counted the flush - either 4 or 5, dependin on if the cut card matches. If it didn't, and you can reproduce let me know, I will try to find it...
(view all replies)Comment Reply
Great game. 43 is my high score. What about points for a flush?
(view all replies)Comment Reply
43 is my highest, but thats after a lot of games! On some of the cards (eg Jack and Queen of Clubs) the black areas have become transparent, and you can see through them.
(view all replies)Comment Reply
28
(view all replies)Comment Reply
yay! i got 41!
(view all replies)Comment Reply
i got 26
(view all replies)Comment Reply
Awsome i got 24!!
(view all replies)Comment Reply
how come you can see through the cards?
(view all replies)Comment Reply
shuffling takes sooo long
(view all replies)Comment Reply
20 is my score!
(view all replies)Comment Reply
It should be a top loved project!
(view all replies)Comment Reply
Great job.
(view all replies)Comment Reply
COOL!
(view all replies)Comment Reply
(link to project)
(view all replies)Comment Reply
check out the description here (link to forums)
(view all replies)Comment Reply
Very impressive - though as with all complex projects it is quite hard to work out what is happening from the code. Can you give us a breakdown of how the cards are shuffled? I had some ideas of how I would simulate a shortening array using 52 sprites, so that rather than pre-shuffling the cards they would be selected in a random order, but you apparently pre-shuffle them.
(view all replies)Comment Reply
I fixed the timings of the sounds and speech changes. Please let me know if there are any other issues that you find! Have fun!
(view all replies)Comment Reply
As a benchmark, if you can get 30 you would be doing well. The original game required this full 4-hand round to be played 4 times, and you win if you make to the end of the cribbage board, which is 121 points. So 30 per round should be a good goal...
(view all replies)Comment Reply
I scored 22. Is that good?
(view all replies)Comment Reply