Blackjack

This is a discussion on Blackjack within the C++ Programming forums, part of the General Programming Boards category; hmm...it might be cuz i played an online one made by a british guy...

  1. #61
    Teenage Mutant Ninja Nerd MMD_Lynx's Avatar
    Join Date
    Aug 2004
    Posts
    65
    hmm...it might be cuz i played an online one made by a british guy
    Stupid people are useful. You can make them do all the mindless tasks you are too lazy to do yourself.

    Sphynx cats are just bald and wrinkly, like old people, and we don't reject them.

  2. #62
    Anal comment spacer DominicTrix's Avatar
    Join Date
    Apr 2002
    Posts
    120
    lol, I'm british, if it wasn't for money that would explain it. As I said it's a cool rule, would make your game more playable.
    "The most important thing about acting is honesty. If you can fake that you've got it made" - George Burns

  3. #63
    Teenage Mutant Ninja Nerd MMD_Lynx's Avatar
    Join Date
    Aug 2004
    Posts
    65
    oh...heh didn't notice ur Location. it was for a chat game. just so people didn't get bored. actually, it was made with an "unofficial" programming language specifically made for making online games. Very helpful. and it was OOP.

    I made a few games myself on it. I'm working on getting my skills high enough so I can make a network game. I didn't understand a lot of the winsock stuff.
    Stupid people are useful. You can make them do all the mindless tasks you are too lazy to do yourself.

    Sphynx cats are just bald and wrinkly, like old people, and we don't reject them.

  4. #64
    Anti-Poster
    Join Date
    Feb 2002
    Posts
    1,399
    MMD_Lynx, in case you haven't seen any of my previous posts, Beej's Guide is my favorite thing to refer to those having difficulties with socket programming.
    If I did your homework for you, then you might pass your class without learning how to write a program like this. Then you might graduate and get your degree without learning how to write a program like this. You might become a professional programmer without knowing how to write a program like this. Someday you might work on a project with me without knowing how to write a program like this. Then I would have to do you serious bodily harm. - Jack Klein

  5. #65
    Teenage Mutant Ninja Nerd MMD_Lynx's Avatar
    Join Date
    Aug 2004
    Posts
    65
    i'll bookmark it for later. let's keep this strictly Blackjack/card game related. (this is a REALLY long post for such a seemingly simple subject)
    Stupid people are useful. You can make them do all the mindless tasks you are too lazy to do yourself.

    Sphynx cats are just bald and wrinkly, like old people, and we don't reject them.

  6. #66
    VA National Guard The Brain's Avatar
    Join Date
    May 2004
    Location
    Manassas, VA USA
    Posts
    903

    Lightbulb

    all these shuffle algorithms were nice... but I was thumbing through the book today.. and found exactly what we were looking for...

    Code:
    #include<algorithm>
    
    random_shuffle(array[0], array[51]);  //list first and last usable elements as parameters
    random_shuffle() will re-arrange array elements in a pseudo-random order (which I think necessitates the use of srand()).

    lots of cool stuff in the <algorithm> library btw.
    Last edited by The Brain; 09-11-2004 at 11:48 AM.
    • "Problem Solving C++, The Object of Programming" -Walter Savitch
    • "Data Structures and Other Objects using C++" -Walter Savitch
    • "Assembly Language for Intel-Based Computers" -Kip Irvine
    • "Programming Windows, 5th edition" -Charles Petzold
    • "Visual C++ MFC Programming by Example" -John E. Swanke
    • "Network Programming Windows" -Jones/Ohlund
    • "Sams Teach Yourself Game Programming in 24 Hours" -Michael Morrison
    • "Mathmatics for 3D Game Programming & Computer Graphics" -Eric Lengyel

  7. #67
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,702
    Code:
    random_shuffle(&array[0], &array[51]);
    Fairly up-to-date reference to the STL:
    http://www.sgi.com/tech/stl/table_of_contents.html

    gg

  8. #68
    VA National Guard The Brain's Avatar
    Join Date
    May 2004
    Location
    Manassas, VA USA
    Posts
    903
    ahhh... good catch... book had the example templated.. my attempt to translate into laymans terms failed.
    • "Problem Solving C++, The Object of Programming" -Walter Savitch
    • "Data Structures and Other Objects using C++" -Walter Savitch
    • "Assembly Language for Intel-Based Computers" -Kip Irvine
    • "Programming Windows, 5th edition" -Charles Petzold
    • "Visual C++ MFC Programming by Example" -John E. Swanke
    • "Network Programming Windows" -Jones/Ohlund
    • "Sams Teach Yourself Game Programming in 24 Hours" -Michael Morrison
    • "Mathmatics for 3D Game Programming & Computer Graphics" -Eric Lengyel

Page 5 of 5 FirstFirst 12345
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Simple Blackjack Program
    By saber1357 in forum C Programming
    Replies: 1
    Last Post: 03-28-2009, 04:19 PM
  2. Help with Blackjack program
    By sugie in forum C++ Programming
    Replies: 1
    Last Post: 04-30-2005, 01:30 AM
  3. Blackjack!
    By Dr. Bebop in forum Game Programming
    Replies: 1
    Last Post: 10-03-2002, 09:58 PM
  4. Blackjack
    By the_head in forum C Programming
    Replies: 1
    Last Post: 08-03-2002, 09:57 AM
  5. BlackJack Program...
    By 67stangman in forum C++ Programming
    Replies: 3
    Last Post: 05-06-2002, 11:44 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21