← Tue, Sep 29 digest

Commodore 64: Mercenary

read article ↗ hn thread ↗

A detailed technical breakdown of the 1986 Commodore 64 game Mercenary reveals its inner workings, rendering code, and a 41-year-old unpatched teleportation bug.

read it Essential reading for retro game developers and enthusiasts for its byte-level reverse engineering and discovery of a 41-year-old bug.

summary

The article provides an exhaustive, byte-accurate breakdown of the 1986 Commodore 64 open-world game Mercenary. It examines rendering limitations, flight models, object catalogs, and underground rooms by porting game routines and running them in simulators. Notably, it highlights a newly uncovered 41-year-old bug where an invisible grass patch teleports the player to the Colony Craft because code checks omit height values. The interactive site lets readers test these routines and inspect original memory structures.

key points

  1. An invisible patch of grass near the crash site triggers a teleport to the Colony Craft because the lift interaction code fails to check altitude.
  2. The game uses a double-buffered 160x136 multicolour bitmap screen, achieving 4 to 5 frames per second on the surface.
  3. Objects outside the city are handled as fixed entities because building models are only loaded for central grid squares.
  4. A permanent non-interactable ship belonging to the Palyar commander's brother-in-law laps the city endlessly at altitude 500.

who should read it

Retro game developers, reverse engineers, and Commodore 64 enthusiasts.

discussion warm

consensus

Commenters express deep nostalgia for Mercenary and amazement at the thoroughness of the reverse-engineering breakdown, alongside tributes to the late creator Paul Woakes.

best comment by a1r ↗

100 paces NW of the starting position is an invisible patch of grass where the author forgot to include a height check. Press E and you teleport to the Colony Craft, far above you. This bug has gone unnoticed for 41 years!

Highlights the specific 41-year-old bug discussed in the article that sparked the thread.

Generated by an LLM from the article and thread. Check the sources before relying on it.