Cite as
“Metroid (USA)”
Licence
proprietary; never redistributed (docs/data-policy.md#roms)
Credit
Nintendo R&D1 (developer) and Nintendo (publisher)
Notes
NES 2.0 header: 128 KB PRG ROM, CHR RAM, mapper 1 (MMC1), no battery (the US release saves by password). Without the 16-byte header the SHA-1 is fdbfc7871962f72a1ef57e5a7e456164fb93430b; nmikstas's disassembly reassembles to these PRG bytes exactly.

Cited on

Claims (24)

Metroid's cartridge ROM, counted by part of the game: each stretch of code or data goes to the part the disassembly's labels and comments say it serves, and the value sums the bytes of each part.0x10-0x2000fCode notes
nmikstas's disassembly of Metroid, assembled with Ophis, equals the PRG ROM of Metroid (USA) byte for byte.0x1C010-0x1C029Code
Samus's health is binary-coded decimal in tenths of a unit; HealthHi holds the full energy tanks in its high nibble and the tens digit in its low nibble, and HealthLo holds the ones digit in its high nibble.0x1CEA2-0x1CF08Code
Samus starts with 30 units of energy and no energy tanks.0x1C8E1-0x1C93ACode
When an enemy touches Samus, the game charges her the base damage of the current area, two bytes in that area's bank at $95CE, whatever the enemy; Brinstar's is 8 units, Norfair's 10, Kraid's hideout's 20, Ridley's hideout's 24, and Tourian's 30.0x1F316-0x1F3200x55DE-0x55DFCode
With the Varia suit, SubtractHealth halves every amount it takes from Samus.0x1CEA2-0x1CF08Code
A hit sets SamusBlink to $32, which is 50, gives Samus an upward speed of $FD with the hit gravity $38, and takes the push direction from the hit; the comment says "Set blink for 32 frames".0x1CE0A-0x1CE93Code
Each frame, the crash detection skips the contact check between Samus and the enemies while SamusBlink is above 0.0x1F044-0x1F14FCode
CheckHealthStatus, which Samus's routines call once per frame, lowers SamusBlink by 1 each time, so the blink lasts 50 frames of game logic.0x1CE0A-0x1CE93Code
On each frame of the blink, CheckHealthStatus sets Samus's horizontal speed in the push direction to the blink counter divided by 16, so the push ends when the counter falls below 16; below 48, it skips the push on any frame Samus has horizontal acceleration.0x1CE0A-0x1CE93Code
Measured in the ROM, a crawler held against Samus in Brinstar's first room takes 8 units with each hit, and the next hit lands 50 game frames later; one of the two gaps also held 2 lag frames, for 52 frames of video.0x1CE0A-0x1CE93Verified
Measured the same way, with the crawler moved off Samus during each blink, the three pushes carried her 37, 45, and 44 px away from it; two lifted her 19 px and one 2 px.0x1CE0A-0x1CE93Verified
In lava, Samus's blink is set to 50 on every frame, so enemies can't touch her, while the lava takes 0.7 units twice every 8 frames without a push; the Varia suit cuts that to once, and SubtractHealth halves it to 0.3 units.0x1E279-0x1E2B8Code
The main loop calls RandomNumbers once per frame, after the frame's work; it adds 5 to RandomNumber1 five times, 25 in all, so the byte steps through all 256 values every 256 frames.0x1C010-0x1C029Code
When an enemy dies, a RandomNumber1 below 16 drops nothing; otherwise its low 3 bits pick from ItemDropTbl, which holds a missile at 0 and 3, energy at 1, 4, and 6, and $89 at 2, 5, and 7.0x1DD0C-0x1DD840x1DE45-0x1DE4CCode
Item $89 drops only for an enemy whose byte in the area's table at $968B has bit 0 set, and Samus collects it as 20 units of energy; the table's comment calls it "No item".0x1F493-0x1F4E30x569B-0x56AACode
Each door re-rolls the room's caps from RandomNumber1, 0 to 15 missile drops and 64 to 94 energy drops, and zeroes the counts. A drop that would pass its cap is lost; one that passes the test adds to its count, even a $89 roll that the enemy then can't drop.0x4B2B-0x4B390x1DD0C-0x1DD84Code
Until the first door, the caps on missile and energy drops are 39 when the game starts in Brinstar, because SamusInit stores the mirroring value $27 into them, or 47 ($2F) elsewhere.0x1C8E1-0x1C93ACode
A small energy ball gives Samus 5 units and a $89 ball 20; a missile gives 2 missiles; an enemy whose data index carries the 30-unit flag gives 30 units or 30 missiles instead.0x1F493-0x1F4E3Code
In Tourian, enemies with data index 2 or 4 drop nothing, and any other kill that would drop nothing resets both caps to 1 and both counts to 0 and rolls the same RandomNumber1 again, skipping the test for 16.0x1DD0C-0x1DD84Code
Called in the ROM for all 256 values of RandomNumber1, the drop code gives a Brinstar enemy of data index 0 60 missiles, 90 small energy balls, 90 $89 balls, and 16 nothing; index 3, whose byte in the table LF74B reads ($968B + data index, kept in $00) has bit 0 clear, gives 106 nothing and no $89.0x1DD0C-0x1DD84Verified
An energy tank adds a tank, up to 6, and fills Samus's health to her new maximum.0x1DC07-0x1DC2BCode
Samus's health can't exceed 99.9 units above her tanks, 100t+99.9 units for t tanks, which is 699.9 with all six.0x1CF09-0x1CF3DCode
A missile tank raises Samus's missile capacity by 5.0x1DC07-0x1DC2BCode