data/claims/mm2-av.yamlMega Man 2 graphics (lsmmega/mm2)
Game: Mega Man 2.
On even frames _sprites writes Mega Man's object slots (0 to $0F), then the enemies' ($10 to $1F), then the energy meters; on odd frames it writes the meters first and the slots in reverse, $1F down to $10, then $0F down to 0, so objects that lose the 8-per-scanline race lose it only every other frame. mm2-av/sprite-order-flip
About: Mega Man 2 Sprite flicker
Value
{
"even": "slots 0-$1F, then meters",
"odd": "meters, then slots $1F-0",
"period": 2
}home/sprites.asm#L12-L38@time_stopper_flag_not_set:
LDA z:znmi_frame
AND #%00000001
BNE @invert
…
@loop_1:
JSR _draw_megaman_with_animation
…
CMP #$10
BNE @loop_1
@loop_2:
JSR _draw_enemies_with_animation
…mm2: Mega Man 2 disassembly (lsmmega/mm2) · home/sprites.asm#L43-L62@invert:
JSR _draw_bar
…
LDA #$1F
STA z:zsprites_pointer
@loop_3:
JSR _draw_enemies_with_animation
BCS @max_2
DEC z:zsprites_pointer
…
@loop_4:
JSR _draw_megaman_with_animation
…Checked by claude, 2026-10-21 — read _sprites at the pinned commitThe "loses only every other frame" reading follows from the PPU's in-order search (nes-hardware/sprites-per-scanline); the atlas has not measured flicker in play. When the time stopper is active a separate path (_time_stopper_flag_set) runs instead.
Cited by: Mega Man 2, Sprite flicker
Mega Man 2 draws its energy meters as sprites, not a split screen; each meter is a column of 7 sprites from Y $18 down to $48, each showing 0-4 units, at X $10 for the weapon, $18 for life, and $28 for a boss. mm2-av/sprite-meters
About: Mega Man 2 Status bar split
Value
{
"spritesPerMeter": 7,
"unitsPerSprite": 4,
"topY": 24,
"x": {
"weapon": 16,
"life": 24,
"boss": 40
}
}home/sprites.asm#L473-L476vertical_bar_base_ycoord = $18
hp_bar_xcoord = $18
weapon_bar_xcoord = $10
boss_bar_xcoord = $28mm2: Mega Man 2 disassembly (lsmmega/mm2) · home/sprites.asm#L530-L545_draw_bar_tile:
LDY #6
@loop:
LDA @vertical_bar_ycoord_table, Y
STA aoam_y, X
SEC
LDA z:z00
SBC #4mm2: Mega Man 2 disassembly (lsmmega/mm2) · home/sprites.asm#L572-L579@vertical_bar_ycoord_table:
.BYTE vertical_bar_base_ycoord + 0
…
.BYTE vertical_bar_base_ycoord + 48Checked by claude, 2026-10-21 — read _draw_bar and _draw_bar_tile at the pinned commitThe loop starts at the bottom sprite (index 6) and takes 4 units per sprite, so a meter fills from the bottom up. Three meters on one line use 3 of the 8 sprite slots.
Cited by: Mega Man 2, Status bar split
Once a frame _background_palette counts up to a stage's frame byte and then copies the next 16-byte background palette set into the working palette, wrapping after the stage's set count; Heat Man's stage has 3 sets and a frame byte of 6, so its palette 3 rotates $36, $26, $16 one step every 7 frames. mm2-av/palette-sets
About: Mega Man 2 Palette cycling
Value
{
"heatman": {
"sets": 3,
"frameByte": 6,
"framesPerStep": 7,
"palette3": [
[
54,
38,
22
],
[
38,
22,
54
],
[
22,
54,
38
]
]
}
}home/background_palette.asm#L1-L32_background_palette:
…
LDA apalette_animation_frame
BEQ @skip
INC z:zpalette_animation_timer
CMP z:zpalette_animation_timer
BCS @skip
LDA #$00
STA z:zpalette_animation_timer
INC z:zcurrent_palette_no
LDA z:zcurrent_palette_no
CMP ano_of_palette
…mm2: Mega Man 2 disassembly (lsmmega/mm2) · home/nmi_wait.asm#L1-L12_nmi_wait_0e:
…
JSR _background_palette
LDA #$00
STA z:znmi_wait
@loop:
LDA z:znmi_wait
BEQ @loopmm2: Mega Man 2 disassembly (lsmmega/mm2) · stages/heatman_wily1/heatman_wily1_palette_init.asm#L1-L34;heatman palette init
; number of background animation palette(s), frame(s)
.BYTE 3, 6
…
.BYTE black, pale_red, white_red, light_red
…
.BYTE black, white_red, light_red, pale_red
…
.BYTE black, light_red, pale_red, white_redmm2: Mega Man 2 disassembly (lsmmega/mm2) · constants/palettes.asm#L1-L55dark_gray
…
light_gray
…
light_red
…
white_gray = $20
…
pale_gray = $30
…
pale_redChecked by claude, 2026-10-21 — read _background_palette, its per-frame call, Heat Man's palette data, and the color enum at the pinned commitThe step comes when the counter exceeds the frame byte (BCS skips while byte ≥ counter), so a byte of 6 steps every 7 frames. The enum counts from $00, so light_red = $16, white_red = $26, pale_red = $36. Which tiles use palette 3 in Heat Man's stage (the lava falls, by appearance) was not read from the level data.
Cited by: Mega Man 2, Palette cycling