{"id":4023,"date":"2025-09-22T20:38:13","date_gmt":"2025-09-22T20:38:13","guid":{"rendered":"https:\/\/redfrontdoor.org\/blog\/?p=4023"},"modified":"2025-09-22T20:38:13","modified_gmt":"2025-09-22T20:38:13","slug":"reverse-engineering-the-dragon-32-game-invaders-revenge","status":"publish","type":"post","link":"https:\/\/redfrontdoor.org\/blog\/?p=4023","title":{"rendered":"Reverse-engineering the Dragon 32 game Invader\u2019s Revenge"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">In my increasingly-distant youth, my family had a <a href=\"https:\/\/en.wikipedia.org\/wiki\/Dragon_32\/64\">Dragon 32<\/a> home computer, which I spent many hours with.  For a lot of this time, I was writing programs of various kinds, with the built-in Basic and then also assembly language.  But, unsurprisingly, I also played games, including one called <em>Invader\u2019s Revenge<\/em>, written by Kenneth Kalish. You control a yellow ship, and have to shoot enemy \u201cdefender\u201d ships while not crashing into anything or being shot by the enemy base. Good fun.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"480\" src=\"https:\/\/redfrontdoor.org\/blog\/wp-content\/uploads\/2025\/09\/screenshot-1.png\" alt=\"Screenshot of Dragon 32 game &quot;Invader's Revenge&quot;\" class=\"wp-image-4024\" style=\"width:368px;height:auto\" srcset=\"https:\/\/redfrontdoor.org\/blog\/wp-content\/uploads\/2025\/09\/screenshot-1.png 640w, https:\/\/redfrontdoor.org\/blog\/wp-content\/uploads\/2025\/09\/screenshot-1-300x225.png 300w, https:\/\/redfrontdoor.org\/blog\/wp-content\/uploads\/2025\/09\/screenshot-1-600x450.png 600w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">In my current job, I am developing and researching&nbsp;<a href=\"https:\/\/pytch.org\/\">Pytch<\/a>, a free online educational coding platform which helps people learn Python by writing \u201cScratch-like\u201d programs. I thought a port of&nbsp;<em>Invader\u2019s Revenge<\/em>&nbsp;could be a good example of what can be made in Pytch.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I could probably have achieved this by taking screenshots and working out the game logic just by observations, but thought it would be a more interesting exercise to reverse engineer the original machine code. This would also allow a dose of nostalgia for the Dragon and working in assembly language, albeit someone else\u2019s.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">After rather more time than I thought I would spend on this, I was successful.  Full details and results in <a href=\"https:\/\/bennorth.github.io\/dragon32-invaders-revenge\/\">these GitHub pages<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Partly for the challenge, and partly for nostalgia, I reverse-engineered the Dragon 32 game Invader&#8217;s Revenge, creating an essentially complete commented disassembly.  I also created a Pytch version, which is embedded in the full write-up.<\/p>\n","protected":false},"author":2,"featured_media":4024,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-4023","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","comments-off"],"_links":{"self":[{"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/4023","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4023"}],"version-history":[{"count":3,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/4023\/revisions"}],"predecessor-version":[{"id":4027,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/4023\/revisions\/4027"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=\/wp\/v2\/media\/4024"}],"wp:attachment":[{"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4023"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4023"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/redfrontdoor.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4023"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}