logoalt Hacker News

Show HN: I spent 3 years reverse-engineering a 40 yo stock market sim from 1986

305 pointsby benstopicslast Tuesday at 2:44 AM117 commentsview on HN

Hello my name is Ben Ward for the past 3 years I have been remastering the financial game Wall Street Raider created by Michael Jenkins originally on DOS in 1986.

It has been a rough journey but I finally see the light at the end of the tunnel. I just recently redid the website and thought maybe the full story of how this project came to be would interest you all. Thank you for reading.


Comments

jhbadgertoday at 10:39 AM

I think it is pretty unreasonable to call CP/M "primitive beyond belief". It was basically equivalent to MS-DOS in capability -- after all, MS-DOS was basically an unlicensed clone of CP/M for the 8086.

tommicatoday at 10:33 AM

Really cool article! The solution to wrap the engine in a modern UI was a good one. I would have fallen to the trap of trying to port the whole thing, like all the other companies did.

Out of curiosity, how are the things tested? Or is checking core-engine doing things right only up to the developer and their tribal knowledge?

show 1 reply
JohnHammersleylast Tuesday at 10:10 AM

This is such a well written story, and congratulations Ben, it sounds like it's been a lot of hard but ultimately successful work!

I know you'll deservedly get a lot of credit for all your work in remastering the game, but you should also get credit for how you've woven this narrative together, it's a lovely read. Thank you for taking the time to write it up, and good luck with the Steam release, and whatever project you take on next! :)

show 2 replies
DigiEggztoday at 6:32 AM

Congrats on such an achievement. The remake looks great, but those DOS screenshots have an undeniable charm. With such a large scale game, something I always find interesting is uncovering what types of quirks and bugs bubble underneath the surface in the original version. Did you come across anything obvious in your testing?

show 2 replies
PaulRobinsontoday at 9:37 AM

A technical question for you around the porting being a dead end:

I see from other replies that you now understand the code reasonably well and feel you can expand/extend it while keeping it in BASIC. However, I note you've also done project where you automatically ported Fortran to Lua - are you not interested in trying to do something similar for performance/maintainability reasons? Is there an advantage in keeping it in PowerBASIC?

I've wish listed the game, and look forward to playing it, it sounds like great fun - even the manual sounds like a good read.

show 1 reply
deauxtoday at 9:45 AM

You can tell that by the end of it you got tired and it's less manually edited and more straight from the LLM's mouth.

I don't really care in this case though, it's an awesome story and it doesn't detract too much. Congratulations!

show 1 reply
socitoday at 8:01 AM

Reading between the lines, the game logic itself hasn’t been reverse engineered yet, so adding, changing, or fixing logic still means working with the original code that only Michael Jenkins understands to this day. In any case: massive props to Ben. This feels like a strong foundation, and I’m excited to see him continue evolving the game.

show 2 replies
arjietoday at 9:18 AM

Well that was a pretty cool story. Really enjoyed that it was sufficiently good for its time that so many people got into the field after enjoying playing it (or perhaps that it was enjoyable enough for so many destined for the field to use). And loved the bit where someone emails him and a few chats later off he sends the source code.

rustyhancocktoday at 8:24 AM

I'm sure there is truth in original author saying tax code complexity as the core challenge. But that's not what makes this hard. That's domain complexity we all come up against it's accidental complexity that killed the ports.

The real problem is idiosyncratic and esoteric coding practices from a single self-taught accountant working in a language that didn't encourage good structure.

I can translate well-written code without understanding what it does functionally, so long as I understand what it's doing mechanically.

The original author seems to build in the assumption you're not going to translate my code you'll need to rewrite it from the the tax code!

show 1 reply
qubextoday at 10:17 AM

Looks like I’m going to need a Windows 10 virtual machine on my Apple Silicon. Or maybe I’ll just buy my first Windows machine since 2001.

show 1 reply
dwedgetoday at 9:18 AM

I admittedly only googled quickly but is there anywhere I can buy the original and the book still? I understand he had issues with the payment processor, and I can see free versions to download but I'd prefer to do it legitimately if possible

show 1 reply
hexfrantoday at 8:44 AM

This story is super interesting and I think can teach us some valuable lessons about refactoring and the price of truly understanding the domain in which the code operates. The accompanying article is also a pleasant reading with a nice bit of background, and I really liked the motivation behind "layering" on top instead of rewriting from scratch.

Thanks for bringing this story to HN!

show 1 reply
dwedgetoday at 9:04 AM

> The game he wanted to make required something that didn't exist yet: a personal computer.

> So Jenkins waited.

This part made me laugh out loud. It made me imagine Jenkins as a time traveller who had made a mistake and got stuck in the past, but knew that personal computers would be invented.

show 1 reply
MagicMoonlighttoday at 9:47 AM

If you could get an LLM to write the article, why not just get it to rewrite the code?

show 3 replies
jjmarrlast Tuesday at 8:37 AM

Good job! When can I buy it?

I am sold on the game and wishlisted it but lack of release date saddens me.

I love spreadsheet games like Terra Invicta/Paradox/Simutrans and this seems like a terrific example of one.

show 1 reply
MarcellusDrumtoday at 9:40 AM

I read this in it's entirety. Not skimmed through it, but read every single word (took about 30 minutes)

You can imagine my disappointment when in the end, the code is still basically a mystery, a a wrapper around the core game was made.

Not because what you did is not hard or impressive, it's because, up until the line line were you said you are going to use a wrapper, you made it seem like you're deciphering the code. That isn't really clickbait, because I had already clicked and spent 20 minutes reading. Being misled felt a bit bad, considering how beautifully the story is written.

Impressive work nonetheless.

masswerktoday at 6:46 AM

Regarding "The Second Oldest Game Developer", there are also the authors of "Spacewar!": Steve Russell was born in 1937, meaning, he's either 89 or will be 89 this year. Dan Edwards must be around that age, as well.

show 3 replies
saaaaaamlast Tuesday at 10:31 AM

This is very well written. I have fairly low interest in video games and rarely read gaming content, but read this all the way through. That’s an achievement in itself!

show 1 reply
doctoboggantoday at 6:20 AM

Really interesting, thanks for sharing!

I know it almost sounds crass, but you should consider letting an LLM take a crack at transpiling the code. Source to source translations are one of the most widely agreed upon strengths of LLMs.

show 1 reply
tedheath123today at 7:42 AM

I loved this game. As soon as I saw the title I knew it would be Wall Street Raider. I play it via dosbox and for me the UI is part of the charm. I’d be interested in tinkering with the pricing simulation but from the article it seems like that’s almost impossible.

show 1 reply
wewewedxfgdftoday at 6:05 AM

If you dropped the source code here you'd probably get a versiojn in each of the 5 major languages quick smart.

show 1 reply
ErneXtoday at 7:45 AM

This was a great thing to read this morning, kudos to both!

thomassmith65today at 6:12 AM

This is a wonderful project, and the post is a wonderful read!

Are there any plans to break out portions of the Basic engine to a modern language? It's frustrating that the heart of the game remains inscrutable. Surely Ward is tempted?

show 1 reply
pillefitztoday at 5:21 AM

This is amazing! Having no knowledge of Basic, a.) what makes the rewrite "impossible"? b.) how do coding agents perform on the codebase? It might make for a neat benchmark similar to ARC

show 3 replies
egorfinetoday at 9:36 AM

They spent so much time and effort to port this game to... Windows only?...

replwoacauselast Tuesday at 5:12 AM

I enjoyed the read. How did you tap into the legacy Power Basic engine? Was there a FFI or some kind of bridge you could hook into? And what languages were you using?

show 1 reply
omega3last Tuesday at 6:32 PM

The Wall Street Raider is under active development, you’re releasing a clone under the same name?

https://www.roninsoft.com/wsraider.htm

show 1 reply
Aditya_Gargtoday at 7:45 AM

Amazing read! Is it possible to do something like this but for wall street raider?

https://labs.ramp.com/rct

"claude code plays wall street raider" would be very very cool.

show 1 reply
bhytoday at 7:31 AM

The game itself could be a good benchmark for AI agents.

zahlmanlast Tuesday at 9:54 PM

... You got the source code, and it was 115 kloc of BASIC, but several other individuals and organizations failed to "reverse-engineer" it?

show 2 replies
msephtontoday at 6:00 AM

Fantastic. Well done! For both the new game and the website article.

ozozozdlast Thursday at 8:41 AM

Awesome story! Well-written also.

You are the engineer we all aspired to be. Though, you really are the chosen one.

Wish you the best!

nacozarinalast Tuesday at 11:49 AM

AI can’t do impossible things yet, but we still can.

show 1 reply
cameron_blast Tuesday at 4:09 AM

Cheers for this!

Thank you for sharing your story.

show 1 reply
Computer0today at 8:09 AM

I have been eagerly waiting for this project's release since I first heard about it, thanks for the update!

show 1 reply
dioniantoday at 6:32 AM

Love it and fascinated to play the game.

sevenseacatlast Wednesday at 5:02 AM

oh this is an absolutely fascinating story!

show 1 reply
MUSTANG303today at 6:40 AM

[dead]

blobberstoday at 7:41 AM

I feel like this is the sort of thing AI could do in 10 minutes. Did you try?

show 2 replies