


The PGN output is not an issue, click square D8 and C8 and you'll get it.Jeremy Bernstein wrote:Paolo's done an amazing job with it -- great to see him here. I have a pretty clear idea now of how to generate the FEN for the current position (at least as part of the PGN output, but possibly also as a display element, if it looks ok). If I get to it this week, that's great, otherwise it'll have to be in a couple of weeks (Chalkidiki and JavaScript don't mix).
Hmmm, as usual, few moment after posting I got the idea how to do that... so I should post shortly a new version of pgn4web (it will be v1.98) that generates the FEN string of the current position.pgn4web wrote: The FEN output is more of an issue, it's not at all easy to generate a FULLY CORRECT FEN string. The issue is with the "last but one" number in the FEN string: the "Halfmove clock". The javascript tool does not track at the moment this information (it would likely require adding a new array HistHalfmove, similar to HistEnPassant). This is why the FEN output is not there, I could not do all that work nor live with generating a FEN string with an incorrect "Halfmove clock".
Anyway, any program dealing with FEN would be able as well to take the game PGN and work from there the position you are looking for, just a couple of clicks away.
Great! One more request -- would it be possible to display the + or # state of check or mate moves in the move list?pgn4web wrote:Hmmm, as usual, few moment after posting I got the idea how to do that... so I should post shortly a new version of pgn4web (it will be v1.98) that generates the FEN string of the current position.pgn4web wrote: The FEN output is more of an issue, it's not at all easy to generate a FULLY CORRECT FEN string. The issue is with the "last but one" number in the FEN string: the "Halfmove clock". The javascript tool does not track at the moment this information (it would likely require adding a new array HistHalfmove, similar to HistEnPassant). This is why the FEN output is not there, I could not do all that work nor live with generating a FEN string with an incorrect "Halfmove clock".
Anyway, any program dealing with FEN would be able as well to take the game PGN and work from there the position you are looking for, just a couple of clicks away.
Nope. The + and # were entered as comments in the example above -- the comments appear in light grey -- if you remove the comments, you'll see that + and # are automatically attached to the move.64x wrote:Awesome! In the example above + and # become duplicated in the display, I assume because the notation was already in the original pgn. I wonder if a check for existence can be added before inserting.
Yes. That was the intent.64x wrote:I see that now. I got confused, as B8 strips out the comments on the PGN. Was that the intent?