Live data from Hacker News

Static Chess

val.town

81–90 of 127 posts

Re: Static Chess

#81
> Plain, brutalist, no bloat chess. Every page is only html and css. Every chess move is made by clicking a link. Send a link to your friend and they'll send you one back to make your move. No silly animations or slick interactivity to trip up your gameplay. When Google indexes this site will we successfully compute all possible chess moves?

> Functionality is quite limited, and things might be broken. Please let me know if you find bugs!

Not sure if the first paragraph boasts the pros or the cos of this sort of implementation.

It's one thing to market implementations done in unusual ways with the intent of exploring the possible. It's another to portray software implemented with the right technologies as : bloat, silly animations, slick interactivity to trip up your gameplay.

It doesn't help that the second paragraph showcases shortcoming of this kind if implementation.

It could all just be sarcastic and I fell for your trap.

Well played and clever implementation!

Re: Static Chess

#82
post #79

Earlier quoted context omitted.

One of the rooks might move over to the other side during the course of the game, and then it's no longer unambiguous which one is the castling rook. E.g., if you have your king on e1, a rook on f1 and another one on g1… can you castle if the f1 rook moves? Can you castle if the g1 rook moves? Just “kingside” won't tell you the difference.

I mean technically it still isn’t ambiguous because you could just refer to the starting position to see which rook is allowed to move. Which of course is annoying to implement, but you do already have to keep state on the history of the game to determine if moves are legal, e.g. you can’t castle twice.

The entire point of a FEN is that it describes the entire board state without having to know anything about the history.

> Which of course is annoying to implement, but you do already have to keep state on the history of the game to determine if moves are legal, e.g. you can’t castle twice.

No, that's what the castling rights field in the FEN is for. Once you castle, you zero out both the k and q bits.

Re: Static Chess

#83

Earlier quoted context omitted.

Static as in no XmlHttpRequest.

I can start a game on Lichess, resign it right away, enter analysis mode, then disconnect from the internet and continue to use the board (in the same way that one can use the board on site we are discussing here), so Lichess's analysis board does not use XmlHttpRequest either.

You don't need to resign a game to enter analysis mode. It's available from the menu.

Re: Static Chess

#84
post #67

Earlier quoted context omitted.

It uses the FEN, which is the standard notation for chess positions. And it's the right choice, IMO -- if two positions are the same they should have the same URL, regardless of the specific move order used to reach it.

No it shouldn’t. Move history has to be encoded so draw by threefold / fivefold repetition and fifty moves / seventy five moves can be claimed / detected.

The half-move counter in the FEN takes care of the 50/75 move rule. You do need the history if you want to implement the threefold/fivefold repetition rule, but it's rare that it is actually relevant for e.g. a chess engine's strength.

Re: Static Chess

#85

This isn't really static right? It's still dynamically rendered by the backend each time you request the page. There aren't 999999919291293923 pre-rendered pages living on a server somewhere.

Technically speaking, it would require ~ 4.8 * 10^44 pages to cover all legal chess positions [1]. But they're happy to serve utterly illegal positions like https://chess.maxmcd.com/rnbqkbnr/qqqqqqqq/8/8/8/8/QQQQQQQQ/... as well.

[1] https://github.com/tromp/ChessPositionRanking

Re: Static Chess

#86
post #16
post #10

Earlier quoted context omitted.

it would be cool if the url was just the chain of the moves. then you just paste the move chain in the URL and you get the board state.

huh, I originally thought this would create unusually long URLs, but if it's just the sequence of moves it could stay pretty small. might more fun too, representing each state of play instead of just the board position. Also easily compressible if size is an issue: https://mbuffett.com/posts/compressing-chess-moves Would also mean all rules can be represented, and you'd be able to do cool things like highlight the pr…

[deleted]

Re: Static Chess

#87
post #16
post #10

Earlier quoted context omitted.

it would be cool if the url was just the chain of the moves. then you just paste the move chain in the URL and you get the board state.

huh, I originally thought this would create unusually long URLs, but if it's just the sequence of moves it could stay pretty small. might more fun too, representing each state of play instead of just the board position. Also easily compressible if size is an issue: https://mbuffett.com/posts/compressing-chess-moves Would also mean all rules can be represented, and you'd be able to do cool things like highlight the pr…

> it's just the sequence of moves it could stay pretty small.

It could also be pretty long, 5898 moves to be precise when using the 50-move rule [1].

[1] https://www.youtube.com/watch?v=D5DXJxR3Uig

Re: Static Chess

#88
post #81

> Plain, brutalist, no bloat chess. Every page is only html and css. Every chess move is made by clicking a link. Send a link to your friend and they'll send you one back to make your move. No silly animations or slick interactivity to trip up your gameplay. When Google indexes this site will we successfully compute all possible chess moves? > Functionality is quite limited, and things might be broken. Please let me…

[flagged]

Re: Static Chess

#89
post #79

Earlier quoted context omitted.

I admit that while I do regularly play chess, I'm not super well versed in either FEN nor Chess960. That said, I've been trying to figure out why you would need a different notation for Chess960 for half an hour now, and I just can't figure it out. All explanations I'm seeing just make some vague mention about ambiguity in the regular notation for Chess960, but I, personally, can't think of a situation in which the r…

One of the rooks might move over to the other side during the course of the game, and then it's no longer unambiguous which one is the castling rook. E.g., if you have your king on e1, a rook on f1 and another one on g1… can you castle if the f1 rook moves? Can you castle if the g1 rook moves? Just “kingside” won't tell you the difference.

Ah, that's the possibility I wasn't thinking of. Thank you.

Re: Static Chess

#90
post #81

> Plain, brutalist, no bloat chess. Every page is only html and css. Every chess move is made by clicking a link. Send a link to your friend and they'll send you one back to make your move. No silly animations or slick interactivity to trip up your gameplay. When Google indexes this site will we successfully compute all possible chess moves? > Functionality is quite limited, and things might be broken. Please let me…

I'd wager that it's a humorous description, taking certain virtues to an illogical extreme.

The limited functionality is nevertheless likely referring to features beside the ones described as bloat.

Post reply on HN