Wordrack
Play solo against Lex, or tap invite and send the link. Whoever opens it first takes the other seat.
- Board
- 15 by 15, 100 tiles, two blanks, standard premiums
- Dictionary
- 178,689 words, sitting inline in the page
- Server
- 277 lines of Node, two dependencies, no database
- Definitions
- 112,129 glosses, so it can tell you what Lex just played
How Lex plays
It finds every legal move each turn. On hard it ranks them by score plus what the leftover rack is worth: an S is about seven and a half points of future value, a blank twenty-five, a Q costs six.
Once fewer than seven tiles are left in the bag it drops rack value and plays for points, because there is no future to plan for. Easy mode caps itself around fourteen.
Online play
Invite codes leave out i, l, o, zero and one so they survive being read aloud. If two people open the same link at once, the joiner takes a five-second lease on the seat and re-reads before writing; anyone later becomes a spectator.
The coach is switched off in online games.
How it is built
One HTML file of about 180,000 lines, nearly all of it the word list. No build step, no framework.
The game was originally written against a hosted storage and identity interface. The server reimplements that same interface against plain Node and steps aside if the original is present, so the game code was never told it moved.
