Inspiration

We wanted to capture the universal frustration of dealing with unpredictable traffic. The "hook" is the contrast between the strict rules the player must follow (speed limits, safe braking) and the absolute chaos of the AI drivers around them.

What it does

Drive Safe is an endless arcade racer played directly in Reddit feeds. You swipe to change lanes and tap to manage speed. You must obey dynamic speed limits while dodging erratic AI drivers and road hazards. Brake too hard or drive too slow, and you'll cause a pile-up! It features daily challenges and persistent leaderboards.

How we built it

Frontend: Phaser 4 inside a Devvit Web iframe for smooth 30+ FPS gameplay. We used procedural generation for visuals to ensure instant loading. Backend: Hono running in Devvit's serverless environment, written in TypeScript for end-to-end type safety. Data: Devvit's Redis integration tracks high scores, leaderboards, and player ranking tiers. Integration: A custom inline splash screen natively in the Reddit feed lets users see stats and jump straight into the game.

Challenges we ran into

Balancing the touch controls for mobile webviews was tough. We had to ensure lane changes felt snappy (under 200ms) and build a "safe lane guarantee" algorithm so the procedural spawner never creates impossible-to-dodge situations. Optimizing Phaser to run smoothly without external image assets also required heavy tweaking.

Accomplishments that we're proud of

The seamless Reddit integration! We love that users can scroll their feed, see their rank on our inline post, and instantly drop into a 60-second high-adrenaline race. Getting a full Phaser game with persistent global leaderboards running entirely on Devvit's serverless architecture is a massive win for us.

What we learned

We learned how to optimize games for zero-install webview environments. By relying on procedural generation instead of heavy image assets, we discovered how to keep initial payloads tiny. We also leveled up our TypeScript skills by sharing types directly between the Phaser client and the Hono backend.

What's next for Drive safe

Phase 2 includes "Ghost Races" so players can challenge their friends' recorded runs. We're also planning a cosmetic progression system to unlock new vehicle styles, and deeper subreddit integration where the community can vote to trigger special weather events or new obstacles!

Built With

Share this project:

Updates

Submission history