Team 5: Virtual Casino

Baseline Use Case

Functionality:
Baseline
System Elements:
Use Case:
Test distribution:
/afs/ece/class/ece841/public_html/team5/team5-baseline.tar.bz2
Test Sequence
  1. Running the Database Server
    1. Login to msepc12.sp.cs.cmu.edu and start SQL server. Directions for access to this host available on request.
  2. Running the Game Server
    1. Log in to any host in the ECE linux cluster.
    2. Change directory to where you wish to unpack the tarball.
    3. Type tar xjvf /afs/ece/class/ece841/public_html/team5/team5-baseline.tar.bz2.
    4. Change to the newly created project directory: cd team5-baseline
    5. If you are using CSH or TCSH for your shell type: source ./env.csh.
    6. If you are using Bourne/BASH/KSH for your shell type: . ./env.bsh.
    7. Make sure that no other orbs are running on this system by typing killall orbd and then start an orb daemon with ./startOrbd.sh&.  Make sure to wait a minute until the orb starts completely.  It gives no output to tell you when it is ready but waiting a minute is usually enough.
    8. Clear out the database of old data in case there is some corrupt data that will effect our test by running ./runDBClear.sh which will not give any output if it runs correctly.
    9. Start the Casino Server with ./BlackJackServer& and wait to see the message, "---Server ready and running .....".  If the orb is running on a different system use the "-h" option as such:   ./BlackJackServer -h <otherhost>.
    10. The server is now up and ready to server games to clients.
  3. Running a Client
    1. Change to the project directory: cd team5-baseline, the same directory from which the server was started.
    2. Start client on this host with ./BlackJackClient. If the orb is on a different host, use the "-h" option as such:
      ./BlackJackClient -h <otherhost>. 
    3. When prompted by the client application enter your name and hit return.
    4. When prompted to buy chips, enter a number and hit return.
    5. The next prompt will ask you to place a bet on the upcoming hand. Type a number between 10 and the number of chips that you have bought in increments of ten.  If you bet zero you quit the game.
    6. You will be dealt two cards. If at anytime you get a total of 21 points, you win. Otherwise you will have to get more points than the dealer without going over 21 to win. If you go over 21 or have fewer points than the dealer, you lose and lose your bet. If you win you get the amount of your bet added to your chip total, if you lose that much is subtracted.
    7. If you don't win automatically with your first two cards you will be prompted to choose between hitting or staying with the cards you have. Hit "h" if you want to be dealt another card or "s" if you want to stay with the ones you have.
    8. The hand continues until either you stay or go over 21
    9. At the end of the hand your chips are added to or subracted from depending on whether you win or loose
    10. Once the hand is over you will be prompted to bet again with your remaining chips. If you are out of chips your only valid choice is to quit the game by entering zero (0) chips as your bet.
    11. The game continues until you run out of chips or decide to quit with your winnings.
Configuration/deployment issues:
Known problems: