Learn

What we learned making three web games multiplayer

Updated 2026-11-23

Short answer: the network code was rarely the hard part. What broke was everything around it: a script that blocked the page when a country's networks blocked its domain, rival cars drawn in one place and collided with in another, maths that Chrome and Safari round differently, quick match that never paired the right players, invite links nobody could find, and waiting rooms that didn't look like the game. Here's what happened in three live games on etheria.games, Turbo Rally, Sky Isle Karts and Firestorm, and what we changed in Joinable for every game.

1. Showing other players isn't multiplayer

On the first Turbo Rally test, two phones saw each other in Joinable's dock ("2 playing"), then each started its own solo race. Presence without shared play confuses players. So Joinable stopped being a widget and started running the whole session: invite or quick match, a waiting room, a countdown everyone shares, live standings, one podium and rematch. The rule since: if Joinable shows other players, it must be playing with them.

2. A blocked domain shouldn't mean a black screen

A tester in Turkey opened the Turbo Rally preview and got a black page. With a VPN it worked. The preview ran on Cloudflare's shared *.pages.dev domain, and Turkish providers have been reported blocking Cloudflare's shared domains. Some networks don't refuse a blocked domain; they never answer, and a page that waits for a script shows black.

Now Joinable loads only from its own domain, relay.getjoinable.com, always async, and games queue their setup with JoinableQ, which never runs if Joinable doesn't arrive. The rule: every game must still play solo when multiplayer doesn't load.

3. Draw and collide in the same place

Turbo Rally's cars glitched side by side. Rivals were drawn 100 ms in the past but collided with a prediction of "now", a car length apart at speed, and both phones applied the whole push. One smoothed estimate for drawing and colliding, and each phone pushing only its own car by half, cut the worst on-screen jump of a rival from 52 to 7. At 200–300 ms, predicting along the turn fixed the wobble on corners. Racing guide.

4. Players want their own name and their own car

After playing Turbo Rally online, the feedback was blunt: players couldn't change their names or choose different cars. Now each player has a card in the waiting room with their name and picks, and the game draws them with what they chose.

5. The waiting room must look like the game

Firestorm's online menu came out in Joinable's default colours: the same as Turbo Rally's. Neither game had passed a theme. Now Joinable's screens read the game's look by default (its theme, CSS variables, buttons and headings) and check contrast.

6. Browsers don't agree on maths

Firestorm is a real-time strategy game, made multiplayer with deterministic lockstep: only orders travel, and every device runs the same battle. A coding agent with only our public prompt and docs did the first version in about 66 minutes. Then a play-test, Chrome against Safari, went out of sync at tick 2412, with no orders anywhere near it.

The cause was Math.hypot, sin, cos and atan2 in the simulation. Chrome's and Safari's engines may round them differently in the last digit, and a battle feeds each result into the next tick. The kit now has a sixth determinism rule, and the self-test names such calls inside step(). Fingerprints compared every second are what caught it. Later, a 4 v 4 run compared 71,120 fingerprints over 10,160 ticks with 0 differences. Make an RTS multiplayer.

7. Quick match needs the same build, the same format, and real testing

8. Put the invite first

Playing Firestorm online, our own founder found the invite link buried. Now the first choice is Invite a friend: on a phone the share sheet opens at once, on a computer the link is already copied. A room with no friend in it is where people give up. Invite links vs matchmaking.

9. Let developers test at the real size

Sky Isle Karts' developer couldn't try an eight-kart grid locally: free rooms held 4. Now rooms on localhost hold 8 on every plan. The same feedback brought --players 3 to 8 and a testDrive() hook to the self-test, which used to sit waiting for a race nobody drove, plus AI racers for empty grid slots.

10. Lost messages and reloads happen mid-battle

A live Firestorm battle froze for good on "Waiting for" one player: a turn sent into a dying connection was lost. Now the room asks for every gap again, and a gap that can't be filled counts as no orders after 10 seconds. A player who reloaded mid-battle came back as a stranger; the tab now keeps their seat.

11. Never cut players off mid-game

Firestorm's first 4 v 4 battles stopped at 15 minutes, the default round limit. Lockstep rounds now allow 2 hours. The same rule runs through billing: when a game's plan runs out, only new online rooms pause. Rounds already playing finish, and solo play always works.

What it adds up to

Make your own game joinable: paste the prompt into your coding agent. More games.

FAQ

Why did my multiplayer game show a black screen in some countries?

Often because the multiplayer script was loaded without async from a domain some networks block, such as Cloudflare's shared *.workers.dev or *.pages.dev. The browser waits for an answer that never comes. Load it async, from your provider's own domain.

Why do lockstep games desync between Chrome and Safari?

Functions such as Math.sin, cos, atan2 and hypot can round differently in the last digit between browser engines, and the simulation feeds each result into the next tick. Use Math.sqrt with multiplication and lookup tables inside the simulation.

How long does it take to make an RTS multiplayer with Joinable?

Firestorm's first two-player version took a coding agent about 66 minutes from the public prompt. Tiny Front, a small reference RTS, took a fresh agent 6 minutes.

Which games use Joinable?

Turbo Rally, Sky Isle Karts and Firestorm, all playable on etheria.games.

Copy the prompt for your coding agent or sign up free