Chess

Here you can talk about everything that's offtopic.

Moderator: Dust

User avatar
Dust
The Boss
Posts: 9093
Joined: 01 Jan 1970 01:00
Contact:

Chess

Post by Dust » 09 Jun 2007 14:05

I had to write a chess program for one of my classes. Unfortunately it was a C# .Net class, so I had to use that...

Here's what I have done so far: Loading is not implemented yet (at least not for the format it saves :), the AI is rather dumb (I lose allways anyway...) and there might be countless bugs. Comments? :)

(It requires .Net 2.0 to run I think)

http://outland.dnsalias.net/dl/Chess.exe
I do what I think is right. But I don't think that what I think is right can not be wrong.
Seppel
Posts: 903
Joined: 01 Jan 1970 01:00
Contact:

Post by Seppel » 09 Jun 2007 14:16

To run this application, you must first install one of the following versions of the .NET Framework: v2.0.50727..

now talking about chess anyway ... damn that chess on Vista sure isn't easy :s :(
User avatar
Dust
The Boss
Posts: 9093
Joined: 01 Jan 1970 01:00
Contact:

Post by Dust » 09 Jun 2007 14:24

Yes, it requires .Net. Microsofts pittifull attempt in copying the Idea of Java...
I do what I think is right. But I don't think that what I think is right can not be wrong.
Esoteric
Die-hard
Posts: 2216
Joined: 01 Jan 1970 01:00
Location: Amsterdam
Contact:

Post by Esoteric » 09 Jun 2007 15:34

if you loose to vista chess easy mode you just cant play chess :lol:

as its way too dumb on easy to even compete :) and i hardly ever play chess, i did 3 games just to check it out :)

i do like the poker game :)
Don't micromanage my psychodamage.
Seppel
Posts: 903
Joined: 01 Jan 1970 01:00
Contact:

Post by Seppel » 09 Jun 2007 15:38

Esoteric wrote:if you loose to vista chess easy mode you just cant play chess :lol:

as its way too dumb on easy to even compete :) and i hardly ever play chess, i did 3 games just to check it out :)

i do like the poker game :)
at what lvl do you play it?
Esoteric
Die-hard
Posts: 2216
Joined: 01 Jan 1970 01:00
Location: Amsterdam
Contact:

Post by Esoteric » 09 Jun 2007 17:03

i dont play it i played it twice on easy and once on medium
Don't micromanage my psychodamage.
Colyn
Die-Harder
Posts: 2721
Joined: 01 Jan 1970 01:00
Location: Cambridge, UK
Contact:

Post by Colyn » 11 Jun 2007 12:25

The AI is truly awful :) Hugely aggressive with the queen, doesn't understand asset exchanges. Doesn't seem to value promoting pawns i.e. would rather go after loose pawns with its king. Promoted pieces cannot move. Pawns can move two places when they get to 5 (white) and 4 (black). Oh and it doesn't understand draw through repitition. Needs new graphics for pieces as well, hard to distinguise king/queen/bishop. Apart from that, it's very good :oops:
Colyn | Warrior
Squirrels chase Magpies. It's true. I've seen it...
Colyn
Die-Harder
Posts: 2721
Joined: 01 Jan 1970 01:00
Location: Cambridge, UK
Contact:

Post by Colyn » 11 Jun 2007 12:27

Oh yea, the "thinking" thread needs to check for UI input such as undo.
Colyn | Warrior
Squirrels chase Magpies. It's true. I've seen it...
Stormwern
Die-hard
Posts: 1006
Joined: 01 Jan 1970 01:00
Location: Sweden
Contact:

Post by Stormwern » 11 Jun 2007 12:38

Why don't you post the vastly superior chess game you apparently have made colyn.
Colyn
Die-Harder
Posts: 2721
Joined: 01 Jan 1970 01:00
Location: Cambridge, UK
Contact:

Post by Colyn » 11 Jun 2007 14:18

I wouldn't know where to start Storm. Dust asked for comments; I bothered to take a look and post them.

Now climb back into your box and try to think of something useful to say.
Colyn | Warrior
Squirrels chase Magpies. It's true. I've seen it...
User avatar
Dust
The Boss
Posts: 9093
Joined: 01 Jan 1970 01:00
Contact:

Post by Dust » 11 Jun 2007 14:41

Colyn wrote:The AI is truly awful :) Hugely aggressive with the queen, doesn't understand asset exchanges. Doesn't seem to value promoting pawns i.e. would rather go after loose pawns with its king. Promoted pieces cannot move. Pawns can move two places when they get to 5 (white) and 4 (black). Oh and it doesn't understand draw through repitition. Needs new graphics for pieces as well, hard to distinguise king/queen/bishop. Apart from that, it's very good :oops:
Yes, the AI is almost purely material based, with a hint on board controll (which is why it uses it's queen early: lots of controll...)

That promoted pieces can't move is strange. Hmm... Maybe I forgot to insert it into the player... oh well... fixed in the next version :)

Pawns should only be able to move two pieces at the start, as their first move. More time with the debuger I guess...

Draws have not yet been implemented.

I like the graphics, searched for hours (because they would be very ugly if I had made them myself :), and it is unlikely they get replaced. Maybe I could attach labels.

Thanks for the feedback :)

Edit: I have no idea how to implement repetition detection... maybe a hash table of past situations?
I do what I think is right. But I don't think that what I think is right can not be wrong.
Grumthorn
Die-hard
Posts: 2231
Joined: 01 Jan 1970 01:00
Location: Waterford, Ireland
Contact:

Post by Grumthorn » 11 Jun 2007 14:50

Dust wrote: Edit: I have no idea how to implement repetition detection... maybe a hash table of past situations?
Very low priority fix tbh, that along with NNK V K end games and the suchlike should probably be the end of the list of fixes.
Every man's death diminishes me, for I am involved in all mankind.
Therefore, send not to know for whom the bell tolls; it tolls for thee.
Colyn
Die-Harder
Posts: 2721
Joined: 01 Jan 1970 01:00
Location: Cambridge, UK
Contact:

Post by Colyn » 11 Jun 2007 15:00

Dust wrote:Yes, the AI is almost purely material based, with a hint on board controll (which is why it uses it's queen early: lots of controll...)
If nothing else, it certainly has an aspect of "shock and awe". Had me freaked out for quite a while.
That promoted pieces can't move is strange. Hmm... Maybe I forgot to insert it into the player... oh well... fixed in the next version :)
I'm pretty sure the opposition didn't move their promoted piece either.
Pawns should only be able to move two pieces at the start, as their first move. More time with the debuger I guess...
:)
I like the graphics, searched for hours (because they would be very ugly if I had made them myself :), and it is unlikely they get replaced. Maybe I could attach labels.
There's no shortage of "assets" on the intertron, I'll find some and post links.
Thanks for the feedback :)
Pleasure.
Edit: I have no idea how to implement repetition detection... maybe a hash table of past situations?
It's been a while since I played chess properly but I do remember there being some subtleties regarding repetition rule (possibly something to do with castling). In it's basic form, if the same position occurs 3 times, the game can be declared a draw. Here's a link to the FIDE rules..

http://www.chessvariants.com/fidelaws.html
Colyn | Warrior
Squirrels chase Magpies. It's true. I've seen it...
User avatar
Dust
The Boss
Posts: 9093
Joined: 01 Jan 1970 01:00
Contact:

Post by Dust » 11 Jun 2007 15:28

Colyn wrote:Oh yea, the "thinking" thread needs to check for UI input such as undo.
That's intentionally not allowed, since thinking works by trying out all possibilities (with alpha-beta pruning), and changes the board/move stack. Maybe I should separate that... but it's better from a design standpoint now. (The AI Player component just gets the possible moves from all it's pieces, and gives them to the board to perform them, which he then passes to an evaluation function)
I do what I think is right. But I don't think that what I think is right can not be wrong.
Colyn
Die-Harder
Posts: 2721
Joined: 01 Jan 1970 01:00
Location: Cambridge, UK
Contact:

Post by Colyn » 11 Jun 2007 16:07

From a UI and usability point of view, that's a mistake. If I decide that I want to undo my last move, there is no valid reason why I should not be able to interrupt the computers thinking process rather than having to sit there waiting for it to finish.
Colyn | Warrior
Squirrels chase Magpies. It's true. I've seen it...
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests