Live data from Hacker News

Static Chess

val.town

71–80 of 127 posts

Re: Static Chess

#71
post #38

This is great. Suggest one additional bit to show black at the bottom. That way the player of black is not handicapped by playing from an upside down position. Or just rip off the chess piece design of this other minimalist chess board simulator, which is never upside down: https://mirrorchess.com/ (It's ok, I made it.)

All pieces can move everywhere...? And no rules seem to be in effect. What's the purpose of this?

Re: Static Chess

#72

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.

[deleted]

Re: Static Chess

#73

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.

It doesn't even really need to be rendered by a backend. An SPA with pushState and it could literally be just a single file.

Re: Static Chess

#74

> When Google indexes this site will we successfully compute all possible chess moves? How do spiders know when to stop spidering when they keep getting original content? I assume there's a Gordian solution to the Halting problem like a limit to bytes or seconds. But if you applied the same rules to ebay.com and val.town that doesn't scale.

There's a lot of heuristics. Big sites get more crawl time. Some crawlers will back off if pages are slow. There's usually some sort of 'interestingness' calculation, so repetitive content won't get crawled as much.

Re: Static Chess

#77
Bruteforcing all the possible moves into a static set of files. I wonder how much space it does occupy, considering that small files take more space than large files with the same amount of bytes

Re: Static Chess

#78

Earlier quoted context omitted.

Chess960 also has different castling rules from normal chess though, and the site can't know it should use those just from the FEN?

The main difference is that the FEN no longer only encodes castling to the king's or queen's side. It must fully encode which file for each side. Castling _rules_ are the same, just the castling _location_ can change. https://www.chessprogramming.org/Forsyth-Edwards_Notation#Ch...

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 regular notation is insufficient.

The KQkq still unambiguously mark which player can castle to which side, and once either a rook or King move for the first time, you just remove the corresponding letter(s). What am I missing?

Re: Static Chess

#79

Earlier quoted context omitted.

The main difference is that the FEN no longer only encodes castling to the king's or queen's side. It must fully encode which file for each side. Castling _rules_ are the same, just the castling _location_ can change. https://www.chessprogramming.org/Forsyth-Edwards_Notation#Ch...

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.

Re: Static Chess

#80
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.

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.

Post reply on HN