Solitaire
Klondike in the browser, with undo, saved games and shareable deals, built on the same card kit as all my card games.
Solitaire is the classic one-player Klondike, built for the browser. It’s the newest of my card games, alongside Gin Rummy, Crazy Eights, Hearts and Spades.
What it does
- Undo, as many moves back as you like.
- Saved games, so you can close the tab and pick up where you left off.
- Shareable deals. Every deal comes from a seed, so
?seed=in the address gives you, or a friend, exactly the same game again.
How it’s built
All of my card games share one card kit: the deck, a seeded shuffle, the card faces, and a canvas card table (drawn with Pixi) where cards ease into place, lift on tap and drag between piles. Each game only adds its own rules.
Every game keeps the same rule: the state is a pure function of the seed and the ordered list of moves. That makes undo and saved games almost free, since a game is just a seed and a list, and it lets me test whole games automatically.
The games will get their own home for playing soon. Until then, the source is on GitHub.