AI Reverse Engineering

Stunt Car Racer (Amiga) — track viewer

drag to rotate · scroll to zoom

Each of the eight league circuits is the game's own track data, decoded purely in Go from the disk image — no emulation. The disk has no filesystem; a table of handles at $1F0A2 locates each track's byte stream, which is a run-length-encoded list of sections that the loader ($5AE46) walks to lay out the circuit. This viewer re-runs that walk (package track) and lays each circuit out on its 16×16 plan grid — each section's cell is read straight from the section parameter the engine itself uses to look sections up ($5FE04/$64304): the parameter's low nibble is the grid X, its high nibble the grid Y. Consecutive sections are always adjacent cells, so the footprints are smooth closed loops — a diamond (Little Ramp), a rectangle (Stepping Stones), the two inner prongs of the drawbridge (Draw Bridge). Each section also has an elevation — the ribbon is an elevated track on support columns, just like the game's pre-race preview, with the ramps, jumps and Roller-Coaster hills. The track is drawn as a hidden-line wireframe: two rails plus a rung per section, coloured along the lap (blue → red), columns down to the ground, and the green marker at the start/finish. The decode is entirely from the disk in Go (section parse verified coordinate-exact against the original loader on our Go 68000 core); the elevation is the mean of the two rail heights the renderer reads ($5C0AA). The surface is interpolated by default, so ramps and hills stay smooth and drivable; only genuine features become hard steps — a platform (a prominent rise-and-fall: the Stepping Stones, Big Ramp's three jumps, the drawbridge) or a cliff (Ski Jump's launch) — drawn with flat tops and vertical drops.

Drag to rotate, scroll to zoom. See the write-up (Part IV) for how the track format was decoded.