News · New this week
Lights Out: an F1 reaction duel built with Claude
A split-screen reaction duel for two players on one phone, and the bug where version one timed the finger lifting instead of touching.
Lights Out is a reaction duel for two people and one phone. The screen is split in half. Five red lights come on, then they go out, and whoever taps their half first wins. Tap before the lights go out and it's a jump start. You lose.
It's day five of a series where a random spinner picks the app and I build it with Claude, an AI coder. This time the spinner landed on a game that settles the argument with the friend who says he reacts faster than an F1 driver.
How a round plays
The rules fit in one breath. Two players each get half of the phone. The red lights go out, and you tap your half the second that happens.
Tapping early is the only way to lose before the race starts. A jump start counts against the player who went early, so you can't just hammer the screen and hope. You have to wait for the lights.
The duel and the jump start in the reel are test rounds. In the duel, player two won by less than a tenth of a second.
Version one lied
The first build looked fine until I checked it against a real tap. My actual reaction was 0.201 seconds. The app said 0.332.
That gap is too big to blame on a slow finger. The cause was that the app stopped the clock when my finger lifted, not when it touched. Every time it reported included however long I held the screen down.
For a game decided by fractions of a second, that's a broken result. It would also make a fast player look slow and could flip who wins.
Version one had a second problem. It ignored simultaneous taps, so two players hitting at the same moment weren't handled.
The fix
The fix was small. Version two listens for the touch itself, so the clock stops the instant a finger lands. It also uses the precise clock for the measurement.
Those two changes are the whole difference. Which event you listen to, and how accurate the timer is, decide whether the number on screen is the number you earned.
The takeaway for anything you time with a tap is to check the app against a reading you trust before you believe it. I only caught this because I had a real tap time to compare with. The app's number looked plausible, and it was still wrong by well over a tenth of a second.
Try it
If you build something that measures input, tap it yourself and compare the result to what you expect. Then check which event starts and stops your clock. A touch and a release are different moments, and the app will happily time the wrong one.
If you want to play Lights Out, comment LIGHTS on the reel and I'll send you the game. Then send it to the friend who thinks he's an F1 driver.



