There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
access audio avg avg 8 bios blue screen boot bsod computer connection cpu crash css dell desktop dma driver drivers dvd email error excel explorer firefox firefox 3 freeze gimp graphics hard drive hardware hijackthis hjt install internet internet explorer itunes keyboard laptop macro malware monitor motherboard network networking outlook outlook 2003 outlook 2007 outlook express pio problem problems router seo server slow sound sp3 spyware trojan usb video virtumonde virus vista vundo windows windows vista windows xp winxp wireless
Software Development
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Software & Hardware > Software Development >
Computer Logic for a Math Game (Visual Basic 6)


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

 
Thread Tools
hoopkidups's Avatar
Senior Member with 143 posts.
 
Join Date: Mar 2004
25-May-2006, 04:01 PM #1
Computer Logic for a Math Game (Visual Basic 6)
Hi,

I'm making a small arcade game that works like this:

A dollar bill ranging from $1 to $6 in value is placed in the middle. (Once that type of bill has been used, it cannot be used again.)

The human player and the computer player both have bills ranging from $1 to $6 in their hands. When the bounty is placed in the middle, the human player will be prompted to select a bill. The computer will do the same thing, and the player who chooses the higher value will will the bounty, plus the other player's bet. If both players bet the same value, all of the cash (Bounty + Human's Bet + Computer's Bet) remains in the middle, and both players will bet again.

The player with the most money at the end of the game will win.

Now that you know how the game is played, I'm hoping that someone will be able to help me with the computer AI. It was easy enough to have the computer make relatively stupid choices, but now I'm trying to make a mode where the computer will choose the BEST possible option to bet.

I did some research, and this game is very similar to a card game called Goofspiel. According to an analysis of the game, a payoff matrix must be created, and then analyzed. This is where I'm having trouble - I can't figure out how to translate the matrix to computer terms, especially since there are so many possibilities.

If anyone knows anything about payoff matrices, then I would really appreciate it if they could shed some light on the problem I'm having.

-Thanks
bpmurray's Avatar
Senior Member with 103 posts.
 
Join Date: Jun 2003
Location: Ireland
Experience: Advanced
26-May-2006, 05:27 PM #2
I'm not familiar with Goofspiel, but you need to read up on what's known as "combinatorial game theory" which addresses this situation, i.e. 2 players who each take turns when you have all the information, as opposed to "classical game theory" which refers to games which have a hidden part to them.

The payoff matrix can only be used when you have a fixed amount of money, i.e. the computer loses & the player wins that amount. I just checked wikipedia, and it has a good description of the idea on http://en.wikipedia.org/wiki/Payoff_matrix
__________________
There are 10 kinds of people: those that understand binary and those that don't.
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are Off
Refbacks are Off

You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 03:41 AM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.