inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Chess
Jan 14, 2014 22:50:05 GMT -8
Post by Chris on Jan 14, 2014 22:50:05 GMT -8
This is more geared towards actually playing the game in a thread. I put the converter on hold for now whilst I try and get this working. I already have it though taking in a block of linefeed seperated EPD statements and extracting the FEN from them to display. when I can get the play system working, I was going to incorporate a converter system that keeps track of positions and converts to PGN if requested. an import/export system would be farther in the development. I was referring to gameplay, the EPD is capable of keeping track of those things you mentioned (points 1 and 2) so you would generate an EPD after each halfmove recording any change to the arranged pieces on the board as well as en passant, castling, turn plus any opcodes or commentary (e.g. "white offered draw after this move", SANmove "f8=Q") which would make exporting the full game to PGN format (eventually in the future) that much easier I have all the king path choices working now, and indeed had to use a loop for it, but I did something clever and just reused my same path function and had it return a list of each pieces available paths. after all opposing piece paths were collected, then a quick for loop for the king to check his paths didnt coincide and if it did, that square wasnt hilighted. special care had to be taken in the case of an opposing king or pawn since a king cant place itself in check, but it has to be collected as a danger square for the OTHER king in order to keep the other king from moving into check. and a pawn cant attack straight, so it had to be also checked for diagonal moves even without pieces to capture in order to make sure the king didnt place itself in check against a pawn. so now Im working on the castling aspect, which is going to be tricky since I just found the rule that not only can the king not end up in check after castking, but the square it moves THROUGH cant be in check either. also apparently you cant use castling to get out of check, which I didnt know. I will say Im glad I got the FEN editor working because it makes it really easy to generate test boards in order to test all these move/attack paths. If you want an editable version Chris let me know. I have it automatically show paths on piece hover for all boards displayed in posts for quick testing. It is indeed exhilarating coming up with your own workable solutions. I'm fine just cheer-leading, I don't really need an editable copy. I would make a suggestion though (if you have not already considered this) that in addition to highlighting move paths perhaps a different highlight color could be used for last move made (originating square and destination square) as well as another highlight color to indicate checks. I recall also considering animation for when captures were made but can't remember if I ever implemented. All of these lend greatly to awareness of what is occurring during the game by spectators and players alike.
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 20, 2014 2:55:29 GMT -8
Post by Wormopolis on Jan 20, 2014 2:55:29 GMT -8
update:
I now have it where you can challenge another player to a game, it tags them in the first post, and makes the subject YOU vs THEM (with actual names). on game creation, white immediately goes first and it brings up a board where you make your move. it highlights all the possible positions for each piece you hover. after you drag your piece to its destination, all hovers are shut off. you then choose "I moved" or "I forfeit" to complete your turn. when hitting "I moved", it creates a new thread and displays that threads game in the first post. replies are still available to allow comments and what-not. when the opposing player goes to look at thread, they will see a "Your move" button above the board. pressing it, brings up the same playable board and they make their moves. they get the same two buttons below the board to continue. the page refreshes and the board is updated in the first post. new "prev"/"next" buttons appear below the display board so anyone can see how the game progressed. I have it updating the EPD strings in the thread key each move to account for castling and en passant as well as whose turn it is.
things left: what to do on a forfeit animating castling handling en passant captures handling how to determine if in check/checkmate
|
|
Former Member
inherit
guest@proboards.com
131621
0
Nov 25, 2024 20:59:50 GMT -8
Former Member
0
January 1970
Former Member
|
Chess
Jan 20, 2014 10:54:25 GMT -8
Post by Former Member on Jan 20, 2014 10:54:25 GMT -8
Wormopolis, just finished reading through this whole thread, seeing the progress happen is crazy cool and I'm absolutely pumped about this plugin! Happy to use the library version for now but it sounds like the game-style one you're working on is going to be beyond epic, I can't wait and hope it isn't making you too insane!
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 20, 2014 10:58:45 GMT -8
Post by Wormopolis on Jan 20, 2014 10:58:45 GMT -8
Its definitely monopolizing my time..
|
|
Former Member
inherit
guest@proboards.com
131621
0
Nov 25, 2024 20:59:50 GMT -8
Former Member
0
January 1970
Former Member
|
Chess
Jan 20, 2014 11:08:43 GMT -8
Post by Former Member on Jan 20, 2014 11:08:43 GMT -8
I can tell! You've been working on this since, what, November? And clearly all the time going into how many possible variations there are and.. wow. I'm sure it'll be a great relief when it's over with at least, right?
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 20, 2014 11:18:49 GMT -8
Post by Wormopolis on Jan 20, 2014 11:18:49 GMT -8
probably biggest code so far. beat out skinview and tournament brackets...
|
|
Former Member
inherit
guest@proboards.com
131621
0
Nov 25, 2024 20:59:50 GMT -8
Former Member
0
January 1970
Former Member
|
Chess
Jan 20, 2014 11:20:20 GMT -8
Post by Former Member on Jan 20, 2014 11:20:20 GMT -8
Skinview? This is one I haven't heard of. But tournament brackets, wow. I'm not really surprised, though. There's so much you have to be able to anticipate and account for with something like this, it's a huge undertaking and really a crowning achievement. Slap this sucker on the top of your resume, get every job ever. /this is how real life should work
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 20, 2014 11:41:56 GMT -8
Post by Wormopolis on Jan 20, 2014 11:41:56 GMT -8
Skinview was a v4 code that put up a dialog window that let you select all the different style selectors from a forum, and you could change things in them while looking live at the site without reloading.
but it didnt actually affect the site until you cut and paste the final CSS back into headers.
|
|
Former Member
inherit
guest@proboards.com
131621
0
Nov 25, 2024 20:59:50 GMT -8
Former Member
0
January 1970
Former Member
|
Chess
Jan 20, 2014 11:47:40 GMT -8
Post by Former Member on Jan 20, 2014 11:47:40 GMT -8
Geez, that's really cool, so it was a pre-V5 visual editor. That would've been useful for me back in the day haha
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 22, 2014 1:35:13 GMT -8
Post by Wormopolis on Jan 22, 2014 1:35:13 GMT -8
ok so another quick update...
castling is now working with animation and saving placements kingcheck is in place, but now Im worried about how Im going to check for checkmate en passant not working, but EPD is in place so I should just have to check that string to see if a capture is possible if its your turn and you are in check, if make a move that doesnt take you out of check, it puts back the piece and alerts you you are still in check. if you put your opponent in check, it highlights the king square red and puts up some text saying king is in check
apparently IE doesnt like how Im highlighting cells, so I have to find a different way for IE.
and I should probably do more testing in chrome since chrome seems to bite me in the butt lately...
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 22, 2014 1:39:07 GMT -8
Post by Wormopolis on Jan 22, 2014 1:39:07 GMT -8
Oh and Chris, I forgot you had an account on my test forum so you can actually see the working copy there if you get curious. it only runs in the one board for chess.
|
|
inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Chess
Jan 24, 2014 16:36:46 GMT -8
Post by Chris on Jan 24, 2014 16:36:46 GMT -8
ok so another quick update... castling is now working with animation and saving placements kingcheck is in place, but now Im worried about how Im going to check for checkmate en passant not working, but EPD is in place so I should just have to check that string to see if a capture is possible if its your turn and you are in check, if make a move that doesnt take you out of check, it puts back the piece and alerts you you are still in check. if you put your opponent in check, it highlights the king square red and puts up some text saying king is in check apparently IE doesnt like how Im highlighting cells, so I have to find a different way for IE. and I should probably do more testing in chrome since chrome seems to bite me in the butt lately... If I am remembering correctly, identifying checkmate is fairly easy once you determine the possible paths a king can move is NONE and the king is also in check by at least one opposing piece. You'll also need to determine stalemates (which gives me a headache just vaguely remembering), there's a 50 move without a capture rule and also a thrice consecutively repeated sequence of moves although that could be left up to the players to determine for the time being. Great progress Wormo! Loving that check indicator! Oh and Chris, I forgot you had an account on my test forum so you can actually see the working copy there if you get curious. it only runs in the one board for chess. That's if I can remember the password I'll hold a seance to contact my long dead memories for a clue
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 24, 2014 16:39:44 GMT -8
Post by Wormopolis on Jan 24, 2014 16:39:44 GMT -8
checkmate has one part that makes it a little harder. not being able to move and being in check, true, is easy enough. but moving a piece into the way of the current check, or capturing the current piece causing the check will prevent a checkmate. its THAT part that is time consuming because I have to check paths crossing paths.
|
|
inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Chess
Jan 24, 2014 17:03:11 GMT -8
Post by Chris on Jan 24, 2014 17:03:11 GMT -8
True, I forgot that each piece has to also be checked to see if they can come to the aid of the king either through directly attacking the threat or running interference and in addition those pieces have to themselves be checked to make sure a potential move does not further endanger the king (e.g pinned) or the move is considered illegal (and therefore considered a checkmate if all ancillary pieces can not make a move). If the king has an escape route but then no move after that it is then a stalemate if my memory holds up.
Time consuming to program but computed in mere milliseconds, this Bill Gates guy might be on to something after-all...
|
|
inherit
King Oligochaete
126470
0
Feb 24, 2021 12:23:15 GMT -8
Wormopolis
Stop rating plugins with 1 star that dont deserve it.
20,002
June 2008
tbserialkillers
Wormo's Mini-Profile
|
Chess
Jan 24, 2014 18:31:05 GMT -8
Post by Wormopolis on Jan 24, 2014 18:31:05 GMT -8
which is why I took a break from it to do some smaller requests...
|
|