Konami's Mahjong

Thirty-two kilobytes in which the main thread does nothing: it starts up, hooks the interrupt and settles into a jump to itself forever. And the opponent, which plays well, does not think either: its hand is built one tile short of complete, and what goes into its river is a tile drawn at random from the wall through a filter that makes it look human.

Konami · © Konami 1984 - An RC-707 32 KB cartridge - MSX1 · pages 1 and 2 - Dump 24cb5bda…

Every picture here is a screenshot of the cartridge. And not one was taken by hand: a script boots the ROM in openMSX with nothing being drawn, dumps video memory at a few fixed instants, and the PNG is built from the dump. The first pass does not press a single key, because the demo plays itself. The listing and the numbers come from the binary and are reproducible with make.

The game in numbers

100%of the binary explained
340routines identified
38named yaku
15,432bytes of code
17,336bytes of data
0bytes unidentified

What is inside

The game

Curiosities

Under the hood