473,394 Members | 1,739 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

chess

Do you guys know if there is a program that can generate chess moves? I
recently wrote a chess game but its only 2 [human] player... I deceided it
was too difficult to come up with the logic for the AI movements... anyone
know where i can find a DLL that will generate chess moves? Ideally, the
DLL would accept moves made by the human player and generate an AI move
based on that. Any help would be much appreciated

:\\ME
Nov 20 '05 #1
5 5836
I wrote an AI (if you can call it that) chess game before.

Recursion, Recursion Recursion...

And it gets really confusing...

Just think about how you think, your own rationale, its simply a game of
perceiving the next move.

So try to build from the opposite side. instead of thinking about what your
computer is going to attack, predict the next move by assigning value to
pieces...

Now it gets fun. Because logically, the computer could predict the entire
game.. this could be time consuming, in whichc ase you can set your
diffuculty level to timeout after awhile in which case the computer ranks
its moves and takes the "best" one.

No, I don't have DLL code... sorry, =)

I might get bored and write it sometime.

"derian" <--*******@astutesolutions.com---> wrote in message
news:Oh**************@tk2msftngp13.phx.gbl...
Do you guys know if there is a program that can generate chess moves? I
recently wrote a chess game but its only 2 [human] player... I deceided it
was too difficult to come up with the logic for the AI movements... anyone
know where i can find a DLL that will generate chess moves? Ideally, the
DLL would accept moves made by the human player and generate an AI move
based on that. Any help would be much appreciated

:\\ME

Nov 20 '05 #2
I tried that but i was .07% done with the code when i came to the conclusion
that I'm only running a 1gig processor w/512 ram and i'm in fact not deep
blue... to calculate all the possibilities for 1 move would take an infinite
amount of time... even if i set the timeout.

Any other ideas?
"derian" <--*******@astutesolutions.com---> wrote in message
news:Oh**************@tk2msftngp13.phx.gbl...
Do you guys know if there is a program that can generate chess moves? I
recently wrote a chess game but its only 2 [human] player... I deceided it
was too difficult to come up with the logic for the AI movements... anyone
know where i can find a DLL that will generate chess moves? Ideally, the
DLL would accept moves made by the human player and generate an AI move
based on that. Any help would be much appreciated

:\\ME

Nov 20 '05 #3
Hi Derian, CJ,

ROFL. <Only> 1GHz, <only> 512Mb RAM, <only> VB.NET.

[wanders away mumbling to himself, "why, when I were a lad .... 4MHz,
32Kb, real basic BASIC.. ... kids these days, don't know what they've got ...
no appreciation ... we fought a war for ... don't know their alpha-betas from
a bubble sort.... heuristics? probably think I've sneezed .... fit the entire
chess board into 32 bytes .... generating legal moves, now that were easy
compared to finding the <best> move.... tree pruning ... ah, remember that
routine I wrote ...]

That wasn't me by the way - I did Backgammon. ;-)

Regards,
Fergus
Nov 20 '05 #4
great reply fergus... that just made my day.
Your whit is truly appreciated in a world that is sometimes severly lacking.

so now back to my original issue... do you have any solutions?

"Fergus Cooney" <fi******@tesco.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Hi Derian, CJ,

ROFL. <Only> 1GHz, <only> 512Mb RAM, <only> VB.NET.

[wanders away mumbling to himself, "why, when I were a lad .... 4MHz,
32Kb, real basic BASIC.. ... kids these days, don't know what they've got .... no appreciation ... we fought a war for ... don't know their alpha-betas from a bubble sort.... heuristics? probably think I've sneezed .... fit the entire chess board into 32 bytes .... generating legal moves, now that were easy
compared to finding the <best> move.... tree pruning ... ah, remember that
routine I wrote ...]

That wasn't me by the way - I did Backgammon. ;-)

Regards,
Fergus

Nov 20 '05 #5
Hi Derian,

I did a search on Google for: Chess Algorithm Free Source

Free Chess Program (Source)
http://www.gnu.org/software/chess/chess.html
This is probably C or C++ and pretty unreadable but the FAQ gave me

A forum which provides general information on chess programming
newsgroup rec.games.chess.computer

Yahoo have
groups.yahoo.com/group/chess-engines/

Don't bother with Star Chess (not Chess) or Chines Chess (18 circular
pieces per player)

Here's a free source for a chess program. It doesn't say what language.
http://games.newfreeware.com/programs/762/

Happy algorithming :-)

Regards,
Fergus
Nov 20 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Will McGugan | last post by:
Hi folks, I've written a Python chess module that does the following. * Reads / Writes PGN files * Write FEN files * Validates moves * Lists legal moves * Detects check / mate / stalemate /...
11
by: Gregc. | last post by:
G'day I am writing a chess program. Here is my code: #include <stdio.h> #include <stdlib.h> bool isInCheck (int krow, int kcol, int qrow, int qcol) { double check;
5
by: Paolo Pantaleo | last post by:
Well Python is not a good language for writing a chess engine (even if a chess engine exists: http://www.kolumbus.fi/jyrki.alakuijala/pychess.html), but it could be grat for chess interfaces, for...
1
by: Varun Hiremath | last post by:
Hello, I have written a chess client using python which is a graphic interface to play chess. It is at present a two player version, players move their peices by clicking two squares on the board...
13
by: asif929 | last post by:
I have been trying to create this chess program from many hours and still couldn't figure out how to complete it. After consume all these efforts i come to this google groups for the first time for...
63
by: biyubi | last post by:
Hi, a year ago I won the 2005 Best Game categoryof the International Obfuscated C Code Contestwith a chess program. http://www.ioccc.org/whowon2005.html...
2
by: CoreyWhite | last post by:
When playing games, perhaps the most simple is tic-tac-toe. The game has two simple strategies, one is defensive and the other offensive. It is not hard at first to learn how to tie games when...
10
by: sam_cit | last post by:
Hi Everyone, I'm working on developing a chess game and i decided to use c++ for its object oriented approach. I have a bass class unit and is inherited to distinct number of units (like king,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.