logoalt Hacker News

daniel_rh • yesterday at 7:08 PM • 3 replies • view on HN

Author here: in 2015, I was playing the classic Wing Commander in DOSBox and suddenly realized the game state fit in the 64k data segment.

Over ten years my brother and I went through a set of experiments (stop and go, turn, communicate) while probing the memory. We uncovered where the variables were, how to inject calls into the game functions, and how to sync the gamestate across the network, so we can fly the story missions together.

My favorite finding is that the camera lives in entity slot 0x3D, which is possibly a "3D" reference by the original developers.

You can play it at https://fireflyk64.github.io/dosbox in browser. If you own Wing Commander, drag in the installer since no game files are hosted. If you don't, the page will load the original DOS/3Dfx version of Vega Strike, before I open sourced it. I upscaled and redid DOS Vega Strike art using AI, but it now has multiplayer and a similar feel.

I'll be in the lobby for the next few hours if anyone wants to fly together.

Disclosure: I also used AI for the final step to help compile for the browser and port our TCP networking stack to WebRTC with voice and solve a few lingering bugs.


Replies

cadr • yesterday at 9:02 PM

I don't know if I'm more impressed with the result, or that you kept coming back to it for a decade. Super cool!

frikk • yesterday at 8:47 PM

helllllll yeah. i think it's awesome when domain experts and clever humans use AI to automate the implementation after they've designed the path through the forest. Nice work.

➕ show 1 reply