Casino

This is a discussion on Casino within the C++ Programming forums, part of the General Programming Boards category; I'm working on my end of the year project for apcs. It is going to be a casino. Right now, ...

  1. #1
    Seņor Member
    Join Date
    Jan 2002
    Posts
    561

    Casino

    I'm working on my end of the year project for apcs. It is going to be a casino. Right now, I am just trying to get poker to work. My problem, I think, is that I am probably linking the files wrong or something. It complies and runs fine, but the first time you play poker, your money won't change. Please don't flame me for using global variables. I am going to rewrite this thing eventually, but at the time I started I did not know how to send arrays to functions. If anyone finds an error or is able to fix my main one, I will love you. Thanks in advance!

  2. #2
    Registered User
    Join Date
    May 2002
    Posts
    317
    Allright, here you go, this works. Looks like a cool program, if I mess up the attachment you need to add load as the first called function in you main and save as your last called function in your main.
    Attached Files Attached Files

  3. #3
    Seņor Member
    Join Date
    Jan 2002
    Posts
    561
    Thanks, but the problem is still there. I guess I explained it badly. Run it, go to poker table, bet, and play. No matter what, you don't win or lose any money the first time you play poker. It's really weird.

  4. #4
    Registered User
    Join Date
    May 2002
    Posts
    317
    Did, you download and implement the code I posted? And actually when I originally ran the program it wouldn't display the amount of money you had after you exited and reentered the program, let alone win or lose any money on the first bet. I changed a couple things and I'm sure if you go over the code you will see it all. (If I'm coming off as preachy or anything, I apologize I'm just trying to get to the answer so your program will work). I just reran the code I adapted now and on the first bet it will add or subtract money. Maybe you're missing something that I changed, but honest it does work. If your still having problems after this just post again, good luck

  5. #5
    Seņor Member
    Join Date
    Jan 2002
    Posts
    561
    It must be my computer then. I downloaded your code, and it does the same thing. I'll try it at school on monday. I noticed the save thing (I was planning on eventually doing that but I've been kinda lazy). Thanks for adding that. I'll look at it more and try to figire it out. Thanks!

  6. #6
    Registered User
    Join Date
    May 2002
    Posts
    317
    Hey, not a prob. If you need any more help just post or pm me. And why don't you email me the finished product, looks like it will be fun to play around with

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. craps game & dice game..
    By cgurl05 in forum C Programming
    Replies: 3
    Last Post: 03-25-2006, 06:58 PM

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