← Back to case studies
Dossier 01 · 2024
SolBTL hero landscape
Fig. 001 · Cover · SolBTL landscapeiPhone · Android
§ SolBTL · Naval battle on Solana

A game of Battleship
that settles on-chain.

Rebuild Battleship for Solana. Every move written to the chain, every win paid out in SOL in under a second.

§ The original brief
§ 01
I
The vision

SolBTL started as an experiment. Most Web3 games ask you to understand the blockchain before you can play. Wrap the on-chain mechanics inside a game people already know how to play, and that problem mostly goes away.

Battleship was the obvious pick. The rules are five sentences. Every move and result gets written to the chain, so the game is provably fair, but you don’t have to read a block explorer to trust it.

It shipped as the first game on the Dubs platform. Matches settle on Solana in under a second. Winners get paid out on-chain.

§ 02
II
Core features

Eight things the game has to do.

  1. 01

    Turn-based combat

    Grids from 5×5 up to 10×10. Six ship types. Three placement modes.

  2. 02

    On-chain payouts

    Every game gets written to Solana. Winner gets paid out on-chain, without a middleman.

  3. 03

    Social

    Friend list, player search, challenges, and a leaderboard with five ranks.

  4. 04

    Provably fair

    Both moves and results sit on Solana. Anyone can verify a match after the fact.

  5. 05

    Three modes

    Wagered matches, free matches, and a practice mode against a bot.

  6. 06

    Made for mobile

    React Native and Expo. Gesture-based placement, haptic feedback, ambient audio.

  7. 07

    Customisable

    Six ship colour schemes, three placement modes, adjustable haptics and audio, dark and light themes.

  8. 08

    Ranks

    Climb from Cadet to Admiral as you win matches.

§ 03 · Gameplay

Placement, in motion.

Fig. 002 · Placement phase · draw, tap, or hybrid
§ 04
III
How it works

Five steps, tap to tap.

  1. 01

    Create or join

    Pick a grid size. Optionally set a SOL wager through Dubs.

  2. 02

    Place ships

    Draw, tap, or a mix of both.

  3. 03

    Play

    Take turns firing at coordinates. Hits, misses, and sinks update in real time.

  4. 04

    Win

    Sink the other fleet. The game resolves on Solana.

  5. 05

    Get paid

    Winner gets the SOL, on-chain, in seconds.

§ 05 · Screens · click to enlarge
12 plates
§ 06
IV
Ranks

From Cadet to Admiral.

Cadet0–4 wins
Lieutenant5–9 wins
Commander10–24 wins
Captain25–49 wins
Admiral50+ wins
§ 07
V
Stack

What powers it.

React Native
Cross-platform mobile client
Expo
Build tooling & OTA updates
TypeScript
End-to-end type safety
Solana Web3.js
Wallet & on-chain settlement
Socket.IO
Real-time game state sync
Dubs SDK
Wagers & prize resolution
React Navigation
Tab / stack routing
Reanimated
Gesture-driven animation
§ 08
VI
Decisions

Architecture — what we chose, and why.

  1. 01

    Real-time layer

    WebSockets via Socket.IO. Room-based updates for placement, moves, and end-of-game. Auto-reconnect, backoff, and background pings to survive the phone going into a locked state.

  2. 02

    Payouts on Solana

    A wagered game creates an on-chain instance through the Dubs SDK. When the game ends, the contract settles and pays out the winner. There is a retry on failure so nothing gets stuck in transit.

  3. 03

    Feel

    Gesture Handler and Reanimated. Drag to place ships, haptic feedback on hits and misses, ambient audio. Deep-ocean palette, high-contrast pieces so nothing gets lost in a quick game.

  4. 04

    State

    One BattleshipContext runs the whole lifecycle: create, lobby, place, play, resolve. It coordinates REST for persistence and the WebSocket for live updates. Optimistic on the UI side.

§ End of case study

Got something to build?
Send us the notes.