TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Space Trader (Ported from Palm OS to Vanilla JavaScript and HTML)

8 pointsby memalign6 months ago
Hi HN! I brought my favorite game from Palm OS to the web as a hobby project. In Space Trader, you can trade goods, hunt bounties, amass a fortune, buy a moon and retire.<p>One of the parts of this project I enjoyed the most:<p>To aid debugging and unit testing, I use a deterministic random number generator called GameRand. In debug mode, I can capture the random seed and log of every action taken in the game. Then I can replay that to reproduce a bug or create a test.<p>I ended up creating nearly exhaustive test coverage this way.<p>A write-up with more technical details and links to source code:<p><a href="https:&#x2F;&#x2F;memalign.github.io&#x2F;p&#x2F;spacetrader.html" rel="nofollow">https:&#x2F;&#x2F;memalign.github.io&#x2F;p&#x2F;spacetrader.html</a>

3 comments

zzo38computer6 months ago
I had not played it since it is not working on my computer, although if someone implement in uxn then it should be able to work on many computers. (However, although I have not tried it, I think that keyboard commands is a good idea, like is mentioned in other comments on here.)<p>Another text-based picture format is XPM2, and is one that I had used sometimes (I wrote a implementation of XPM in C, supporting encoding and decoding all three formats; other implementations I have seen have many limitations and bugs). PCEImage could be used as a simpler format in case you do not need all of the features of XPM (such a a monochrome palette and symbolic colours), although it would also be possible to use a subset of XPM2.
bobrobpr6 months ago
Just give me a way to auto-dismiss. The popup gets old fast. Let me hit Enter to dismiss it at least. Great game. Reminds me of Escape Velocity by Ambrosia.
评论 #42504858 未加载
skibz6 months ago
This is remarkably polished for a hobby project. Kudos.