Thread: Value of a card bitmap?

  1. #1
    Registered User
    Join Date
    Aug 2002
    Posts
    170

    Value of a card bitmap?

    I am stumped. What I am writting is like a bot for playing cards. I want it to be able to read the data, and make descisions based on the data. Almost all of the data is displayed in the CListBox. But, the cards that are delt to me are not listed there. They are drawn on the screen as graphical cards. I need to be able to get the value of the cards, both suit and value in order to make decisions. Currently my program works if I manually type my hand into my program. But, this way I can't let me program run autonomously.

    Any advice? I hate to keep asking, but this board has been very helpful in the past.

    Thanks in advance for any help you can give me.

    Best Regards,

    Bonkey
    Best Regards,

    Bonkey

  2. #2
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,793
    Are you talking about solitaire & freecell???

    If so, then there's no easy way that I can think of.....

    The only thing that springs to mind is that both of these apps use a specific dll to draw the actual cards (the cleverly titled "cards.dll")....there are methods to intercept dll calls, but they are rather difficult, very hackish and probably not too reliable unless you really know what you are doing......

  3. #3
    Registered User
    Join Date
    Aug 2002
    Posts
    170
    Not those specifically. But the idea is the same. I know they have a dll that they are using for the cards.

    All other cards that are visable are logged and I can read them from the log. Just my own cards don't get logged.

    It is workable the way it is.
    Best Regards,

    Bonkey

  4. #4
    Registered User
    Join Date
    Aug 2002
    Posts
    170
    Anyone out there have any ideas on reading cards? Is there a way to intercept the dll calls reliably? I know that there is data on cards.dll on the web, but this app is using it's own dll so those specifics wont help.

    Any ideas?
    Best Regards,

    Bonkey

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need Help With a BlackJack Program in C
    By Jp2009 in forum C Programming
    Replies: 15
    Last Post: 03-30-2009, 10:06 AM
  2. Bitwise Unwanted Output
    By pobri19 in forum C++ Programming
    Replies: 4
    Last Post: 09-15-2008, 04:07 AM
  3. Vector out of range program crash.
    By Shamino in forum C++ Programming
    Replies: 11
    Last Post: 01-18-2008, 05:37 PM
  4. Segmentation Fault - aaaaaaaah!
    By yogibear in forum C Programming
    Replies: 6
    Last Post: 10-01-2007, 03:21 AM
  5. Blackjack
    By Tommo in forum C Programming
    Replies: 10
    Last Post: 06-20-2007, 08:07 PM