Browser game, built for phones

Hold to inflate.
Let go to vent.

Bottom Time is a side-scrolling scuba game with one control. Everything else is dive physics: the air in your BCD expands as you rise, your tank drains faster the deeper you go, and your tissues load nitrogen on the same decompression model dive computers use. There is a new reef every day and a ghost of your best dive to race.

A scuba diver at 9.3 metres finning over coral mounds with sea fans, table corals and a barrel sponge, sun rays from above, a school of fish in the distance and the dive computer readout in the corner
Daily Dive #1, 204 metres in
A diver above a sunken ship hull with portholes and sponges on the deck; below the deck a swim-through, where a viewfinder ring marks a frogfish worth 332 points
A wreck swim-through, and a frogfish worth 332 points
A diver at 26.8 metres beside a reef wall in dark blue water, torch beam on, with the score showing a 3.7 times depth bonus
Over the wall at 26.8 m: torch on, points worth 3.7 times

Where it fits

Keystone builds software people lean on: an emergency hotline directory, a booking system, a storefront, public data tools. The rules are the same on every project. It has to work on the phone in your hand, and the numbers behind it have to hold up when someone checks.

A game is the least forgiving place to follow those rules. Nobody reads a changelog before deciding a game stutters or cheats; they close the tab. So Bottom Time got the treatment everything else gets: a model we can test, a replay we can verify, an autopilot that checked the levels can be survived, and a written list of every shortcut.

Phone first

One thumb on the glass is the whole control. Physics runs at a fixed 60 steps a second and the picture is interpolated between them, so a 120 Hz phone is smooth without the physics changing. It respects the notch, buzzes on Android, and needs no network once it has loaded.

Numbers that hold up

The same seed and the same inputs give the same dive, bit for bit. That is what brings your best run back as a ghost, and what would let a leaderboard re-run a submitted score instead of trusting it.

Built by a diver

The founder is a TDI/SDI Divemaster. The runaway ascent near the surface, the tank that drains four times faster at 30 metres, the ceiling that pins you down after a deep excursion: that is how diving feels, not how games usually pretend it does.

It is also the pocket edition of TRIM, our dive simulator for instructors. Same physics, different job. TRIM is a classroom tool you spend an hour in. Bottom Time is a minute anyone can pick up, and a good reason to ask what that red line on the screen means.

The physics you can feel

This is the model the game runs, not an illustration of it.

Depth Pressure Same air in your BCD Wetsuit lift lost Air per breath Score Deco ceiling after 60 s
0 m 1 atm 100% 0 L x1 x1 none
10 m 2 atm 50% 1.6 L x2 x2 none
20 m 3 atm 33% 2.1 L x3 x3 2.2 m
30 m 4 atm 25% 2.4 L x4 x4 7.7 m
40 m 5 atm 20% 2.6 L x5 x5 13.3 m

Pressure is 1 atm plus 1 for every 10 metres of seawater. Ceilings are the shallowest depth the tissue model allows after holding that depth for a minute of play, at a gradient factor of 70.

Rising feeds itself

Near the surface a small change in depth is a big change in volume, so an ascent speeds itself up. Most first dives end at the surface. That is Boyle's law, and it is why real divers vent early.

Depth costs air

Every breath at 30 metres takes four times the gas it would at the surface. Going deep pays four times the points and empties the tank four times as fast.

Nitrogen has a memory

Stay deep and the tissue model builds a ceiling you cannot swim above. Cross it and the dive ends. Fast tissues clear quickly; the slow ones make you wait.

How it is built

Deterministic simulation

The physics module never touches the page, never calls a random number generator and avoids trigonometry inside a step, so a run plays out the same way every time. Rendering reads the state and never writes it.

Ghosts from button presses

Your best dive is stored as the moments you pressed and let go, delta-encoded. Replaying that list against the same seed rebuilds the whole dive. That replay is the ghost you race.

A new reef every day

The reef is generated in 40 metre chunks from a hash of the day and the chunk number, so any chunk can be built in any order and dropped once you pass it. Everyone gets the same Daily Dive.

Light that behaves like water

Red fades first as you descend, then green, following Beer-Lambert absorption per colour channel. The camera strobe restores true colour for a moment, and a torch comes on as the light goes.

No dependencies

Canvas 2D, WebAudio and plain ES modules. No framework, no build step, no image or audio files: the reef, the fish and the regulator breathing are drawn and synthesised in code. View source works.

A reef that reacts

Fish school and scatter when you swim into them, sunlight moves across the sand, and below 20 metres the plankton glows as you pass. None of it can touch the score, because none of it lives in the simulation.

How we know it is fair

Fair is a claim, so it gets evidence.

  • Eight unit tests run with the rest of this site. They check that a replay reproduces a dive bit for bit, that input recordings round-trip, that the same gas takes a quarter of the volume at 30 metres, that air use scales with pressure, that the decompression ceiling grows with time at depth, that a held inflator ends in an uncontrolled ascent, that reef chunks come out identical in any order, and that the seabed never rises within 6 metres of the surface on 40 test reefs.
  • A lookahead autopilot flew 30 generated reefs. It tries eight inflator rhythms 2.5 seconds ahead on the same deterministic simulation and keeps the best. 24 runs were still going at 150 seconds, 4 ran out of air, and 2 died in ghost-net sections where the generator had stacked obstacles too close together. Seabed hazards are now kept clear of nets and arches.
  • An earlier autopilot run hit a coral mound that rose to 1.5 metres below the surface, a gap no player could pass. The seabed now flattens toward 6 metres and never crosses it.
  • The same autopilot flies the title screen, and it flew the dives in the screenshots on this page.

What is simplified

Every shortcut, written down, so nobody mistakes a convenience for the truth.

Time is compressed. A real minute of nitrogen loading happens in 1.5 seconds of play, and the diver moves up and down faster than a real one would.

It uses 4 of the 16 ZHL-16C compartments, the fast ones a short dive actually loads, with a gradient factor of 70.

Light absorption is softened. Real seawater strips red faster than the game does; at true rates the reef would be grey by 10 metres.

The diver swims forward on their own, and the floating air tanks are a game device. Nobody hands you gas on a real dive.

It has not had a big playtest yet. The constants were set by measurement and by the autopilot. Real players will move them, and we will say when they do.

It is not a training tool. For practising the real thing, there is TRIM, and then there is an instructor.

Go diving

Any phone or desktop browser. One thumb, about a minute a dive.

Today's Daily Dive

The same reef for everyone today. Beat your ghost, fill the logbook.

Play

TRIM

The dive simulator behind the idea, built as an instructor's aid.

See TRIM

Work with us

Need software that holds up this well under a thumb?

Get in touch