; Mermaids of Atlantis (U) - zero-page aliases. ; ; Pass 1 names every zero-page operand ZpXX; the names below are the ; semantic ones the dump proves. An address whose role is the same at ; every reference is renamed everywhere; an address the game reuses for ; several roles keeps the neutral ZpXX name and is listed at the end. ButtonState1 = $26 ; player 1 button bits, read from $4016 ButtonState2 = $27 ; player 2 button bits, read from $4017 PrevButton1 = $28 ; player 1 buttons of the previous frame PrevButton2 = $29 ; player 2 buttons of the previous frame NewButton1 = $2A ; player 1 buttons pressed this frame NewButton2 = $2B ; player 2 buttons pressed this frame PrgBankNumber = $2C ; the MMC3 PRG bank the game switches to HandlerIndex = $2D ; the index the banked call dispatches on IdleCounter = $2F ; the counter the idle loop spins on FrameCounter = $31 ; the frame counter, incremented at the end of the NMI ControllerBits = $05 ; the eight button bits assembled by the pad reader ControllerByte = $07 ; the raw byte read from $4016/$4017 GameMode = $6A ; the game mode flag (0 = playing, 1 = demo) ; --------------------------------------------------------------------------- ; The addresses below are used for more than one purpose in this dump, so ; they keep the neutral name. ; ; $00-$01 the RAM-clear pointer (and the banked-call scratch) ; $02 the PPUMASK shadow ; $06 the PRG bank shadow in the banked call ; $11-$14 indirect pointers: the VRAM pointer, the dispatch table pointer ; and the sound table pointer share the two pairs ; $19-$1F scroll, sprite and bubble coordinates, reused per actor ; $20-$2E per-actor scratch: the tile, the position and the frame counters ; $30-$3F per-actor state: the sprite index, the direction and the timers ; $40-$5F the level script variables: the stage, the wave and the score ; $60-$7F the game state: the mode flags, the player state and the timers ; $80-$9F the same, for the second half of the image ; $A0-$DF the sound engine state ; --------------------------------------------------------------------------- Zp2E = $2E Zp00 = $00 Zp01 = $01 Zp02 = $02 Zp03 = $03 Zp04 = $04 Zp06 = $06 Zp08 = $08 Zp09 = $09 Zp10 = $10 Zp11 = $11 Zp12 = $12 Zp13 = $13 Zp14 = $14 Zp15 = $15 Zp16 = $16 Zp17 = $17 Zp18 = $18 Zp19 = $19 Zp1A = $1A Zp1B = $1B Zp1C = $1C Zp1D = $1D Zp1E = $1E Zp1F = $1F Zp20 = $20 Zp21 = $21 Zp22 = $22 Zp23 = $23 Zp24 = $24 Zp25 = $25 Zp30 = $30 Zp32 = $32 Zp33 = $33 Zp34 = $34 Zp35 = $35 Zp36 = $36 Zp37 = $37 Zp38 = $38 Zp39 = $39 Zp3A = $3A Zp3B = $3B Zp3C = $3C Zp3D = $3D Zp3E = $3E Zp3F = $3F Zp40 = $40 Zp41 = $41 Zp42 = $42 Zp46 = $46 Zp47 = $47 Zp48 = $48 Zp49 = $49 Zp4A = $4A Zp4B = $4B Zp4C = $4C Zp4D = $4D Zp4E = $4E Zp52 = $52 Zp56 = $56 Zp58 = $58 Zp59 = $59 Zp5A = $5A Zp5B = $5B Zp5C = $5C Zp5D = $5D Zp5E = $5E Zp5F = $5F Zp60 = $60 Zp61 = $61 Zp62 = $62 Zp63 = $63 Zp64 = $64 Zp65 = $65 Zp66 = $66 Zp67 = $67 Zp68 = $68 Zp69 = $69 Zp6C = $6C Zp6E = $6E Zp6F = $6F Zp70 = $70 Zp71 = $71 Zp72 = $72 Zp73 = $73 Zp74 = $74 Zp75 = $75 Zp76 = $76 Zp78 = $78 Zp7E = $7E Zp80 = $80 Zp85 = $85 Zp86 = $86 Zp91 = $91 Zp93 = $93 Zp94 = $94 Zp95 = $95 Zp96 = $96 Zp97 = $97 Zp99 = $99 Zp9A = $9A Zp9D = $9D ZpA7 = $A7 ZpAF = $AF ZpB7 = $B7 ZpB9 = $B9 ZpBE = $BE ZpC8 = $C8 ZpC9 = $C9 ZpCA = $CA ZpCB = $CB ZpCC = $CC ZpCD = $CD ZpCE = $CE ZpCF = $CF ZpD0 = $D0 ZpD4 = $D4 ZpD5 = $D5 ZpD6 = $D6 ZpD7 = $D7 ZpD8 = $D8 ZpD9 = $D9 ZpDA = $DA ZpDB = $DB ZpDC = $DC ZpDD = $DD ZpDE = $DE ZpDF = $DF ZpE0 = $E0 ZpE2 = $E2 ZpE3 = $E3 ZpE7 = $E7