Software Design
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreSoftware Design

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 8th, 2004, 04:56 AM
jwhoisthebest's Avatar
jwhoisthebest jwhoisthebest is offline
Sniper
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Location: Perth, Western Australia
Posts: 42 jwhoisthebest User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Chess Computers

I am looking to make a program kind of like a chess computer.
What's really got me is the "foresight" thing. I roughly think that pretty much each turn the computer would find out what is and isn't a legal move, and then for each possible move, try moving it and then finding the moves again and so on until a certain point, where at which the computer would work out which one is the best possible outcome.
I just want to be able to find all the possible moves.

The thing I am hoping to make is more like a strategy-fight kind of thing, much like the fighting systems on Final Fantasy games, Pokemon and all those other things, where stategy is the key of the fight. It would be like either an AI character versus a human character, and also AI versus AI. The human versus human thing is easy. It's going to go into an online RPG, and I am hoping to use AI characters instead of human characters so that the game is challenging and fun even if there is only a couple of human players playing to begin with.
I have made something like those before, but they only look at the "now" as it were. So for example, if it's health was under a certain point, it would heal itself, or it would choose defensive or offensive moves depending on the other player's stats, or whether the last couple of moves where very strong.
I think most moves will be legal. I just want to be able to find a way to find all the possible sets of moves up to a certain point in the future, and find out what each players stats and vars would be, so I can work out the "goodness".
Could anyone help?
Thank you if you can. And if it helps, I plan to do this in Flash Actionscript, although I can translate from Javascript or PHP if necessary.
Thankz.

Reply With Quote
  #2  
Old February 11th, 2004, 03:29 PM
dog135's Avatar
dog135 dog135 is offline
Doggie
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jul 2003
Location: Seattle, WA
Posts: 751 dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 10 h 38 m 25 sec
Reputation Power: 7
A lot of thinking goes into good chess programs. If you're trying a different approach from the norm, I'm afraid you're on your own.

There is, however, some good resources for this. I don't remember the name of it, but there's a chess program that you can download the source for that's one of the best on Earth. It uses tratagies from previous human players to learn how to beat it's opponent. Search Google for a while, you're bound to find it.
__________________
"Science is constructed of facts as a house is of stones. But a collection of facts is no more a science than a heap of stones is a house." - Henri Poincare

Reply With Quote
  #3  
Old February 14th, 2004, 03:00 AM
jwhoisthebest's Avatar
jwhoisthebest jwhoisthebest is offline
Sniper
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2004
Location: Perth, Western Australia
Posts: 42 jwhoisthebest User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Hmm...

I think I was only having trouble retreiving the branches of possible moves and what not, and returning the variables that would be needed to work out the goodness factor. I don't know why, but I always think that there'd be a really simple way to go about these things (and also where I read up about how chess computers work, it was pretty brief all around) but I think I've got it now. And strangely enough I never work things out until I ask someone, at which point I think "Oh wait, now I've got it". I am probably going to work on it in a format of a multidimensional for and an single array. So there'd be a for for each step into the future it is taking, and then at the final step, work out the variables for it through a certain system similar to the game system. I am starting to think now that maybe using a chess "goodness" system wouldn't work as good for my game, because a certain degree of chance is also going to be in there.

I am still stumped as to how I would go about filling the gaps for the other person's moves though. I'm not sure how to do that, whether I should go about it in the same fashion as how the computer works out the moves, or perhaps just working out all the possible moves, rather than trying to work out what the other player will do. It's a real problem I think, because I haven't seen much on how the chess computers work, and if I make it think that the human player will only choose the best possible move, well that's probably not going to happen, hence making it impossible to make use of the foresight, and if I take into account of all the possible moves that the human player could use, then when checking the gooness, it will always choose the instance where the human player chose the worst possible move.
I'm not sure yet. I think I've read somewhere that most chess computers use the latter.
I'll try searching on Google, but I'm a horrible internet searcher, so I'll just cross my fingers. I actually came across a site that had links to all the source code for chess computers once, about 30 or more links to source code, and not one of them worked. I'm unlucky like that.

Cya, thankyou

Reply With Quote
  #4  
Old February 22nd, 2004, 02:55 AM
Ion2Atom Ion2Atom is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 1 Ion2Atom User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
What about having the computer make its decisions based on the players prior moves? You could have a range from most to least probable based on what the player had chosen in the past when confronted with similar situations. You could then take the top couple moves in this range and have the ai make its decision based the most benificial action it could take regarding the most likely actions the player would take. Hope this is helpful.

Reply With Quote
  #5  
Old March 6th, 2004, 08:23 AM
DaWei_M's Avatar
DaWei_M DaWei_M is offline
Permanently Banned
Dev Shed God 5th Plane (7000 - 7499 posts)
 
Join Date: Jan 2004
Location: Central New York. Texan via Arizona, out of his element!
Posts: 7,351 DaWei_M User rank is Sergeant (500 - 2000 Reputation Level)DaWei_M User rank is Sergeant (500 - 2000 Reputation Level)DaWei_M User rank is Sergeant (500 - 2000 Reputation Level)DaWei_M User rank is Sergeant (500 - 2000 Reputation Level)DaWei_M User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 2 Weeks 1 Day 19 h 39 m 7 sec
Warnings Level: 10
Number of bans: 1
Reputation Power: 0
You're apparently rediscovering a lot of things. The best backgammon automata use neural networks and are trained extensively. The approach yields master-level play.

Reply With Quote
  #6  
Old March 17th, 2004, 02:17 PM
shivaprasad shivaprasad is offline
Chess Programer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Location: India
Posts: 2 shivaprasad User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Chess Developer

Hi,
I was developed a chess game 2 years before and now I am researching to improve artificial inteligence and to make un beatable game . and I feel Glad on ur interest if u need ill send u the game and source also (if u need). ask me if u have any doubts.

thank u
shiva prasad

email : URL
URL

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreSoftware Design > Chess Computers


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT