PDA

View Full Version : Did it Atlast....



vasanth
12-09-2002, 11:29 AM
At last i have finished my 2 player chess game...... I have attached it check it out.. All the move validations,, check, check mate etc etc has been done..


TO move a piece. first select the pawn or whatever by clicking the left mouse button on it.. To place it move the cursor on top of that block and press that right mouse button..( Please note nothing will happen if that move is not a valid one...)

Well the only thing left is validation for stalemate and castling....

Well here is a challenge.. let me see if anyone of you can find any validation bug or any other bug in my game...(:D badly need testers..)

and also please post you coments to improve my game..

*Runs back to program AI to make it single player...*

To exit the game press any key ont the keyboard( use mouse to play).
You need to extract al the files to run the game...

Sang-drax
12-09-2002, 11:33 AM
Doesn't seem to work in XP :(

It starts, displays a brown text message on the screen and hangs.

vasanth
12-09-2002, 11:34 AM
Ok sorry... corrected the path problem.. i have replaced the file.. download it again.. Sorry :):)

MadHatter
12-09-2002, 11:44 AM
i downloaded and started it ok, but i can't move any of the pieces.. tried them all.. i click and nothing happens.

XP home edition

vasanth
12-09-2002, 11:47 AM
ok here is the tutorial gaian.... :D:D:D


White starts first remember.....

now click on any of the white pieces you want to move(click with left ouse button and release button) now got to the block where you want to place it. and click the right mouse button......( the block you selected should be a valid block for it to move..)


*Note to myself improve the mouse interface...*

Clyde
12-09-2002, 11:54 AM
You don't seem to allow En Passent

vasanth
12-09-2002, 11:59 AM
:mad: ohh boy sombody found out........
:) well i though that this move was not a good idea( my own chess ethics..).. I am not aware of it... but is En Passent a standard chess rule.. Some one please enlighten me about this...

MadHatter
12-09-2002, 12:02 PM
ahh, i got it.. i think you should light up possible moves for a piece, or atleast light up a piece when it's selected. i played once to try it out.. got the king cornered where he was safe at that spot, but couldn't move anywhere else, because it would put him in check, so the game didn't actually win.. just stopped on black's turn :rolleyes: good work... i lost tho :(

PJYelton
12-09-2002, 12:19 PM
Yes, en passent is very much a standard chess move that would need to be included (sorry! :D )

A little history, to speed up the game, chess was changed to allow pawns to move two squares on their first move (they only used to be allowed one square). So that this double move wouldn't be taken advantage of by bypassing an advanced enemy pawn, en passent was also incorporated to keep the game as close to the original as possible. So in no way would it be considered a bad or unethical move, if anything the person who tries to avoid the advance pawn to begin with is the one stretching the rules!

minesweeper
12-09-2002, 12:37 PM
Is en passant the move that is also known as 'castling'? Where you move your rook inside of the kings position.

PJYelton
12-09-2002, 01:17 PM
No, en passent is where a player moves his pawn up two squares side by side with an enemy pawn. The opponant can if he chooses take the pawn as though it had only moved one spot - but he must do it on the very next move or else forfeit the right.

vasanth
12-09-2002, 09:38 PM
Thank you for your opinion... but i would appreciate comments on the other aspects of the game as well... So that i can make it better... .. And did any one of you find any other bugs.. other then the "en passent" move which was not allowed......

PJYelton
12-09-2002, 09:40 PM
I didn't see any other bugs other than the ones you mentioned. Good job!

Eibro
12-09-2002, 09:53 PM
I think you could do a little better on the color of the pieces. Even if you're limited to 16 colors some masking and shifting of those 3 bytes can still give you the best-bet for a certain color.

vasanth
12-10-2002, 12:43 AM
Wrell i am thinking of giving the user the option to change colors..... And any sugestions on the mouse interface....

Sebastiani
12-10-2002, 01:00 AM
I really like the game. Never used DOS graphics in my life, didn't realize that was possible. Good work.

vasanth
12-10-2002, 02:56 AM
Hi,
Thank you.... I have now added one more feature to my game... The defeated pawns are shrunk and displayed on the right side of the screen........... Well and now i have a better interface.. will be posting it after removing some bugging bugs....

Well i would appreciate if you guys gave me more ideas... And is it fine if i post the source here.(1400 lines..) do you guys have time to help me improve the coding structure....

Thanx in advance
Vasanth

ammar
12-10-2002, 03:54 AM
The game is nice, but I think you should do two things:
1- Let the player know what piece is selected.
2- Make both the selection and the movment with the left mouse click.

Good Job...

vasanth
12-10-2002, 10:54 AM
Added that feature and made the mouse interface drag adn drop..

I am planning to add an undo button to undo moves.. Any number of moves should be undone till the starting point is reached.. I was planing to use double linked list for this.. by keeping track of the changes in each node where each node represents a move.. Is there a better way of doing it... WHat do you think of using a file to store the moves instead of a list..

ammar
12-10-2002, 03:20 PM
Why don't you attach the game after the modification...
I would like to see it