logoalt Hacker News

Show HN: I rebuilt a 2000s browser strategy game on Cloudflare's edge

28 pointsby parzivaltlast Saturday at 12:17 PM23 commentsview on HN

I grew up in Germany in the early 2000s playing a browser game called Inselkampf. You built up an island, mined gold and stone, cut down trees for wood, raised armies, sent fleets across an ocean grid, joined alliances and got betrayed by them. Same genre as OGame or Travian. It shut down in 2014 and I never found anything that replaced that feeling of checking in before school to see if your fleet had arrived and your alliance was still alive.

I finally built the version I wanted to play. Kampfinsel is live at kampfinsel.com right now with real players on it. It's not a straight copy of the old game. I gave it its own world. No magic, no gunpowder – just ballistas, fire pots, and slow ships crossing huge distances. Three resources: gold, stone, wood. Travel between islands takes hours, not seconds. It's slow on purpose.

The whole thing runs on Cloudflare's edge. Workers for the game logic and API, D1 for the database, KV for sessions and caching, R2 for assets and Durable Objects for per-island state and the tick system (fleet arrivals, combat, resource generation). There's no origin server at all. Making a stateful multiplayer game work inside Workers' CPU limits and D1's consistency model meant some non-obvious choices: resources are calculated on-read from timestamps instead of being ticked into the database, fleet movements live in Durable Object alarms and combat writes are batched. This helped me a lot!

The look is intentionally rough and text-heavy (Hi HN!): server-rendered HTML, tables, a parchment color palette, Unicode icons, no frontend framework, no build step. The only JavaScript is for countdown timers and auto-refresh. I wanted it to feel the way I remember these games looking, not how they actually looked. Honestly, it looks a lot like HN itself - tables, monospace, no chrome. If you like how this site looks, you'll probably feel at home.

No signup wall, no premium currency, no pay-to-win. Feedback very welcome, especially from anyone who played this kind of game back in the day or has opinions on running stateful stuff on Workers + D1 + Durable Objects. I'll be around for the next few hours.


Comments

avdelazeriyesterday at 9:00 PM

OGame and Travian are two names that really take me back. Those and Tribal Wars, I played them a lot back when I was a teenager.

show 1 reply
nickandbroyesterday at 9:03 PM

Very cool, though wouldn't using durable objects for a MMO type game become prohibitively expensive vs using websockets with a stateful server? I assume your game is not sending that many requests so its not too bad.

show 2 replies
parzivaltlast Saturday at 2:05 PM

Did anyone here actually played Inselkampf, OGame or Travian back then? If you have recommendation or the one and only feature you still remember.

show 1 reply
fusspawn_yesterday at 10:41 PM

Someone needs to bring back nukezone.nu

show 1 reply
parzivaltyesterday at 9:40 PM

funny side note: this started as me nerding around with Cloudflare's stack on vacation, just seeing what was possible. been a 1.1.1.1 WARP fanboy from day one. didn't intend to ship a game. showed an early version to a few friends and they just... kept playing. didn't say much, just kept logging in. that's when it hit me that other people might want this too. so here we are. hope you like it.

slateryesterday at 8:40 PM

It keeps asking me to accept the privacy policy when registering, but there's no privacy policy checkbox...? Firefox, macOS

show 4 replies
stavrosyesterday at 9:02 PM

Oh no, I remember those browser games, I will stay well away from them because they're the kind of thing that I will play for a month straight otherwise.

show 1 reply
aspire879last Saturday at 1:42 PM

[dead]