Azonova product case study

Topzle — a game room built around people

Topzle brings games, conversation, and friendly competition into one responsive room. Players can find a public match or invite friends privately, then play with chat, optional audio and video, AI opponents, live presence, rematches, and room-level results working together.

React + TypeScript Cloudflare Workers Durable Objects Supabase + PostgreSQL Realtime audio + video Game AI + local ML
Topzle game table surrounded by chess, Ludo, drawing, and social play elements
One digital table for playing, talking, inviting friends, and coming back for another round.

1) Product brief

Many online games treat the match as the entire product. Topzle treats the room as the product. The game creates a reason to gather, while the room keeps players connected before, during, and after each round. That changes the design problem from “render a board” to coordinating identity, presence, communication, game authority, reconnection, results, and rematches without making the experience feel technical.

Start quickly

Play as a guest, sign in passwordlessly, join a waiting public room, or share a private invite.

Keep play social

Chat, calls, presence, turn alerts, reactions, results, and rematches stay attached to the room.

Work on every screen

Game-first layouts adapt to phones, tablets, and desktops without hiding the important controls.

Stay trustworthy

The server validates actions, while privacy-sensitive permissions appear only after a player asks for them.

2) The room experience

A player can choose a game and enter public matchmaking, create a private room, invite friends through native sharing, or start with a bot while waiting. Once inside, the selected game remains the visual focus. Player bubbles show who is connected and can expand into compact call previews. Chat floats on small screens, room controls stay contextual, and finished rounds show a clear result with a next-round action for every player.

Topzle logo with players connected across games and the words Play. Talk. Repeat.
Topzle’s identity is built around the spark created when people meet around a shared game table.

What the experience includes

  • Public and private rooms: matchmaking for quick play, plus invite-only rooms for friends.
  • Guest and account play: anonymous access remains available while signed-in players gain profiles, history, stats, friends, and room rejoining.
  • Room continuity: chat history, live presence, reconnect handling, cumulative room results, and fair next-round controls.
  • Responsive controls: game-specific layouts, movable player bubbles, compact mobile chat, and no fixed chrome competing with the board.

3) A reusable game system

Topzle supports different kinds of play without forcing every title into one UI or one rule model. The live room catalog includes Tic-Tac-Toe, Chess, Ludo, Connect Four, Battleship, Draw & Guess, Live Rock Paper Scissors, and Snakes & Ladders. Each game owns its visual layer, rules, timers, result language, AI capability, and guided lessons while sharing the same room protocol.

Game definition
catalog + capability model

Minimum and maximum players, AI support, time controls, and room behavior are declared rather than scattered through the UI.

Authoritative rules
validate every action

The server rejects illegal moves, owns turn order and timers, and broadcasts one canonical state to every participant.

Independent presentation
game-level CSS + interaction

Chess, Ludo, drawing, camera play, naval grids, and board animations load only the styles and assets they need.

Learning and results
guides + practice + room totals

Interactive tutorials explain rules with the real game UI, while results feed rematches, room summaries, and player statistics.

4) Real-time architecture

The architecture separates durable product records from fast room coordination. A Cloudflare Worker provides the API boundary. Every active room is coordinated by a SQLite Durable Object that serializes actions, persists game events, manages timers, tracks presence, and fans state out over WebSockets. Supabase stores account, profile, catalog, social, moderation, and reporting data under row-level security.

Web, PWA, and mobile

Responsive React interfaces share typed contracts with the Expo mobile foundation.

Worker API

Authentication, validation, matchmaking, visitor context, support, and protected platform operations.

Room Durable Object

One ordered authority for game state, WebSockets, presence, chat events, deadlines, and reconnection.

Supabase

PostgreSQL persistence, authentication directory, row-level security, profiles, stats, and admin data.

Cloudflare Realtime

SFU-based audio and compact video with application-level budgets and per-player controls.

Admin operations

A separate authenticated console for safety, support conversations, feature controls, rooms, and users.

Core rule: the client proposes an action; the room authority validates, persists, and broadcasts the accepted result. Reconnects recover from snapshots and ordered events instead of guessing what happened.

5) Communication and presence

Communication is integrated without assuming permission. Joining a room never opens the camera or microphone. A player explicitly starts video or audio, can independently mute or stop either track, and can hide any player bubble. Speaking indicators, compact previews, typing state, sent/delivered/read receipts, chat history, turn sounds, join sounds, chat alerts, and attention-aware tab titles make the room understandable even when attention shifts elsewhere.

  • Clean exits mark a player inactive immediately; interrupted connections receive a short reconnect grace period.
  • Late joiners receive bounded room chat history and the current canonical game snapshot.
  • Video uses compact player-bubble previews so communication does not take over the game surface.
  • Audio notifications and on-screen message previews can be disabled by the player.

6) AI and on-device intelligence

“Play with bot” is implemented as a game capability, not a generic chat assistant. Each supported game can use its own difficulty model, move evaluator, timing, and animation. AI turns pass through the same authoritative rules as human turns, which prevents a bot from producing a state a real player could not.

Topzle also uses local browser inference where privacy, latency, and operating cost matter. Draw & Guess can classify drawings from a bundled model, while Live Rock Paper Scissors recognizes gestures on the device. Camera frames and drawings do not need to be sent to an external AI API for recognition.

7) Identity, privacy, and safety

Fast entry and responsible controls are designed together. Guests can play without being trapped behind sign-in. Players who want continuity can use passwordless email or phone verification and complete a profile. Locale defaults help with country codes, currency, timezone, and date presentation, while display-country controls remain editable.

  • Permission minimization: camera, microphone, notifications, and other sensitive capabilities are requested only after a related action.
  • Age-aware onboarding: date-of-birth constraints, youth warnings, parental-consent flows, and guardian review are represented in the product.
  • Abuse resistance: Turnstile, rate limits, server validation, RLS, moderation foundations, reporting, and auditable support conversations.
  • Operational control: administrators can govern anonymous or unverified calling without disabling gameplay itself.

8) Performance and scale

Topzle is designed to scale by keeping hot room work local and bounded. A room does not scan global tables to decide whose turn it is. Durable Object state serializes concurrent actions; PostgreSQL tables are consolidated around reusable entities and indexed access patterns; histories are bounded; game CSS and recognition models load on demand; and deployment targets remain independently releasable.

Cost-aware real-time media

Calls use compact, resizable previews rather than full-screen video by default. Sender constraints, low and high video layers, active-speaker behavior, per-user leases, and a shared daily media budget limit unnecessary egress while preserving a useful social signal. Those controls can be raised deliberately as paid usage grows.

Testing and operations

Strict TypeScript contracts connect clients, APIs, room messages, and game engines. Unit and integration tests cover rules and room behavior, while production runbooks cover hosted Supabase migrations, Cloudflare deployments, secrets, cache purging, custom domains, and rollback boundaries.

9) Product status

The Topzle web experience, API, room authority, admin surface, game engines, account flows, matchmaking foundations, AI modes, tutorials, communication system, and deployment setup are implemented as one TypeScript monorepo. The next phase is continued physical-device testing, gameplay balancing, moderation operations, media tuning from real usage, and native store release work.

See the product in action

Open Topzle, choose a game, join a public match, or invite someone to a private room.

Visit Topzle ↗