I'm not good in C++ and I need your help. I have some small program that can automatically play chess in internet chess servers. It needs only the chess engine to play. I play only on www.kurnik.org, but from a few months they changed adress to www.playok.com. My problem depends on this, that when they changed the adress, they too changed the chess board. Program can't recognize the board and I can't use it to play. I don't know how to repair it. I want play with this program on this chess server.

In the attachment are the program and C++ 6.0 sources. If someone can repair this program, I will be grateful.

Screens:

New board:
http://chalon-echecs.fr/wp-content/uploads/2008/12/playok4.jpg

Previous board (sorry for the size, but I can't find larger):
http://www.szachy.tbg.net.pl/grafika/serwery/kurnik2.jpg

Program:
http://www.sendspace.com/file/j441fg

Klapiii
Deleted Member

The source does not include the *.dsw file for use by VC++ 6.0 IDE. And next time you zip up source code you should delete all the files that are generated by the compiler, such as all the *.obj files. That will make the zip file smaller.

So it can't be repaired by using sources? I hope that it is possible from .exe file :) Btw. thanks for the reply :)

I might be possible, but I don't know what source files to include in the project. If you can get the *.dsw file or a makefile (usually has *.mak file extension) that would be great. The *.exe file is useless for this purpose.

I don't have this files :( There is website of author this program (I can't contact with him, because he didn't make accessible any e-mail or something):
http://www.mgn.ru/~internetchesskiller/

Maybe it will be helpful for you, but I doubt. I believe in you :)

Actually, since it appears that the program scans the chessboard visually you should be able to adapt it to the 'new' chessboard layout. It's really just a matter of changing it so that it recognizes the new board and pieces. It looks like the original compiler was CBuilder; you will need to create a project or makefile for your compiler. It actually appears that the makefile/project is for CBuilder 6.0, *not* Visual C++ 6.0, which is why there is not a ".dsw" file (and the obj and other intermediate files are a result of the way the auther zipped up the file for download).
You will not be able to modify the exe, as that is compiled code; however with these sources you can modify the files and build your own exe. I haven't yet looked through all of it; it is possible that the information for recognizing the board and the pieces is provided by an external file, but since the exe does not require separate files for it to load, this data is probably stored as either a resource (if you are lucky), or as hard-coded data in the source (if you are not lucky). Hope for the first, but you will probably end up with the second case imho.

So, to sum up: you need to create a project or makefile (which itself is a type of project) for your own compiler. The project needs to specify what cpp files to compile and link. It won't really hurt anything to list *all* of the .cpp files in the project, as this will result in a slightly larger exe (which is probably not a big factor for you). The compiler and linker should optimize this code out anyway. Once you have a valid exe building, you then need to find where the data for the board and pieces is specified and modify this accordingly to reflect the new board and piece images. Without getting deeper into it I don't know how complex a task that is.

Thanx...
Sean

Thanks for the reply. I must only find where is the information for recognizing the board and pieces. I searched in the source and I didn't find some significant information or images of pieces or board. I don't know how it recognizes the board after captured screen. It is riddle. Maybe you will decode it.

Greets

Edited 2 Years Ago by Dani: Removed Name

my guess is that the code you want is in the folder fruit -- it has a board.cpp and board.h which might contain relevant information.

Thanks a lot. But what lines I must change? I don't know what parameters, etc. must be changed in these files.

This project can only be compiled with Borland compilers because of all the Borland-specific code it contains, and I don't have that compiler. Sorry, but I can't help you with this.

Refresh.

I doubt that anyone here will take up the task of modifying the program.

A slight chance of getting some sort of assistance might be to contact the author, his contact information is available on the program's Help/About window.

Ok I sended an e-mail to <snip email>. Maybe however someone here will undertake this task.

Why the problem can't be resolved in this topic? Why I might have to pay?

why? because it would require more effort than one would normally expect out of a free programming forum. This forum is for asking, discussing, and answering programming questions, not for providing free computer programming. For that you will have to pay just like everyone else that wants people to write programs for them.

Almost everyone here at DaniWeb are unpaid volunteers. None of us get paid for helping others, so don't expect us to do something like what you want for free.

Since you like to bump this thread so much I'm going to close it to prevent you from doing that again.

This article has been dead for over six months. Start a new discussion instead.