diff options
author | B. Watson <yalhcru@gmail.com> | 2016-09-02 00:00:39 -0400 |
---|---|---|
committer | B. Watson <yalhcru@gmail.com> | 2016-09-02 00:00:39 -0400 |
commit | 2501dc4ecbfc45170a84503a90eb15f5770e6918 (patch) | |
tree | 3b9ebc8179ab484f8293a989609f0561b9b92384 | |
parent | e9ec302bb089104385c020356dd47b64d6bd09a7 (diff) | |
download | jumpmanjr-2501dc4ecbfc45170a84503a90eb15f5770e6918.tar.gz |
bombs and level maps
-rw-r--r-- | README | 3 | ||||
-rw-r--r-- | bombs.txt | 42 | ||||
-rw-r--r-- | jumpmanjr.dasm | 529 | ||||
-rw-r--r-- | jumpmanjr.info | 224 | ||||
-rw-r--r-- | level_maps.txt | 119 | ||||
-rw-r--r-- | leveldesc.info | 196 | ||||
-rw-r--r-- | main.info | 28 | ||||
-rw-r--r-- | mklevelinfo.pl | 14 |
8 files changed, 809 insertions, 346 deletions
@@ -97,6 +97,8 @@ The way I do this: 4. Play with it, see what happens. If you discover something useful, add it to main.info and/or mklevelinfo.pl. +Official XKCD comic of this project: https://xkcd.com/1349/ + Notes: [1] If you're wondering about the .dasm filename extension: ca65's standard @@ -126,4 +128,3 @@ Notes: Makefile will print this for your copy/pasting convenience, but I don't see a way to have atari800 automatically do this (short of modifying atari800, which is a project for another day). - diff --git a/bombs.txt b/bombs.txt new file mode 100644 index 0000000..b6d4e78 --- /dev/null +++ b/bombs.txt @@ -0,0 +1,42 @@ + +Picking up bombs in the game seems simple enough... but the way they're +implemented in the code isn't. + +Each level has: + +- bomb graphics in the map data +- a list of bombs (indexed by 'coarse grid' coordinates) +- a list of map changes that happen when a bomb is picked up (optional) +- a subroutine that gets called on bomb pickup (optional) +- a subroutine that only gets called when certain bombs are + picked up... but this isn't used in Jumpman Junior (probably + it's a leftover from original Jumpman) +- another bomb-related list that I haven't figured out yet +- a byte that tells the game how many points a bomb pickup is + worth... but it's set to $64 (100) on every level in the game. +- a shape to draw to replace the bomb, when it's picked up. Likely + this is just a 4x4 blank square on most levels, but Figurits + Revenge probably has a girder here instead (I can't remember if + *every* bomb on that level causes a girder section to appear though) + +Coarse Grid Coordinates +----------------------- + +Effectively, the level is split into an invisible 8x8 grid, and only one +bomb can appear in each grid square. When a bomb is touched (detected +by GTIA collision register), the bomb_pickup routine gets called. It +turns the current player X and Y coordinates (in pixels/scanlines) +into coarse grid coordinates basically by lopping off the lower-order +bits. Since the Atari's display is larger than the visible portion, +the outermost grid squares are actually off the screen. This means the +grid is effectively more like 6x7 than 8x8. Each grid square can only +contain one bomb, so there's a limit of 64 (or really 42) bombs per level. + +The coarse coordinates are combined into one byte, and this byte is +searched for in the bomb list. When it's found, its position in the +list is used as an index into the other two lists (the map changes list +and the one I don't know what it's for yet). If the byte isn't found +before the $FF that terminates the list, bomb_pickup returns (so no +points are awarded and no bomb-picked-up sound is heard, and the bomb +doesn't disappear... doesn't happen on any of the levels as far as I +can remember though). diff --git a/jumpmanjr.dasm b/jumpmanjr.dasm index 7da9faf..1d858f5 100644 --- a/jumpmanjr.dasm +++ b/jumpmanjr.dasm @@ -1,5 +1,5 @@ ; da65 V2.15 - Git 104f898 -; Created: 2016-08-31 16:20:14 +; Created: 2016-09-01 23:57:51 ; Input file: jumpmanjr.rom ; Page: 1 @@ -108,17 +108,21 @@ work_level_points_per_bomb:= $0790 ; points awarded per bomb pickup work_level_time_bonus:= $0791 ; amount of time bonus at start of level work_level_offs_19:= $0793 ; always $00 work_level_unkn_table0:= $0794 ; pointer to ROM table or $06xx -work_level_map0 := $0796 ; map data -work_level_map1 := $0798 ; map data -work_level_bomblist:= $079A ; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +work_level_map := $0796 ; used to draw the level initially (see also map_changes) +work_level_map_bombs:= $0798 ; start of bombs in map data (which must come last!) +work_level_bomblist:= $079A ; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. work_level_map_changes:= $079C ; address of list of addresses of map data, used for changing the map when certain bombs are picked up -work_level_offs_30:= $079E ; always $0000 +work_level_indirect_subs:= $079E ; pointer to list of indirect subs, always $0000 in this game work_level_sub_bomb:= $07A0 ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine work_level_sub_start:= $07A2 ; called at start of level, $06E6 for some levels, or else a ROM subroutine work_level_sub6 := $07A4 ; always $9740 aka game_main_loop work_level_sub_eol:= $07A6 ; called at end of level (all bombs picked up). $06E6 for all but level07 work_level_offs_40:= $07A8 ; all zeroes -work_level_offs_46:= $07AE ; unknown +work_level_colpf3:= $07AE ; color (not sure what gets drawn in this color yet) +work_level_colpf0:= $07AF ; color for girders and up-ropes +work_level_colpf1:= $07B0 ; color for ladders and down-ropes +work_level_colpf2:= $07B1 ; color for bombs +work_level_offs_50:= $07B2 ; unknown work_level_offs_55:= $07B7 ; unknown, always $00 $00 $00 work_level_offs_58:= $07BA ; unknown, not a ROM address work_level_offs_60:= $07BC ; unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00 @@ -137,17 +141,21 @@ cur_level_points_per_bomb:= $07D0 ; points awarded per bomb pickup cur_level_time_bonus:= $07D1 ; amount of time bonus at start of level cur_level_offs_19:= $07D3 ; always $00 cur_level_unkn_table0:= $07D4 ; pointer to ROM table or $06xx -cur_level_map0 := $07D6 ; map data -cur_level_map1 := $07D8 ; map data -cur_level_bomblist:= $07DA ; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +cur_level_map := $07D6 ; used to draw the level initially (see also map_changes) +cur_level_map_bombs:= $07D8 ; start of bombs in map data (which must come last!) +cur_level_bomblist:= $07DA ; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. cur_level_map_changes:= $07DC ; address of list of addresses of map data, used for changing the map when certain bombs are picked up -cur_level_offs_30:= $07DE ; always $0000 +cur_level_indirect_subs:= $07DE ; pointer to list of indirect subs, always $0000 in this game cur_level_sub_bomb:= $07E0 ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine cur_level_sub_start:= $07E2 ; called at start of level, $06E6 for some levels, or else a ROM subroutine cur_level_sub6 := $07E4 ; always $9740 aka game_main_loop cur_level_sub_eol:= $07E6 ; called at end of level (all bombs picked up). $06E6 for all but level07 cur_level_offs_40:= $07E8 ; all zeroes -cur_level_offs_46:= $07EE ; unknown +cur_level_colpf3:= $07EE ; color (not sure what gets drawn in this color yet) +cur_level_colpf0:= $07EF ; color for girders and up-ropes +cur_level_colpf1:= $07F0 ; color for ladders and down-ropes +cur_level_colpf2:= $07F1 ; color for bombs +cur_level_offs_50:= $07F2 ; unknown cur_level_offs_55:= $07F7 ; unknown, always $00 $00 $00 cur_level_offs_58:= $07FA ; unknown, not a ROM address cur_level_offs_60:= $07FC ; unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00 @@ -1294,8 +1302,8 @@ csm_loop: rts ; 8729 60 ` ; ---------------------------------------------------------------------------- -; clear P/M mem -clear_pm_mem: +; misc stuff, called from enable_joystick +prepare_level: lda #$09 ; 872A A9 09 .. sta player_speed ; 872C 8D 24 06 .$. ldx #$05 ; 872F A2 05 .. @@ -1351,7 +1359,7 @@ ej_loop:lda #$E6 ; 8777 A9 E6 stx joystick_disabled ; 8785 8E 32 06 .2. stx sfx_lock ; 8788 8E 2F 06 ./. stx work_level_bullet_max ; 878B 8E 8B 07 ... - jsr clear_pm_mem ; 878E 20 2A 87 *. + jsr prepare_level ; 878E 20 2A 87 *. jsr silence_audio ; 8791 20 5B 87 [. lda #$30 ; 8794 A9 30 .0 sta SAVMSC+1 ; 8796 85 59 .Y @@ -1359,7 +1367,7 @@ ej_loop:lda #$E6 ; 8777 A9 E6 set_prior: lda #$11 ; 8798 A9 11 .. sta PRIOR ; 879A 8D 1B D0 ... - jmp L88A8 ; 879D 4C A8 88 L.. + jmp clear_pm_mem ; 879D 4C A8 88 L.. ; ---------------------------------------------------------------------------- ; check whether Jumpman just touched a bomb (RTS if not) @@ -1370,7 +1378,7 @@ check_bomb_coll: rts ; 87A7 60 ` ; ---------------------------------------------------------------------------- -; Jumpman just picked up a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, do some other stuff I don't understand yet +; Jumpman just touched a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, etc. bomb_pickup: lda player_x_pos ; 87A8 AD 7E 06 .~. clc ; 87AB 18 . @@ -1387,6 +1395,8 @@ bomb_pickup: lsr a ; 87BF 4A J ora bombloc ; 87C0 05 B6 .. sta bombloc ; 87C2 85 B6 .. +; screen X range approx $32 to $C6, Y $18 to $C0, meaning the coarse grid visible screen range is X 1-6, Y 0-6 +coarse_grid: lda work_level_bomblist ; 87C4 AD 9A 07 ... sta blistptr ; 87C7 85 B4 .. lda work_level_bomblist+1 ; 87C9 AD 9B 07 ... @@ -1408,9 +1418,9 @@ bl_ok: cmp bombloc ; 87D7 C5 B6 ; ---------------------------------------------------------------------------- bomb_found: - lda work_level_map1 ; 87E0 AD 98 07 ... + lda work_level_map_bombs ; 87E0 AD 98 07 ... sta $B0 ; 87E3 85 B0 .. - lda work_level_map1+1 ; 87E5 AD 99 07 ... + lda work_level_map_bombs+1 ; 87E5 AD 99 07 ... sta $B1 ; 87E8 85 B1 .. ; multiply Y by 1.5 (only works because Y will always be even at this point) mul_y: tya ; 87EA 98 . @@ -1419,8 +1429,9 @@ mul_y: tya ; 87EA 98 clc ; 87EE 18 . adc $B2 ; 87EF 65 B2 e. tay ; 87F1 A8 . -; find out: why are we storing this at 06DC? -unkn1: lda ($B0),y ; 87F2 B1 B0 .. +; store actual bomb coordinates (not the coarse ones) for bomb subs to use +store_bomb_coords: + lda ($B0),y ; 87F2 B1 B0 .. sta $06DC ; 87F4 8D DC 06 ... iny ; 87F7 C8 . lda ($B0),y ; 87F8 B1 B0 .. @@ -1441,7 +1452,7 @@ unkn1: lda ($B0),y ; 87F2 B1 B0 lsr a ; 8818 4A J lsr a ; 8819 4A J tay ; 881A A8 . -; this has to do with redrawing parts of the level (e.g. disappearing platforms on level00) +; some bombs redraw parts of the level (e.g. disappearing platforms on level00) change_map: lda work_level_map_changes ; 881B AD 9C 07 ... sta $B0 ; 881E 85 B0 .. @@ -1465,9 +1476,9 @@ check_ind_sub: tay ; 883D A8 . ; this would call a subroutine via pointer-to-pointer, but I'm almost 100% certain it's never used (maybe a holdover from original Jumpman?) call_bomb_indirect_sub: - lda work_level_offs_30 ; 883E AD 9E 07 ... + lda work_level_indirect_subs ; 883E AD 9E 07 ... sta $B0 ; 8841 85 B0 .. - lda work_level_offs_30+1 ; 8843 AD 9F 07 ... + lda work_level_indirect_subs+1 ; 8843 AD 9F 07 ... sta $B1 ; 8846 85 B1 .. lda ($B0),y ; 8848 B1 B0 .. sta $06E4 ; 884A 8D E4 06 ... @@ -1501,9 +1512,11 @@ erase_bomb: jsr draw_map_jv ; 8881 20 00 80 .. jsr update_score_display_jv ; 8884 20 0C 80 .. dec work_level_num_bombs ; 8887 CE 8A 07 ... -L888A: lda collision_save+4 ; 888A AD B4 06 ... +; wait for bomb to really disappear +wait_bomb: + lda collision_save+4 ; 888A AD B4 06 ... and #$04 ; 888D 29 04 ). - bne L888A ; 888F D0 F9 .. + bne wait_bomb ; 888F D0 F9 .. rts ; 8891 60 ` ; ---------------------------------------------------------------------------- @@ -1513,15 +1526,18 @@ sfx_bomb_pickup: .byte $03,$28,$03,$1E,$03,$28,$03,$1E ; 889A 03 28 03 1E 03 28 03 1E .(...(.. .byte $03,$28,$03,$00,$00,$00 ; 88A2 03 28 03 00 00 00 .(.... ; ---------------------------------------------------------------------------- -L88A8: ldx #$00 ; 88A8 A2 00 .. +; clear P/M memory, called from enable_joystick +clear_pm_mem: + ldx #$00 ; 88A8 A2 00 .. txa ; 88AA 8A . -L88AB: sta $2B00,x ; 88AB 9D 00 2B ..+ +clr_loop: + sta $2B00,x ; 88AB 9D 00 2B ..+ sta $2C00,x ; 88AE 9D 00 2C .., sta $2D00,x ; 88B1 9D 00 2D ..- sta $2E00,x ; 88B4 9D 00 2E ... sta $2F00,x ; 88B7 9D 00 2F ../ dex ; 88BA CA . - bne L88AB ; 88BB D0 EE .. + bne clr_loop ; 88BB D0 EE .. rts ; 88BD 60 ` ; ---------------------------------------------------------------------------- @@ -3183,9 +3199,9 @@ setup_get_ready_dl: lda #$96 ; 9659 A9 96 .. sta work_level_sub0+1 ; 965B 8D 83 07 ... jsr clear_screen_mem_jv ; 965E 20 1E 80 .. - lda cur_level_map0 ; 9661 AD D6 07 ... + lda cur_level_map ; 9661 AD D6 07 ... sta dm_progctr ; 9664 85 C0 .. - lda cur_level_map0+1 ; 9666 AD D7 07 ... + lda cur_level_map+1 ; 9666 AD D7 07 ... sta dm_progctr+1 ; 9669 85 C1 .. jsr draw_map_jv ; 966B 20 00 80 .. L966E: lda jiffy_timer_2 ; 966E AD 1B 06 ... @@ -3207,13 +3223,13 @@ copy_level_desc_2: lda #$00 ; 9691 A9 00 .. sta COLOR4 ; 9693 8D C8 02 ... sta $06AB ; 9696 8D AB 06 ... - lda work_level_offs_46+1 ; 9699 AD AF 07 ... + lda work_level_colpf0 ; 9699 AD AF 07 ... sta COLOR0 ; 969C 8D C4 02 ... - lda work_level_offs_46+2 ; 969F AD B0 07 ... + lda work_level_colpf1 ; 969F AD B0 07 ... sta COLOR1 ; 96A2 8D C5 02 ... - lda work_level_offs_46+3 ; 96A5 AD B1 07 ... + lda work_level_colpf2 ; 96A5 AD B1 07 ... sta COLOR2 ; 96A8 8D C6 02 ... - lda work_level_offs_46 ; 96AB AD AE 07 ... + lda work_level_colpf3 ; 96AB AD AE 07 ... sta COLOR3 ; 96AE 8D C7 02 ... jsr setup_gameboard_dlist_jv ; 96B1 20 15 80 .. inc $06F5 ; 96B4 EE F5 06 ... @@ -3570,7 +3586,7 @@ L9949: lda player_x_pos ; 9949 AD 7E 06 sbc #$30 ; 994D E9 30 .0 sta zp_temp1 ; 994F 85 CB .. ldx #$08 ; 9951 A2 08 .. -L9953: lda work_level_offs_46+3,x ; 9953 BD B1 07 ... +L9953: lda work_level_colpf2,x ; 9953 BD B1 07 ... clc ; 9956 18 . adc #$02 ; 9957 69 02 i. cmp zp_temp1 ; 9959 C5 CB .. @@ -3585,7 +3601,7 @@ L9967: clc ; 9967 18 rts ; 9968 60 ` ; ---------------------------------------------------------------------------- -L9969: lda work_level_offs_46+3,x ; 9969 BD B1 07 ... +L9969: lda work_level_colpf2,x ; 9969 BD B1 07 ... clc ; 996C 18 . adc #$30 ; 996D 69 30 i0 sec ; 996F 38 8 @@ -4201,21 +4217,21 @@ level00_offs_19: ; pointer to ROM table or $06xx level00_unkn_table0: .addr L06DF ; A014 DF 06 .. -; map data -level00_map0: - .addr level00_map ; A016 00 A3 .. -; map data -level00_map1: - .addr LA366 ; A018 66 A3 f. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; used to draw the level initially (see also map_changes) +level00_map: + .addr l00_map ; A016 00 A3 .. +; start of bombs in map data (which must come last!) +level00_map_bombs: + .addr l00_map_bombs ; A018 66 A3 f. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level00_bomblist: - .addr LA38B ; A01A 8B A3 .. + .addr l00_bombs ; A01A 8B A3 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level00_map_changes: - .addr LA3A4 ; A01C A4 A3 .. + .addr l00_map_changes ; A01C A4 A3 .. ; ---------------------------------------------------------------------------- -; always $0000 -level00_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level00_indirect_subs: .byte $00,$00 ; A01E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4234,10 +4250,21 @@ level00_sub_eol: ; all zeroes level00_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A028 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level00_colpf3: + .byte $CA ; A02E CA . +; color for girders and up-ropes +level00_colpf0: + .byte $96 ; A02F 96 . +; color for ladders and down-ropes +level00_colpf1: + .byte $18 ; A030 18 . +; color for bombs +level00_colpf2: + .byte $5A ; A031 5A Z ; unknown -level00_offs_46: - .byte $CA,$96,$18,$5A,$0C,$24,$4C,$74 ; A02E CA 96 18 5A 0C 24 4C 74 ...Z.$Lt - .byte $8C ; A036 8C . +level00_offs_50: + .byte $0C,$24,$4C,$74,$8C ; A032 0C 24 4C 74 8C .$Lt. ; unknown, always $00 $00 $00 level00_offs_55: .byte $00,$00,$00 ; A037 00 00 00 ... @@ -4297,21 +4324,21 @@ level01_offs_19: ; pointer to ROM table or $06xx level01_unkn_table0: .addr LA5C2 ; A054 C2 A5 .. -; map data -level01_map0: - .addr LA3E0 ; A056 E0 A3 .. -; map data -level01_map1: +; used to draw the level initially (see also map_changes) +level01_map: + .addr l01_map ; A056 E0 A3 .. +; start of bombs in map data (which must come last!) +level01_map_bombs: .addr LA446 ; A058 46 A4 F. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level01_bomblist: .addr LA477 ; A05A 77 A4 w. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level01_map_changes: .addr L0000 ; A05C 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level01_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level01_indirect_subs: .byte $00,$00 ; A05E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4330,10 +4357,21 @@ level01_sub_eol: ; all zeroes level01_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A068 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level01_colpf3: + .byte $6A ; A06E 6A j +; color for girders and up-ropes +level01_colpf0: + .byte $08 ; A06F 08 . +; color for ladders and down-ropes +level01_colpf1: + .byte $C6 ; A070 C6 . +; color for bombs +level01_colpf2: + .byte $1A ; A071 1A . ; unknown -level01_offs_46: - .byte $6A,$08,$C6,$1A,$18,$4C,$80,$00 ; A06E 6A 08 C6 1A 18 4C 80 00 j....L.. - .byte $00 ; A076 00 . +level01_offs_50: + .byte $18,$4C,$80,$00,$00 ; A072 18 4C 80 00 00 .L... ; unknown, always $00 $00 $00 level01_offs_55: .byte $00,$00,$00 ; A077 00 00 00 ... @@ -4393,21 +4431,21 @@ level02_offs_19: ; pointer to ROM table or $06xx level02_unkn_table0: .addr LA66D ; A094 6D A6 m. -; map data -level02_map0: +; used to draw the level initially (see also map_changes) +level02_map: .addr LA5F0 ; A096 F0 A5 .. -; map data -level02_map1: +; start of bombs in map data (which must come last!) +level02_map_bombs: .addr LA62F ; A098 2F A6 /. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level02_bomblist: .addr LA654 ; A09A 54 A6 T. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level02_map_changes: .addr L0000 ; A09C 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level02_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level02_indirect_subs: .byte $00,$00 ; A09E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4426,10 +4464,21 @@ level02_sub_eol: ; all zeroes level02_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A0A8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level02_colpf3: + .byte $1A ; A0AE 1A . +; color for girders and up-ropes +level02_colpf0: + .byte $C6 ; A0AF C6 . +; color for ladders and down-ropes +level02_colpf1: + .byte $96 ; A0B0 96 . +; color for bombs +level02_colpf2: + .byte $1A ; A0B1 1A . ; unknown -level02_offs_46: - .byte $1A,$C6,$96,$1A,$0C,$8C,$00,$00 ; A0AE 1A C6 96 1A 0C 8C 00 00 ........ - .byte $00 ; A0B6 00 . +level02_offs_50: + .byte $0C,$8C,$00,$00,$00 ; A0B2 0C 8C 00 00 00 ..... ; unknown, always $00 $00 $00 level02_offs_55: .byte $00,$00,$00 ; A0B7 00 00 00 ... @@ -4489,21 +4538,21 @@ level03_offs_19: ; pointer to ROM table or $06xx level03_unkn_table0: .addr L06DF ; A0D4 DF 06 .. -; map data -level03_map0: +; used to draw the level initially (see also map_changes) +level03_map: .addr LA790 ; A0D6 90 A7 .. -; map data -level03_map1: +; start of bombs in map data (which must come last!) +level03_map_bombs: .addr LA7D5 ; A0D8 D5 A7 .. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level03_bomblist: .addr LA806 ; A0DA 06 A8 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level03_map_changes: .addr L0000 ; A0DC 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level03_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level03_indirect_subs: .byte $00,$00 ; A0DE 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4522,10 +4571,21 @@ level03_sub_eol: ; all zeroes level03_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A0E8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level03_colpf3: + .byte $CA ; A0EE CA . +; color for girders and up-ropes +level03_colpf0: + .byte $96 ; A0EF 96 . +; color for ladders and down-ropes +level03_colpf1: + .byte $18 ; A0F0 18 . +; color for bombs +level03_colpf2: + .byte $5A ; A0F1 5A Z ; unknown -level03_offs_46: - .byte $CA,$96,$18,$5A,$4C,$18,$2C,$80 ; A0EE CA 96 18 5A 4C 18 2C 80 ...ZL.,. - .byte $6C ; A0F6 6C l +level03_offs_50: + .byte $4C,$18,$2C,$80,$6C ; A0F2 4C 18 2C 80 6C L.,.l ; unknown, always $00 $00 $00 level03_offs_55: .byte $00,$00,$00 ; A0F7 00 00 00 ... @@ -4585,21 +4645,21 @@ level04_offs_19: ; pointer to ROM table or $06xx level04_unkn_table0: .addr L06DF ; A114 DF 06 .. -; map data -level04_map0: +; used to draw the level initially (see also map_changes) +level04_map: .addr LAAD0 ; A116 D0 AA .. -; map data -level04_map1: +; start of bombs in map data (which must come last!) +level04_map_bombs: .addr LAB42 ; A118 42 AB B. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level04_bomblist: .addr LAB6D ; A11A 6D AB m. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level04_map_changes: .addr LAB8A ; A11C 8A AB .. ; ---------------------------------------------------------------------------- -; always $0000 -level04_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level04_indirect_subs: .byte $00,$00 ; A11E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4618,10 +4678,21 @@ level04_sub_eol: ; all zeroes level04_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A128 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level04_colpf3: + .byte $6A ; A12E 6A j +; color for girders and up-ropes +level04_colpf0: + .byte $08 ; A12F 08 . +; color for ladders and down-ropes +level04_colpf1: + .byte $C6 ; A130 C6 . +; color for bombs +level04_colpf2: + .byte $1A ; A131 1A . ; unknown -level04_offs_46: - .byte $6A,$08,$C6,$1A,$0C,$22,$84,$8E ; A12E 6A 08 C6 1A 0C 22 84 8E j....".. - .byte $00 ; A136 00 . +level04_offs_50: + .byte $0C,$22,$84,$8E,$00 ; A132 0C 22 84 8E 00 ."... ; unknown, always $00 $00 $00 level04_offs_55: .byte $00,$00,$00 ; A137 00 00 00 ... @@ -4681,21 +4752,21 @@ level05_offs_19: ; pointer to ROM table or $06xx level05_unkn_table0: .addr L06DF ; A154 DF 06 .. -; map data -level05_map0: +; used to draw the level initially (see also map_changes) +level05_map: .addr LA920 ; A156 20 A9 . -; map data -level05_map1: +; start of bombs in map data (which must come last!) +level05_map_bombs: .addr LA974 ; A158 74 A9 t. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level05_bomblist: .addr LA9A5 ; A15A A5 A9 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level05_map_changes: .addr L0000 ; A15C 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level05_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level05_indirect_subs: .byte $00,$00 ; A15E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4714,10 +4785,21 @@ level05_sub_eol: ; all zeroes level05_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A168 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level05_colpf3: + .byte $56 ; A16E 56 V +; color for girders and up-ropes +level05_colpf0: + .byte $C6 ; A16F C6 . +; color for ladders and down-ropes +level05_colpf1: + .byte $96 ; A170 96 . +; color for bombs +level05_colpf2: + .byte $28 ; A171 28 ( ; unknown -level05_offs_46: - .byte $56,$C6,$96,$28,$04,$30,$68,$94 ; A16E 56 C6 96 28 04 30 68 94 V..(.0h. - .byte $00 ; A176 00 . +level05_offs_50: + .byte $04,$30,$68,$94,$00 ; A172 04 30 68 94 00 .0h.. ; unknown, always $00 $00 $00 level05_offs_55: .byte $00,$00,$00 ; A177 00 00 00 ... @@ -4777,21 +4859,21 @@ level06_offs_19: ; pointer to ROM table or $06xx level06_unkn_table0: .addr L06DF ; A194 DF 06 .. -; map data -level06_map0: +; used to draw the level initially (see also map_changes) +level06_map: .addr LAC60 ; A196 60 AC `. -; map data -level06_map1: +; start of bombs in map data (which must come last!) +level06_map_bombs: .addr LACBA ; A198 BA AC .. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level06_bomblist: .addr LACE5 ; A19A E5 AC .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level06_map_changes: .addr LAD02 ; A19C 02 AD .. ; ---------------------------------------------------------------------------- -; always $0000 -level06_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level06_indirect_subs: .byte $00,$00 ; A19E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4810,10 +4892,21 @@ level06_sub_eol: ; all zeroes level06_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A1A8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level06_colpf3: + .byte $CA ; A1AE CA . +; color for girders and up-ropes +level06_colpf0: + .byte $96 ; A1AF 96 . +; color for ladders and down-ropes +level06_colpf1: + .byte $18 ; A1B0 18 . +; color for bombs +level06_colpf2: + .byte $5A ; A1B1 5A Z ; unknown -level06_offs_46: - .byte $CA,$96,$18,$5A,$0C,$4C,$8C,$00 ; A1AE CA 96 18 5A 0C 4C 8C 00 ...Z.L.. - .byte $00 ; A1B6 00 . +level06_offs_50: + .byte $0C,$4C,$8C,$00,$00 ; A1B2 0C 4C 8C 00 00 .L... ; unknown, always $00 $00 $00 level06_offs_55: .byte $00,$00,$00 ; A1B7 00 00 00 ... @@ -4873,21 +4966,21 @@ level07_offs_19: ; pointer to ROM table or $06xx level07_unkn_table0: .addr LAE8A ; A1D4 8A AE .. -; map data -level07_map0: +; used to draw the level initially (see also map_changes) +level07_map: .addr LADE0 ; A1D6 E0 AD .. -; map data -level07_map1: +; start of bombs in map data (which must come last!) +level07_map_bombs: .addr LAE4C ; A1D8 4C AE L. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level07_bomblist: .addr LAE71 ; A1DA 71 AE q. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level07_map_changes: .addr L0000 ; A1DC 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level07_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level07_indirect_subs: .byte $00,$00 ; A1DE 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -4906,10 +4999,21 @@ level07_sub_eol: ; all zeroes level07_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A1E8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level07_colpf3: + .byte $6A ; A1EE 6A j +; color for girders and up-ropes +level07_colpf0: + .byte $08 ; A1EF 08 . +; color for ladders and down-ropes +level07_colpf1: + .byte $C6 ; A1F0 C6 . +; color for bombs +level07_colpf2: + .byte $1A ; A1F1 1A . ; unknown -level07_offs_46: - .byte $6A,$08,$C6,$1A,$0C,$30,$68,$8C ; A1EE 6A 08 C6 1A 0C 30 68 8C j....0h. - .byte $00 ; A1F6 00 . +level07_offs_50: + .byte $0C,$30,$68,$8C,$00 ; A1F2 0C 30 68 8C 00 .0h.. ; unknown, always $00 $00 $00 level07_offs_55: .byte $00,$00,$00 ; A1F7 00 00 00 ... @@ -4969,21 +5073,21 @@ level08_offs_19: ; pointer to ROM table or $06xx level08_unkn_table0: .addr L06DF ; A214 DF 06 .. -; map data -level08_map0: +; used to draw the level initially (see also map_changes) +level08_map: .addr LB0A2 ; A216 A2 B0 .. -; map data -level08_map1: +; start of bombs in map data (which must come last!) +level08_map_bombs: .addr LB072 ; A218 72 B0 r. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level08_bomblist: .addr LB0A3 ; A21A A3 B0 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level08_map_changes: .addr L0000 ; A21C 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level08_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level08_indirect_subs: .byte $00,$00 ; A21E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -5002,10 +5106,21 @@ level08_sub_eol: ; all zeroes level08_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A228 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level08_colpf3: + .byte $1A ; A22E 1A . +; color for girders and up-ropes +level08_colpf0: + .byte $C6 ; A22F C6 . +; color for ladders and down-ropes +level08_colpf1: + .byte $96 ; A230 96 . +; color for bombs +level08_colpf2: + .byte $28 ; A231 28 ( ; unknown -level08_offs_46: - .byte $1A,$C6,$96,$28,$0C,$3C,$00,$00 ; A22E 1A C6 96 28 0C 3C 00 00 ...(.<.. - .byte $8C ; A236 8C . +level08_offs_50: + .byte $0C,$3C,$00,$00,$8C ; A232 0C 3C 00 00 8C .<... ; unknown, always $00 $00 $00 level08_offs_55: .byte $00,$00,$00 ; A237 00 00 00 ... @@ -5065,21 +5180,21 @@ level09_offs_19: ; pointer to ROM table or $06xx level09_unkn_table0: .addr LB275 ; A254 75 B2 u. -; map data -level09_map0: +; used to draw the level initially (see also map_changes) +level09_map: .addr LB1E0 ; A256 E0 B1 .. -; map data -level09_map1: +; start of bombs in map data (which must come last!) +level09_map_bombs: .addr LB237 ; A258 37 B2 7. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level09_bomblist: .addr LB25C ; A25A 5C B2 \. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level09_map_changes: .addr L0000 ; A25C 00 00 .. ; ---------------------------------------------------------------------------- -; always $0000 -level09_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level09_indirect_subs: .byte $00,$00 ; A25E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -5098,10 +5213,21 @@ level09_sub_eol: ; all zeroes level09_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A268 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level09_colpf3: + .byte $CA ; A26E CA . +; color for girders and up-ropes +level09_colpf0: + .byte $96 ; A26F 96 . +; color for ladders and down-ropes +level09_colpf1: + .byte $18 ; A270 18 . +; color for bombs +level09_colpf2: + .byte $5A ; A271 5A Z ; unknown -level09_offs_46: - .byte $CA,$96,$18,$5A,$0C,$40,$8C,$00 ; A26E CA 96 18 5A 0C 40 8C 00 ...Z.@.. - .byte $00 ; A276 00 . +level09_offs_50: + .byte $0C,$40,$8C,$00,$00 ; A272 0C 40 8C 00 00 .@... ; unknown, always $00 $00 $00 level09_offs_55: .byte $00,$00,$00 ; A277 00 00 00 ... @@ -5161,21 +5287,21 @@ level10_offs_19: ; pointer to ROM table or $06xx level10_unkn_table0: .addr data_table_b50b ; A294 0B B5 .. -; map data -level10_map0: +; used to draw the level initially (see also map_changes) +level10_map: .addr LB320 ; A296 20 B3 . -; map data -level10_map1: +; start of bombs in map data (which must come last!) +level10_map_bombs: .addr LB38F ; A298 8F B3 .. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level10_bomblist: .addr LB3BD ; A29A BD B3 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level10_map_changes: .addr LB3DC ; A29C DC B3 .. ; ---------------------------------------------------------------------------- -; always $0000 -level10_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level10_indirect_subs: .byte $00,$00 ; A29E 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -5194,10 +5320,21 @@ level10_sub_eol: ; all zeroes level10_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A2A8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level10_colpf3: + .byte $6A ; A2AE 6A j +; color for girders and up-ropes +level10_colpf0: + .byte $08 ; A2AF 08 . +; color for ladders and down-ropes +level10_colpf1: + .byte $C6 ; A2B0 C6 . +; color for bombs +level10_colpf2: + .byte $1A ; A2B1 1A . ; unknown -level10_offs_46: - .byte $6A,$08,$C6,$1A,$0C,$30,$54,$8C ; A2AE 6A 08 C6 1A 0C 30 54 8C j....0T. - .byte $00 ; A2B6 00 . +level10_offs_50: + .byte $0C,$30,$54,$8C,$00 ; A2B2 0C 30 54 8C 00 .0T.. ; unknown, always $00 $00 $00 level10_offs_55: .byte $00,$00,$00 ; A2B7 00 00 00 ... @@ -5257,21 +5394,21 @@ level11_offs_19: ; pointer to ROM table or $06xx level11_unkn_table0: .addr LB658 ; A2D4 58 B6 X. -; map data -level11_map0: +; used to draw the level initially (see also map_changes) +level11_map: .addr data_b590 ; A2D6 90 B5 .. -; map data -level11_map1: +; start of bombs in map data (which must come last!) +level11_map_bombs: .addr LB5D2 ; A2D8 D2 B5 .. -; addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF. +; addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF. level11_bomblist: .addr LB5FD ; A2DA FD B5 .. ; address of list of addresses of map data, used for changing the map when certain bombs are picked up level11_map_changes: .addr LB61A ; A2DC 1A B6 .. ; ---------------------------------------------------------------------------- -; always $0000 -level11_offs_30: +; pointer to list of indirect subs, always $0000 in this game +level11_indirect_subs: .byte $00,$00 ; A2DE 00 00 .. ; ---------------------------------------------------------------------------- ; called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine @@ -5290,10 +5427,21 @@ level11_sub_eol: ; all zeroes level11_offs_40: .byte $00,$00,$00,$00,$00,$00 ; A2E8 00 00 00 00 00 00 ...... +; color (not sure what gets drawn in this color yet) +level11_colpf3: + .byte $08 ; A2EE 08 . +; color for girders and up-ropes +level11_colpf0: + .byte $C6 ; A2EF C6 . +; color for ladders and down-ropes +level11_colpf1: + .byte $96 ; A2F0 96 . +; color for bombs +level11_colpf2: + .byte $28 ; A2F1 28 ( ; unknown -level11_offs_46: - .byte $08,$C6,$96,$28,$0C,$2A,$4C,$6A ; A2EE 08 C6 96 28 0C 2A 4C 6A ...(.*Lj - .byte $8C ; A2F6 8C . +level11_offs_50: + .byte $0C,$2A,$4C,$6A,$8C ; A2F2 0C 2A 4C 6A 8C .*Lj. ; unknown, always $00 $00 $00 level11_offs_55: .byte $00,$00,$00 ; A2F7 00 00 00 ... @@ -5304,8 +5452,7 @@ level11_offs_58: level11_offs_60: .byte $00,$00,$00,$00 ; A2FC 00 00 00 00 .... ; level map data starts here -level00_map: - .byte $FE,$33,$9C,$FD,$04,$00,$44,$05 ; A300 FE 33 9C FD 04 00 44 05 .3....D. +l00_map:.byte $FE,$33,$9C,$FD,$04,$00,$44,$05 ; A300 FE 33 9C FD 04 00 44 05 .3....D. .byte $06,$04,$15,$0A,$74,$15,$0A,$24 ; A308 06 04 15 0A 74 15 0A 24 ....t..$ .byte $22,$02,$74,$22,$02,$24,$25,$16 ; A310 22 02 74 22 02 24 25 16 ".t".$%. .byte $04,$45,$04,$44,$45,$06,$8C,$45 ; A318 04 45 04 44 45 06 8C 45 .E.DE..E @@ -5318,24 +5465,48 @@ level00_map: .byte $15,$FE,$C9,$9C,$06,$18,$0A,$99 ; A350 15 FE C9 9C 06 18 0A 99 ........ .byte $18,$0A,$FE,$DA,$9C,$1D,$38,$06 ; A358 18 0A FE DA 9C 1D 38 06 ......8. .byte $81,$38,$06,$FE,$B3,$9C ; A360 81 38 06 FE B3 9C .8.... -LA366: .byte $04,$12,$01,$38,$02,$01,$64,$02 ; A366 04 12 01 38 02 01 64 02 ...8..d. +; gfx_draw instructions for bombs, used by bomb_pickup to get bomb coords. $ff terminated +l00_map_bombs: + .byte $04,$12,$01,$38,$02,$01,$64,$02 ; A366 04 12 01 38 02 01 64 02 ...8..d. .byte $01,$98,$12,$01,$44,$22,$01,$58 ; A36E 01 98 12 01 44 22 01 58 ....D".X .byte $22,$01,$04,$42,$01,$98,$42,$01 ; A376 22 01 04 42 01 98 42 01 "..B..B. .byte $04,$52,$01,$38,$52,$01,$64,$52 ; A37E 04 52 01 38 52 01 64 52 .R.8R.dR .byte $01,$98,$52,$01,$FF ; A386 01 98 52 01 FF ..R.. -LA38B: .byte $24,$00,$62,$10,$82,$20,$C4,$00 ; A38B 24 00 62 10 82 20 C4 00 $.b.. .. +; 2 bytes per entry, terminated by $FF. 1st byte is coarse grid coords (top nybble = X, bottom = Y), 2nd byte is index into map_changes +l00_bombs: + .byte $24,$00,$62,$10,$82,$20,$C4,$00 ; A38B 24 00 62 10 82 20 C4 00 $.b.. .. .byte $66,$30,$86,$40,$2A,$00,$CA,$00 ; A393 66 30 86 40 2A 00 CA 00 f0.@*... .byte $2C,$00,$6C,$00,$8C,$00,$CC,$00 ; A39B 2C 00 6C 00 8C 00 CC 00 ,.l..... +; terminator for l00_bombs +l00_bombs_term: .byte $FF ; A3A3 FF . -LA3A4: .byte $00,$00,$AE,$A3,$B8,$A3,$C2,$A3 ; A3A4 00 00 AE A3 B8 A3 C2 A3 ........ - .byte $CC,$A3,$FE,$49,$9C,$FD,$04,$01 ; A3AC CC A3 FE 49 9C FD 04 01 ...I.... - .byte $64,$08,$02,$FF,$FE,$49,$9C,$FD ; A3B4 64 08 02 FF FE 49 9C FD d....I.. - .byte $04,$FF,$34,$09,$02,$FF,$FE,$49 ; A3BC 04 FF 34 09 02 FF FE 49 ..4....I - .byte $9C,$FD,$04,$00,$2C,$25,$05,$FF ; A3C4 9C FD 04 00 2C 25 05 FF ....,%.. +; ---------------------------------------------------------------------------- +; 0000 = no change +l00_map_changes: + .addr L0000 ; A3A4 00 00 .. + .addr l00_map_change_0 ; A3A6 AE A3 .. + .addr l00_map_change_1 ; A3A8 B8 A3 .. + .addr l00_map_change_2 ; A3AA C2 A3 .. + .addr l00_map_change_3 ; A3AC CC A3 .. +; ---------------------------------------------------------------------------- +l00_map_change_0: + .byte $FE,$49,$9C,$FD,$04,$01,$64,$08 ; A3AE FE 49 9C FD 04 01 64 08 .I....d. + .byte $02,$FF ; A3B6 02 FF .. +l00_map_change_1: + .byte $FE,$49,$9C,$FD,$04,$FF,$34,$09 ; A3B8 FE 49 9C FD 04 FF 34 09 .I....4. + .byte $02,$FF ; A3C0 02 FF .. +l00_map_change_2: + .byte $FE,$49,$9C,$FD,$04,$00,$2C,$25 ; A3C2 FE 49 9C FD 04 00 2C 25 .I....,% + .byte $05,$FF ; A3CA 05 FF .. +l00_map_change_3: .byte $FE,$49,$9C,$FD,$04,$00,$60,$25 ; A3CC FE 49 9C FD 04 00 60 25 .I....`% - .byte $05,$FF,$00,$00,$00,$00,$00,$00 ; A3D4 05 FF 00 00 00 00 00 00 ........ - .byte $00,$00,$00,$00 ; A3DC 00 00 00 00 .... -LA3E0: .byte $FE,$33,$9C,$FD,$04,$00,$04,$05 ; A3E0 FE 33 9C FD 04 00 04 05 .3...... + .byte $05,$FF ; A3D4 05 FF .. +; probably just filler +zero_filler_a3d6: + .byte $00,$00,$00,$00,$00,$00,$00,$00 ; A3D6 00 00 00 00 00 00 00 00 ........ + .byte $00,$00 ; A3DE 00 00 .. +; level map data starts here +l01_map:.byte $FE,$33,$9C,$FD,$04,$00,$04,$05 ; A3E0 FE 33 9C FD 04 00 04 05 .3...... .byte $08,$34,$05,$0E,$7C,$05,$08,$14 ; A3E8 08 34 05 0E 7C 05 08 14 .4..|... .byte $15,$04,$34,$15,$04,$5C,$15,$04 ; A3F0 15 04 34 15 04 5C 15 04 ..4..\.. .byte $7C,$15,$04,$04,$25,$10,$5C,$25 ; A3F8 7C 15 04 04 25 10 5C 25 |...%.\% @@ -7063,9 +7234,9 @@ LBA00: lda #$40 ; BA00 A9 40 lda #$30 ; BA13 A9 30 .0 sta SAVMSC+1 ; BA15 85 59 .Y jsr clear_screen_mem_jv ; BA17 20 1E 80 .. - lda cur_level_map0 ; BA1A AD D6 07 ... + lda cur_level_map ; BA1A AD D6 07 ... sta dm_progctr ; BA1D 85 C0 .. - lda cur_level_map0+1 ; BA1F AD D7 07 ... + lda cur_level_map+1 ; BA1F AD D7 07 ... sta dm_progctr+1 ; BA22 85 C1 .. jsr draw_map_jv ; BA24 20 00 80 .. lda #$30 ; BA27 A9 30 .0 @@ -7111,13 +7282,13 @@ show_level_name: ; level is already drawn with all color regs set to black. for each color reg, wait 1 sec before turning it visible. this syncs up with the music because the music was written to sync with this actually sync_to_music: jsr wait_1_sec ; BA71 20 9E BA .. - lda cur_level_offs_46+3 ; BA74 AD F1 07 ... + lda cur_level_colpf2 ; BA74 AD F1 07 ... sta COLOR2 ; BA77 8D C6 02 ... jsr wait_1_sec ; BA7A 20 9E BA .. - lda cur_level_offs_46+2 ; BA7D AD F0 07 ... + lda cur_level_colpf1 ; BA7D AD F0 07 ... sta COLOR1 ; BA80 8D C5 02 ... jsr wait_1_sec ; BA83 20 9E BA .. - lda cur_level_offs_46+1 ; BA86 AD EF 07 ... + lda cur_level_colpf0 ; BA86 AD EF 07 ... sta COLOR0 ; BA89 8D C4 02 ... jsr wait_1_sec ; BA8C 20 9E BA .. lda #$00 ; BA8F A9 00 .. @@ -7252,7 +7423,7 @@ LBC5E: lda jiffy_timer_1 ; BC5E AD 1A 06 lda #$BD ; BC88 A9 BD .. sta work_level_sub1+1 ; BC8A 8D 85 07 ... lda #$4C ; BC8D A9 4C .L - sta work_level_offs_46+7 ; BC8F 8D B5 07 ... + sta work_level_offs_50+3 ; BC8F 8D B5 07 ... ; wait for score screen to finish (I think, anyway) wd_wait_scores: lda work_level_sub1 ; BC92 AD 84 07 ... diff --git a/jumpmanjr.info b/jumpmanjr.info index 94cdace..56c4e30 100644 --- a/jumpmanjr.info +++ b/jumpmanjr.info @@ -117,8 +117,10 @@ label { name "init_next_level"; addr $9BE8; size 1; comment "..."; }; label { name "show_get_ready_prompt"; addr $9624; size 1; comment "only in multiplayer games"; }; label { name "check_bomb_coll"; addr $87A0; size 1; comment "check whether Jumpman just touched a bomb (RTS if not)"; }; label { name "check_bomb_coll_jv"; addr $8033; size 1; comment "check whether Jumpman just touched a bomb (RTS if not)"; }; -label { name "bomb_pickup"; addr $87A8; size 1; comment "Jumpman just picked up a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, do some other stuff I don't understand yet"; }; +label { name "bomb_pickup"; addr $87A8; size 1; comment "Jumpman just touched a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, etc."; }; +label { name "coarse_grid"; addr $87C4; size 1; comment "screen X range approx $32 to $C6, Y $18 to $C0, meaning the coarse grid visible screen range is X 1-6, Y 0-6"; }; label { name "erase_bomb"; addr $8879; size 1; comment "make the bomb disappear by drawing sh_blank in its location"; }; +label { name "wait_bomb"; addr $888A; size 1; comment "wait for bomb to really disappear"; }; label { name "bomb_add_points"; addr $8865; size 1; comment "add points to score for picking up bomb (theoretically different on every level, but really $64 aka 100 for all of them)"; }; label { name "call_bomb_sub"; addr $8856; size 1; comment "call bomb pickup subroutine for this level (which might just do an RTS if there's no special action)"; }; label { name "call_bomb_indirect_sub"; addr $883E; size 1; comment "this would call a subroutine via pointer-to-pointer, but I'm almost 100% certain it's never used (maybe a holdover from original Jumpman?)"; }; @@ -127,8 +129,8 @@ label { name "bl_ok"; addr $87D7; size 1; }; label { name "bomb_found"; addr $87E0; size 1; }; label { name "bombloc"; addr $B6; size 1; comment "bomb_pickup: position of the bomb Jumpman just touched, on 8x8 coarse grid"; }; label { name "mul_y"; addr $87EA; size 1; comment "multiply Y by 1.5 (only works because Y will always be even at this point)"; }; -label { name "unkn1"; addr $87F2; size 1; comment "find out: why are we storing this at 06DC?"; }; -label { name "change_map"; addr $881B; size 1; comment "this has to do with redrawing parts of the level (e.g. disappearing platforms on level00)"; }; +label { name "store_bomb_coords"; addr $87F2; size 1; comment "store actual bomb coordinates (not the coarse ones) for bomb subs to use"; }; +label { name "change_map"; addr $881B; size 1; comment "some bombs redraw parts of the level (e.g. disappearing platforms on level00)"; }; label { name "check_ind_sub"; addr $8831; size 1; comment "see if this bomb calls an indirect sub (none of them do in this game, this is useless code)"; }; label { name "blistptr"; addr $B4; size 2; comment "bomb_pickup: points to current level's bomblist"; }; range { name "gr7_or_masks"; start $8143; end $8152; type bytetable; }; @@ -302,7 +304,21 @@ label { name "electrocution_done"; addr $A4DD; comment "turn off electrocution e label { name "electrocute"; addr $A509; comment "electrocution effect"; }; label { name "level02_collisions"; addr $A53D; comment "skip a couple of the collision regs, so we don't register a collision when Jumpman is being electrocuted"; }; label { name "start_jump"; addr $99A0; comment "start jumping, play sfx_jump"; }; -range { name "level00_map"; start $A300; end $a497; type bytetable; comment "level map data starts here"; }; + +range { name "l00_map"; start $A300; end $a365; type bytetable; comment "level map data starts here"; }; + +range { name "l00_map_bombs"; start $A366; end $A38A; type bytetable; comment "gfx_draw instructions for bombs, used by bomb_pickup to get bomb coords. $ff terminated"; }; +range { name "l00_bombs"; start $A38B; end $a3a2; type bytetable; comment "2 bytes per entry, terminated by $FF. 1st byte is coarse grid coords (top nybble = X, bottom = Y), 2nd byte is index into map_changes"; }; +range { name "l00_bombs_term"; start $a3a3; end $a3a3; type bytetable; comment "terminator for l00_bombs"; }; +range { name "l00_map_changes"; start $A3A4; end $a3ad; type addrtable; comment "0000 = no change"; }; +range { name "l00_map_change_0"; start $A3AE; end $a3d5; type bytetable; }; +label { name "l00_map_change_1"; addr $a3b8; }; +label { name "l00_map_change_2"; addr $a3c2; }; +label { name "l00_map_change_3"; addr $a3cc; }; +range { name "zero_filler_a3d6"; start $a3d6; end $a3df; type bytetable; comment "probably just filler"; }; + +range { name "l01_map"; start $A3e0; end $a497; type bytetable; comment "level map data starts here"; }; + range { name "sfx_electrocution"; start $A52D; end $A53C; type bytetable; }; range { name "data_a542"; start $A542; end $A68B; type bytetable; comment "dunno, referenced by electrocution_bomb_pickup"; }; range { name "dumbwaiter_player"; start $a782; end $A826; type bytetable; comment "the dumbwaiters from level02. stored upside-down."; }; @@ -526,7 +542,9 @@ label { name "HPOSP0_minus_two"; addr $CFFE; size 1; }; label { name "position_pm_vert"; addr $8322; size 1; }; label { name "clear_pm"; addr $8342; size 1; comment "write zeroes to unused portion of this player/missile"; }; label { name "position_done"; addr $82E8; size 1; }; -label { name "clear_pm_mem"; addr $872A; size 1; comment "clear P/M mem"; }; +label { name "clear_pm_mem"; addr $88A8; size 1; comment "clear P/M memory, called from enable_joystick"; }; +label { name "clr_loop"; addr $88AB; size 1; }; +label { name "prepare_level"; addr $872A; size 1; comment "misc stuff, called from enable_joystick"; }; label { name "clear_screen_mem"; addr $8714; size 1; comment "clear the gameboard screen memory (called before drawing a level, natch)"; }; label { name "clear_screen_mem_jv"; addr $801E; size 1; comment "clear the gameboard screen memory (called before drawing a level, natch)"; }; label { name "csm_loop"; addr $871F; size 1; }; @@ -606,17 +624,21 @@ label { name "work_level_points_per_bomb"; addr $0790; size 1; comment "points a label { name "work_level_time_bonus"; addr $0791; size 2; comment "amount of time bonus at start of level"; }; label { name "work_level_offs_19"; addr $0793; size 1; comment "always $00"; }; label { name "work_level_unkn_table0"; addr $0794; size 2; comment "pointer to ROM table or $06xx"; }; -label { name "work_level_map0"; addr $0796; size 2; comment "map data"; }; -label { name "work_level_map1"; addr $0798; size 2; comment "map data"; }; -label { name "work_level_bomblist"; addr $079a; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +label { name "work_level_map"; addr $0796; size 2; comment "used to draw the level initially (see also map_changes)"; }; +label { name "work_level_map_bombs"; addr $0798; size 2; comment "start of bombs in map data (which must come last!)"; }; +label { name "work_level_bomblist"; addr $079a; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; label { name "work_level_map_changes"; addr $079c; size 2; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -label { name "work_level_offs_30"; addr $079e; size 2; comment "always $0000"; }; +label { name "work_level_indirect_subs"; addr $079e; size 2; comment "pointer to list of indirect subs, always $0000 in this game"; }; label { name "work_level_sub_bomb"; addr $07a0; size 2; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; label { name "work_level_sub_start"; addr $07a2; size 2; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; label { name "work_level_sub6"; addr $07a4; size 2; comment "always $9740 aka game_main_loop"; }; label { name "work_level_sub_eol"; addr $07a6; size 2; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; label { name "work_level_offs_40"; addr $07a8; size 6; comment "all zeroes"; }; -label { name "work_level_offs_46"; addr $07ae; size 9; comment "unknown"; }; +label { name "work_level_colpf3"; addr $07ae; size 1; comment "color (not sure what gets drawn in this color yet)"; }; +label { name "work_level_colpf0"; addr $07af; size 1; comment "color for girders and up-ropes"; }; +label { name "work_level_colpf1"; addr $07b0; size 1; comment "color for ladders and down-ropes"; }; +label { name "work_level_colpf2"; addr $07b1; size 1; comment "color for bombs"; }; +label { name "work_level_offs_50"; addr $07b2; size 5; comment "unknown"; }; label { name "work_level_offs_55"; addr $07b7; size 3; comment "unknown, always $00 $00 $00"; }; label { name "work_level_offs_58"; addr $07ba; size 2; comment "unknown, not a ROM address"; }; label { name "work_level_offs_60"; addr $07bc; size 4; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -636,17 +658,21 @@ label { name "cur_level_points_per_bomb"; addr $07d0; size 1; comment "points aw label { name "cur_level_time_bonus"; addr $07d1; size 2; comment "amount of time bonus at start of level"; }; label { name "cur_level_offs_19"; addr $07d3; size 1; comment "always $00"; }; label { name "cur_level_unkn_table0"; addr $07d4; size 2; comment "pointer to ROM table or $06xx"; }; -label { name "cur_level_map0"; addr $07d6; size 2; comment "map data"; }; -label { name "cur_level_map1"; addr $07d8; size 2; comment "map data"; }; -label { name "cur_level_bomblist"; addr $07da; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +label { name "cur_level_map"; addr $07d6; size 2; comment "used to draw the level initially (see also map_changes)"; }; +label { name "cur_level_map_bombs"; addr $07d8; size 2; comment "start of bombs in map data (which must come last!)"; }; +label { name "cur_level_bomblist"; addr $07da; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; label { name "cur_level_map_changes"; addr $07dc; size 2; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -label { name "cur_level_offs_30"; addr $07de; size 2; comment "always $0000"; }; +label { name "cur_level_indirect_subs"; addr $07de; size 2; comment "pointer to list of indirect subs, always $0000 in this game"; }; label { name "cur_level_sub_bomb"; addr $07e0; size 2; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; label { name "cur_level_sub_start"; addr $07e2; size 2; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; label { name "cur_level_sub6"; addr $07e4; size 2; comment "always $9740 aka game_main_loop"; }; label { name "cur_level_sub_eol"; addr $07e6; size 2; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; label { name "cur_level_offs_40"; addr $07e8; size 6; comment "all zeroes"; }; -label { name "cur_level_offs_46"; addr $07ee; size 9; comment "unknown"; }; +label { name "cur_level_colpf3"; addr $07ee; size 1; comment "color (not sure what gets drawn in this color yet)"; }; +label { name "cur_level_colpf0"; addr $07ef; size 1; comment "color for girders and up-ropes"; }; +label { name "cur_level_colpf1"; addr $07f0; size 1; comment "color for ladders and down-ropes"; }; +label { name "cur_level_colpf2"; addr $07f1; size 1; comment "color for bombs"; }; +label { name "cur_level_offs_50"; addr $07f2; size 5; comment "unknown"; }; label { name "cur_level_offs_55"; addr $07f7; size 3; comment "unknown, always $00 $00 $00"; }; label { name "cur_level_offs_58"; addr $07fa; size 2; comment "unknown, not a ROM address"; }; label { name "cur_level_offs_60"; addr $07fc; size 4; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -666,17 +692,21 @@ range { name "level00_points_per_bomb"; start $a010; end $a010; type bytetable; range { name "level00_time_bonus"; start $a011; end $a012; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level00_offs_19"; start $a013; end $a013; type bytetable; comment "always $00"; }; range { name "level00_unkn_table0"; start $a014; end $a015; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level00_map0"; start $a016; end $a017; type addrtable; comment "map data"; }; -range { name "level00_map1"; start $a018; end $a019; type addrtable; comment "map data"; }; -range { name "level00_bomblist"; start $a01a; end $a01b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level00_map"; start $a016; end $a017; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level00_map_bombs"; start $a018; end $a019; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level00_bomblist"; start $a01a; end $a01b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level00_map_changes"; start $a01c; end $a01d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level00_offs_30"; start $a01e; end $a01f; type bytetable; comment "always $0000"; }; +range { name "level00_indirect_subs"; start $a01e; end $a01f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level00_sub_bomb"; start $a020; end $a021; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level00_sub_start"; start $a022; end $a023; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level00_sub6"; start $a024; end $a025; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level00_sub_eol"; start $a026; end $a027; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level00_offs_40"; start $a028; end $a02d; type bytetable; comment "all zeroes"; }; -range { name "level00_offs_46"; start $a02e; end $a036; type bytetable; comment "unknown"; }; +range { name "level00_colpf3"; start $a02e; end $a02e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level00_colpf0"; start $a02f; end $a02f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level00_colpf1"; start $a030; end $a030; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level00_colpf2"; start $a031; end $a031; type bytetable; comment "color for bombs"; }; +range { name "level00_offs_50"; start $a032; end $a036; type bytetable; comment "unknown"; }; range { name "level00_offs_55"; start $a037; end $a039; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level00_offs_58"; start $a03a; end $a03b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level00_offs_60"; start $a03c; end $a03f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -696,17 +726,21 @@ range { name "level01_points_per_bomb"; start $a050; end $a050; type bytetable; range { name "level01_time_bonus"; start $a051; end $a052; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level01_offs_19"; start $a053; end $a053; type bytetable; comment "always $00"; }; range { name "level01_unkn_table0"; start $a054; end $a055; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level01_map0"; start $a056; end $a057; type addrtable; comment "map data"; }; -range { name "level01_map1"; start $a058; end $a059; type addrtable; comment "map data"; }; -range { name "level01_bomblist"; start $a05a; end $a05b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level01_map"; start $a056; end $a057; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level01_map_bombs"; start $a058; end $a059; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level01_bomblist"; start $a05a; end $a05b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level01_map_changes"; start $a05c; end $a05d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level01_offs_30"; start $a05e; end $a05f; type bytetable; comment "always $0000"; }; +range { name "level01_indirect_subs"; start $a05e; end $a05f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level01_sub_bomb"; start $a060; end $a061; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level01_sub_start"; start $a062; end $a063; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level01_sub6"; start $a064; end $a065; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level01_sub_eol"; start $a066; end $a067; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level01_offs_40"; start $a068; end $a06d; type bytetable; comment "all zeroes"; }; -range { name "level01_offs_46"; start $a06e; end $a076; type bytetable; comment "unknown"; }; +range { name "level01_colpf3"; start $a06e; end $a06e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level01_colpf0"; start $a06f; end $a06f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level01_colpf1"; start $a070; end $a070; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level01_colpf2"; start $a071; end $a071; type bytetable; comment "color for bombs"; }; +range { name "level01_offs_50"; start $a072; end $a076; type bytetable; comment "unknown"; }; range { name "level01_offs_55"; start $a077; end $a079; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level01_offs_58"; start $a07a; end $a07b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level01_offs_60"; start $a07c; end $a07f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -726,17 +760,21 @@ range { name "level02_points_per_bomb"; start $a090; end $a090; type bytetable; range { name "level02_time_bonus"; start $a091; end $a092; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level02_offs_19"; start $a093; end $a093; type bytetable; comment "always $00"; }; range { name "level02_unkn_table0"; start $a094; end $a095; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level02_map0"; start $a096; end $a097; type addrtable; comment "map data"; }; -range { name "level02_map1"; start $a098; end $a099; type addrtable; comment "map data"; }; -range { name "level02_bomblist"; start $a09a; end $a09b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level02_map"; start $a096; end $a097; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level02_map_bombs"; start $a098; end $a099; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level02_bomblist"; start $a09a; end $a09b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level02_map_changes"; start $a09c; end $a09d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level02_offs_30"; start $a09e; end $a09f; type bytetable; comment "always $0000"; }; +range { name "level02_indirect_subs"; start $a09e; end $a09f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level02_sub_bomb"; start $a0a0; end $a0a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level02_sub_start"; start $a0a2; end $a0a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level02_sub6"; start $a0a4; end $a0a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level02_sub_eol"; start $a0a6; end $a0a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level02_offs_40"; start $a0a8; end $a0ad; type bytetable; comment "all zeroes"; }; -range { name "level02_offs_46"; start $a0ae; end $a0b6; type bytetable; comment "unknown"; }; +range { name "level02_colpf3"; start $a0ae; end $a0ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level02_colpf0"; start $a0af; end $a0af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level02_colpf1"; start $a0b0; end $a0b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level02_colpf2"; start $a0b1; end $a0b1; type bytetable; comment "color for bombs"; }; +range { name "level02_offs_50"; start $a0b2; end $a0b6; type bytetable; comment "unknown"; }; range { name "level02_offs_55"; start $a0b7; end $a0b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level02_offs_58"; start $a0ba; end $a0bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level02_offs_60"; start $a0bc; end $a0bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -756,17 +794,21 @@ range { name "level03_points_per_bomb"; start $a0d0; end $a0d0; type bytetable; range { name "level03_time_bonus"; start $a0d1; end $a0d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level03_offs_19"; start $a0d3; end $a0d3; type bytetable; comment "always $00"; }; range { name "level03_unkn_table0"; start $a0d4; end $a0d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level03_map0"; start $a0d6; end $a0d7; type addrtable; comment "map data"; }; -range { name "level03_map1"; start $a0d8; end $a0d9; type addrtable; comment "map data"; }; -range { name "level03_bomblist"; start $a0da; end $a0db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level03_map"; start $a0d6; end $a0d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level03_map_bombs"; start $a0d8; end $a0d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level03_bomblist"; start $a0da; end $a0db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level03_map_changes"; start $a0dc; end $a0dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level03_offs_30"; start $a0de; end $a0df; type bytetable; comment "always $0000"; }; +range { name "level03_indirect_subs"; start $a0de; end $a0df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level03_sub_bomb"; start $a0e0; end $a0e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level03_sub_start"; start $a0e2; end $a0e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level03_sub6"; start $a0e4; end $a0e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level03_sub_eol"; start $a0e6; end $a0e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level03_offs_40"; start $a0e8; end $a0ed; type bytetable; comment "all zeroes"; }; -range { name "level03_offs_46"; start $a0ee; end $a0f6; type bytetable; comment "unknown"; }; +range { name "level03_colpf3"; start $a0ee; end $a0ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level03_colpf0"; start $a0ef; end $a0ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level03_colpf1"; start $a0f0; end $a0f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level03_colpf2"; start $a0f1; end $a0f1; type bytetable; comment "color for bombs"; }; +range { name "level03_offs_50"; start $a0f2; end $a0f6; type bytetable; comment "unknown"; }; range { name "level03_offs_55"; start $a0f7; end $a0f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level03_offs_58"; start $a0fa; end $a0fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level03_offs_60"; start $a0fc; end $a0ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -786,17 +828,21 @@ range { name "level04_points_per_bomb"; start $a110; end $a110; type bytetable; range { name "level04_time_bonus"; start $a111; end $a112; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level04_offs_19"; start $a113; end $a113; type bytetable; comment "always $00"; }; range { name "level04_unkn_table0"; start $a114; end $a115; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level04_map0"; start $a116; end $a117; type addrtable; comment "map data"; }; -range { name "level04_map1"; start $a118; end $a119; type addrtable; comment "map data"; }; -range { name "level04_bomblist"; start $a11a; end $a11b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level04_map"; start $a116; end $a117; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level04_map_bombs"; start $a118; end $a119; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level04_bomblist"; start $a11a; end $a11b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level04_map_changes"; start $a11c; end $a11d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level04_offs_30"; start $a11e; end $a11f; type bytetable; comment "always $0000"; }; +range { name "level04_indirect_subs"; start $a11e; end $a11f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level04_sub_bomb"; start $a120; end $a121; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level04_sub_start"; start $a122; end $a123; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level04_sub6"; start $a124; end $a125; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level04_sub_eol"; start $a126; end $a127; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level04_offs_40"; start $a128; end $a12d; type bytetable; comment "all zeroes"; }; -range { name "level04_offs_46"; start $a12e; end $a136; type bytetable; comment "unknown"; }; +range { name "level04_colpf3"; start $a12e; end $a12e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level04_colpf0"; start $a12f; end $a12f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level04_colpf1"; start $a130; end $a130; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level04_colpf2"; start $a131; end $a131; type bytetable; comment "color for bombs"; }; +range { name "level04_offs_50"; start $a132; end $a136; type bytetable; comment "unknown"; }; range { name "level04_offs_55"; start $a137; end $a139; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level04_offs_58"; start $a13a; end $a13b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level04_offs_60"; start $a13c; end $a13f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -816,17 +862,21 @@ range { name "level05_points_per_bomb"; start $a150; end $a150; type bytetable; range { name "level05_time_bonus"; start $a151; end $a152; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level05_offs_19"; start $a153; end $a153; type bytetable; comment "always $00"; }; range { name "level05_unkn_table0"; start $a154; end $a155; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level05_map0"; start $a156; end $a157; type addrtable; comment "map data"; }; -range { name "level05_map1"; start $a158; end $a159; type addrtable; comment "map data"; }; -range { name "level05_bomblist"; start $a15a; end $a15b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level05_map"; start $a156; end $a157; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level05_map_bombs"; start $a158; end $a159; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level05_bomblist"; start $a15a; end $a15b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level05_map_changes"; start $a15c; end $a15d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level05_offs_30"; start $a15e; end $a15f; type bytetable; comment "always $0000"; }; +range { name "level05_indirect_subs"; start $a15e; end $a15f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level05_sub_bomb"; start $a160; end $a161; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level05_sub_start"; start $a162; end $a163; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level05_sub6"; start $a164; end $a165; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level05_sub_eol"; start $a166; end $a167; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level05_offs_40"; start $a168; end $a16d; type bytetable; comment "all zeroes"; }; -range { name "level05_offs_46"; start $a16e; end $a176; type bytetable; comment "unknown"; }; +range { name "level05_colpf3"; start $a16e; end $a16e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level05_colpf0"; start $a16f; end $a16f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level05_colpf1"; start $a170; end $a170; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level05_colpf2"; start $a171; end $a171; type bytetable; comment "color for bombs"; }; +range { name "level05_offs_50"; start $a172; end $a176; type bytetable; comment "unknown"; }; range { name "level05_offs_55"; start $a177; end $a179; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level05_offs_58"; start $a17a; end $a17b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level05_offs_60"; start $a17c; end $a17f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -846,17 +896,21 @@ range { name "level06_points_per_bomb"; start $a190; end $a190; type bytetable; range { name "level06_time_bonus"; start $a191; end $a192; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level06_offs_19"; start $a193; end $a193; type bytetable; comment "always $00"; }; range { name "level06_unkn_table0"; start $a194; end $a195; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level06_map0"; start $a196; end $a197; type addrtable; comment "map data"; }; -range { name "level06_map1"; start $a198; end $a199; type addrtable; comment "map data"; }; -range { name "level06_bomblist"; start $a19a; end $a19b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level06_map"; start $a196; end $a197; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level06_map_bombs"; start $a198; end $a199; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level06_bomblist"; start $a19a; end $a19b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level06_map_changes"; start $a19c; end $a19d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level06_offs_30"; start $a19e; end $a19f; type bytetable; comment "always $0000"; }; +range { name "level06_indirect_subs"; start $a19e; end $a19f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level06_sub_bomb"; start $a1a0; end $a1a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level06_sub_start"; start $a1a2; end $a1a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level06_sub6"; start $a1a4; end $a1a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level06_sub_eol"; start $a1a6; end $a1a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level06_offs_40"; start $a1a8; end $a1ad; type bytetable; comment "all zeroes"; }; -range { name "level06_offs_46"; start $a1ae; end $a1b6; type bytetable; comment "unknown"; }; +range { name "level06_colpf3"; start $a1ae; end $a1ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level06_colpf0"; start $a1af; end $a1af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level06_colpf1"; start $a1b0; end $a1b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level06_colpf2"; start $a1b1; end $a1b1; type bytetable; comment "color for bombs"; }; +range { name "level06_offs_50"; start $a1b2; end $a1b6; type bytetable; comment "unknown"; }; range { name "level06_offs_55"; start $a1b7; end $a1b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level06_offs_58"; start $a1ba; end $a1bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level06_offs_60"; start $a1bc; end $a1bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -876,17 +930,21 @@ range { name "level07_points_per_bomb"; start $a1d0; end $a1d0; type bytetable; range { name "level07_time_bonus"; start $a1d1; end $a1d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level07_offs_19"; start $a1d3; end $a1d3; type bytetable; comment "always $00"; }; range { name "level07_unkn_table0"; start $a1d4; end $a1d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level07_map0"; start $a1d6; end $a1d7; type addrtable; comment "map data"; }; -range { name "level07_map1"; start $a1d8; end $a1d9; type addrtable; comment "map data"; }; -range { name "level07_bomblist"; start $a1da; end $a1db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level07_map"; start $a1d6; end $a1d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level07_map_bombs"; start $a1d8; end $a1d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level07_bomblist"; start $a1da; end $a1db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level07_map_changes"; start $a1dc; end $a1dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level07_offs_30"; start $a1de; end $a1df; type bytetable; comment "always $0000"; }; +range { name "level07_indirect_subs"; start $a1de; end $a1df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level07_sub_bomb"; start $a1e0; end $a1e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level07_sub_start"; start $a1e2; end $a1e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level07_sub6"; start $a1e4; end $a1e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level07_sub_eol"; start $a1e6; end $a1e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level07_offs_40"; start $a1e8; end $a1ed; type bytetable; comment "all zeroes"; }; -range { name "level07_offs_46"; start $a1ee; end $a1f6; type bytetable; comment "unknown"; }; +range { name "level07_colpf3"; start $a1ee; end $a1ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level07_colpf0"; start $a1ef; end $a1ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level07_colpf1"; start $a1f0; end $a1f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level07_colpf2"; start $a1f1; end $a1f1; type bytetable; comment "color for bombs"; }; +range { name "level07_offs_50"; start $a1f2; end $a1f6; type bytetable; comment "unknown"; }; range { name "level07_offs_55"; start $a1f7; end $a1f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level07_offs_58"; start $a1fa; end $a1fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level07_offs_60"; start $a1fc; end $a1ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -906,17 +964,21 @@ range { name "level08_points_per_bomb"; start $a210; end $a210; type bytetable; range { name "level08_time_bonus"; start $a211; end $a212; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level08_offs_19"; start $a213; end $a213; type bytetable; comment "always $00"; }; range { name "level08_unkn_table0"; start $a214; end $a215; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level08_map0"; start $a216; end $a217; type addrtable; comment "map data"; }; -range { name "level08_map1"; start $a218; end $a219; type addrtable; comment "map data"; }; -range { name "level08_bomblist"; start $a21a; end $a21b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level08_map"; start $a216; end $a217; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level08_map_bombs"; start $a218; end $a219; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level08_bomblist"; start $a21a; end $a21b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level08_map_changes"; start $a21c; end $a21d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level08_offs_30"; start $a21e; end $a21f; type bytetable; comment "always $0000"; }; +range { name "level08_indirect_subs"; start $a21e; end $a21f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level08_sub_bomb"; start $a220; end $a221; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level08_sub_start"; start $a222; end $a223; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level08_sub6"; start $a224; end $a225; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level08_sub_eol"; start $a226; end $a227; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level08_offs_40"; start $a228; end $a22d; type bytetable; comment "all zeroes"; }; -range { name "level08_offs_46"; start $a22e; end $a236; type bytetable; comment "unknown"; }; +range { name "level08_colpf3"; start $a22e; end $a22e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level08_colpf0"; start $a22f; end $a22f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level08_colpf1"; start $a230; end $a230; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level08_colpf2"; start $a231; end $a231; type bytetable; comment "color for bombs"; }; +range { name "level08_offs_50"; start $a232; end $a236; type bytetable; comment "unknown"; }; range { name "level08_offs_55"; start $a237; end $a239; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level08_offs_58"; start $a23a; end $a23b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level08_offs_60"; start $a23c; end $a23f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -936,17 +998,21 @@ range { name "level09_points_per_bomb"; start $a250; end $a250; type bytetable; range { name "level09_time_bonus"; start $a251; end $a252; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level09_offs_19"; start $a253; end $a253; type bytetable; comment "always $00"; }; range { name "level09_unkn_table0"; start $a254; end $a255; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level09_map0"; start $a256; end $a257; type addrtable; comment "map data"; }; -range { name "level09_map1"; start $a258; end $a259; type addrtable; comment "map data"; }; -range { name "level09_bomblist"; start $a25a; end $a25b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level09_map"; start $a256; end $a257; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level09_map_bombs"; start $a258; end $a259; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level09_bomblist"; start $a25a; end $a25b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level09_map_changes"; start $a25c; end $a25d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level09_offs_30"; start $a25e; end $a25f; type bytetable; comment "always $0000"; }; +range { name "level09_indirect_subs"; start $a25e; end $a25f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level09_sub_bomb"; start $a260; end $a261; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level09_sub_start"; start $a262; end $a263; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level09_sub6"; start $a264; end $a265; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level09_sub_eol"; start $a266; end $a267; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level09_offs_40"; start $a268; end $a26d; type bytetable; comment "all zeroes"; }; -range { name "level09_offs_46"; start $a26e; end $a276; type bytetable; comment "unknown"; }; +range { name "level09_colpf3"; start $a26e; end $a26e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level09_colpf0"; start $a26f; end $a26f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level09_colpf1"; start $a270; end $a270; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level09_colpf2"; start $a271; end $a271; type bytetable; comment "color for bombs"; }; +range { name "level09_offs_50"; start $a272; end $a276; type bytetable; comment "unknown"; }; range { name "level09_offs_55"; start $a277; end $a279; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level09_offs_58"; start $a27a; end $a27b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level09_offs_60"; start $a27c; end $a27f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -966,17 +1032,21 @@ range { name "level10_points_per_bomb"; start $a290; end $a290; type bytetable; range { name "level10_time_bonus"; start $a291; end $a292; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level10_offs_19"; start $a293; end $a293; type bytetable; comment "always $00"; }; range { name "level10_unkn_table0"; start $a294; end $a295; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level10_map0"; start $a296; end $a297; type addrtable; comment "map data"; }; -range { name "level10_map1"; start $a298; end $a299; type addrtable; comment "map data"; }; -range { name "level10_bomblist"; start $a29a; end $a29b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level10_map"; start $a296; end $a297; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level10_map_bombs"; start $a298; end $a299; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level10_bomblist"; start $a29a; end $a29b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level10_map_changes"; start $a29c; end $a29d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level10_offs_30"; start $a29e; end $a29f; type bytetable; comment "always $0000"; }; +range { name "level10_indirect_subs"; start $a29e; end $a29f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level10_sub_bomb"; start $a2a0; end $a2a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level10_sub_start"; start $a2a2; end $a2a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level10_sub6"; start $a2a4; end $a2a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level10_sub_eol"; start $a2a6; end $a2a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level10_offs_40"; start $a2a8; end $a2ad; type bytetable; comment "all zeroes"; }; -range { name "level10_offs_46"; start $a2ae; end $a2b6; type bytetable; comment "unknown"; }; +range { name "level10_colpf3"; start $a2ae; end $a2ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level10_colpf0"; start $a2af; end $a2af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level10_colpf1"; start $a2b0; end $a2b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level10_colpf2"; start $a2b1; end $a2b1; type bytetable; comment "color for bombs"; }; +range { name "level10_offs_50"; start $a2b2; end $a2b6; type bytetable; comment "unknown"; }; range { name "level10_offs_55"; start $a2b7; end $a2b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level10_offs_58"; start $a2ba; end $a2bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level10_offs_60"; start $a2bc; end $a2bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -996,17 +1066,21 @@ range { name "level11_points_per_bomb"; start $a2d0; end $a2d0; type bytetable; range { name "level11_time_bonus"; start $a2d1; end $a2d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level11_offs_19"; start $a2d3; end $a2d3; type bytetable; comment "always $00"; }; range { name "level11_unkn_table0"; start $a2d4; end $a2d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level11_map0"; start $a2d6; end $a2d7; type addrtable; comment "map data"; }; -range { name "level11_map1"; start $a2d8; end $a2d9; type addrtable; comment "map data"; }; -range { name "level11_bomblist"; start $a2da; end $a2db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level11_map"; start $a2d6; end $a2d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level11_map_bombs"; start $a2d8; end $a2d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level11_bomblist"; start $a2da; end $a2db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level11_map_changes"; start $a2dc; end $a2dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level11_offs_30"; start $a2de; end $a2df; type bytetable; comment "always $0000"; }; +range { name "level11_indirect_subs"; start $a2de; end $a2df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level11_sub_bomb"; start $a2e0; end $a2e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level11_sub_start"; start $a2e2; end $a2e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level11_sub6"; start $a2e4; end $a2e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level11_sub_eol"; start $a2e6; end $a2e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level11_offs_40"; start $a2e8; end $a2ed; type bytetable; comment "all zeroes"; }; -range { name "level11_offs_46"; start $a2ee; end $a2f6; type bytetable; comment "unknown"; }; +range { name "level11_colpf3"; start $a2ee; end $a2ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level11_colpf0"; start $a2ef; end $a2ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level11_colpf1"; start $a2f0; end $a2f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level11_colpf2"; start $a2f1; end $a2f1; type bytetable; comment "color for bombs"; }; +range { name "level11_offs_50"; start $a2f2; end $a2f6; type bytetable; comment "unknown"; }; range { name "level11_offs_55"; start $a2f7; end $a2f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level11_offs_58"; start $a2fa; end $a2fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level11_offs_60"; start $a2fc; end $a2ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; diff --git a/level_maps.txt b/level_maps.txt index b114485..cfbda56 100644 --- a/level_maps.txt +++ b/level_maps.txt @@ -1,6 +1,12 @@ Level Maps ---------- +There are 13 primary maps (one per level, plus the WELL DONE screen). Some +levels also have secondary map data, which is used for changing parts +of the map during the level (e.g. the disappearing girders on level 1). + +Here's the map for the first level, as a disassembly: + level00_map: .byte $FE,$33,$9C,$FD,$04,$00,$44,$05 ; A300 FE 33 9C FD 04 00 44 05 .3....D. .byte $06,$04,$15,$0A,$74,$15,$0A,$24 ; A308 06 04 15 0A 74 15 0A 24 ....t..$ @@ -15,6 +21,13 @@ level00_map: .byte $15,$FE,$C9,$9C,$06,$18,$0A,$99 ; A350 15 FE C9 9C 06 18 0A 99 ........ .byte $18,$0A,$FE,$DA,$9C,$1D,$38,$06 ; A358 18 0A FE DA 9C 1D 38 06 ......8. .byte $81,$38,$06,$FE,$B3,$9C ; A360 81 38 06 FE B3 9C .8.... +level00_map_bombs: + .byte $04,$12,$01,$38,$02,$01,$64,$02 ; A366 04 12 01 38 02 01 64 02 ...8..d. + .byte $01,$98,$12,$01,$44,$22,$01,$58 ; A36E 01 98 12 01 44 22 01 58 ....D".X + .byte $22,$01,$04,$42,$01,$98,$42,$01 ; A376 22 01 04 42 01 98 42 01 "..B..B. + .byte $04,$52,$01,$38,$52,$01,$64,$52 ; A37E 04 52 01 38 52 01 64 52 .R.8R.dR + .byte $01,$98,$52,$01,$FF ; A386 01 98 52 01 FF ..R.. + A300: FE 33 9C selects a shape (in this case, a girder) A303: FD 04 00 sets the X and Y delta (4 pixels X, 0 lines Y) @@ -29,20 +42,28 @@ A30B: 0A is the number of copies to draw horizontally from left to right. A32A: $FD,$04,$FF sets a new X/Y delta. now we're drawing left and -down, for the diagonal girders (aka ramps) that run SW to NE. +up, for the diagonal girders (aka ramps) that run SW to NE. -A333: $FD,$04,$01 is X/Y delta, drawing left and up, for the ramps +A333: $FD,$04,$01 is X/Y delta, drawing left and down, for the ramps that run NW to SE (tilted the other way from the previous set). -A33C: $FE,$5F,$9C selects a different shape (ladders) +A33C: $FE,$5F,$9C selects a different shape (ladders). There are more +$FE's to select ladders, up/down ropes, and bombs... + +The bombs *must* come last! They have their own label here, +level00_map_bombs. This is because the level_desc structure has a 2nd +map data pointer to the bombs, used by bomb_pickup for determining the +location of the bomb that was just picked up. Most levels don't even +use the position, but it's always stored at $06DC/$06DD for use by the +bomb_sub (if there is one). so eventually, I need ca65 macros that resemble instructions that assemble into map data. Something like: -set_gfx $9Cee -set_delta $04,$00 -draw_gfx $44,$05,$06 -draw_gfx $04,$15,$0A +gfx_shape $9C33 +gfx_delta $04,$00 +gfx_draw $44,$05,$06 +gfx_draw $04,$15,$0A ...notionally the drawing engine is a little CPU with 3 16-bit registers: a program counter (stored at $C0), gfx (the graphic object it draws) @@ -57,10 +78,86 @@ Anything else - gfx_draw (opcode is X start, next 2 bytes are Y and length) All the opcodes other than gfx_end are 3 bytes. Write macros for ca65 and a disassembler in perl. -There are 13 primary maps (one per level, plus the WELL DONE screen). Some -(all?) levels also have secondary map data, which I think is used for -changing parts of the map during the level (e.g. the disappearing girders -on level 1). +Hand disassembly of level00_map: + +level00_map: + gfx_shape sh_girder + gfx_delta $04,$00 ; draw left to right (or to the east), 4 pixel steps + gfx_draw $44,$05,$06 ; these are all horizontal platforms + gfx_draw $04,$15,$0A + gfx_draw $74,$15,$0A + gfx_draw $24,$22,$02 + gfx_draw $74,$22,$02 + gfx_draw $24,$25,$16 + gfx_draw $04,$45,$04 + gfx_draw $44,$45,$06 + gfx_draw $8C,$45,$04 + gfx_draw $04,$55,$08 + gfx_draw $34,$55,$0E + gfx_draw $7C,$55,$08 + gfx_delta $04,$FF ; diagonally up/right (northeast), 4px east, 1px north + gfx_draw $34,$09,$04 + gfx_draw $5C,$44,$0A + gfx_delta $04,$01 ; diagonally down/right (southeast), 4px east, 1px south + gfx_draw $5C,$06,$04 + gfx_draw $1C,$3B,$0A + gfx_shape sh_ladder ; we're done drawing girders + gfx_delta $00,$04 ; draw downwards (south), 4px steps + gfx_draw $0C,$41,$05 + gfx_draw $24,$01,$05 + gfx_draw $74,$01,$05 + gfx_draw $4C,$01,$15 + gfx_shape sh_up_rope + gfx_draw $06,$18,$0A ; notice no gfx_delta here, keep using previous delta! + gfx_draw $99,$18,$0A + gfx_shape sh_down_rope + gfx_draw $1D,$38,$06 ; again, no gfx_delta needed + gfx_draw $81,$38,$06 + gfx_shape sh_bomb +level00_map_bombs: ; always need a label at the start of the bombs + gfx_draw $04,$12,$01 ; no gfx_delta, wouldn't matter as length is 1 for these. + gfx_draw $38,$02,$01 + gfx_draw $64,$02,$01 + gfx_draw $98,$12,$01 + gfx_draw $44,$22,$01 + gfx_draw $58,$22,$01 + gfx_draw $04,$42,$01 + gfx_draw $98,$42,$01 + gfx_draw $04,$52,$01 + gfx_draw $38,$52,$01 + gfx_draw $64,$52,$01 + gfx_draw $98,$52,$01 + gfx_end ; that's all, folks! + +level00 also has 4 sets of map_change instructions, triggered when various +bombs are picked up: + +l00_map_change_0: + gfx_shape $9C49 ; sh_blank_4x4 + gfx_delta $04,$01 + gfx_draw $64,$08,$02 + gfx_end + +l00_map_change_1: + gfx_shape $9C49 ; sh_blank_4x4 + gfx_delta $04,$FF + gfx_draw $34,$09,$02 + gfx_end + +l00_map_change_2: + gfx_shape $9C49 ; sh_blank_4x4 + gfx_delta $04,$00 + gfx_draw $2C,$25,$05 + gfx_end + +l00_map_change_3: + gfx_shape $9C49 ; sh_blank_4x4 + gfx_delta $04,$00 + gfx_draw $60,$25,$05 + gfx_end + +As you can see, these just erase parts of platforms (even if you can't +tell from looking at the data, you can tell from playing the game). Shapes ------ diff --git a/leveldesc.info b/leveldesc.info index d74d21f..c764796 100644 --- a/leveldesc.info +++ b/leveldesc.info @@ -13,17 +13,21 @@ label { name "work_level_points_per_bomb"; addr $0790; size 1; comment "points a label { name "work_level_time_bonus"; addr $0791; size 2; comment "amount of time bonus at start of level"; }; label { name "work_level_offs_19"; addr $0793; size 1; comment "always $00"; }; label { name "work_level_unkn_table0"; addr $0794; size 2; comment "pointer to ROM table or $06xx"; }; -label { name "work_level_map0"; addr $0796; size 2; comment "map data"; }; -label { name "work_level_map1"; addr $0798; size 2; comment "map data"; }; -label { name "work_level_bomblist"; addr $079a; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +label { name "work_level_map"; addr $0796; size 2; comment "used to draw the level initially (see also map_changes)"; }; +label { name "work_level_map_bombs"; addr $0798; size 2; comment "start of bombs in map data (which must come last!)"; }; +label { name "work_level_bomblist"; addr $079a; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; label { name "work_level_map_changes"; addr $079c; size 2; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -label { name "work_level_offs_30"; addr $079e; size 2; comment "always $0000"; }; +label { name "work_level_indirect_subs"; addr $079e; size 2; comment "pointer to list of indirect subs, always $0000 in this game"; }; label { name "work_level_sub_bomb"; addr $07a0; size 2; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; label { name "work_level_sub_start"; addr $07a2; size 2; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; label { name "work_level_sub6"; addr $07a4; size 2; comment "always $9740 aka game_main_loop"; }; label { name "work_level_sub_eol"; addr $07a6; size 2; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; label { name "work_level_offs_40"; addr $07a8; size 6; comment "all zeroes"; }; -label { name "work_level_offs_46"; addr $07ae; size 9; comment "unknown"; }; +label { name "work_level_colpf3"; addr $07ae; size 1; comment "color (not sure what gets drawn in this color yet)"; }; +label { name "work_level_colpf0"; addr $07af; size 1; comment "color for girders and up-ropes"; }; +label { name "work_level_colpf1"; addr $07b0; size 1; comment "color for ladders and down-ropes"; }; +label { name "work_level_colpf2"; addr $07b1; size 1; comment "color for bombs"; }; +label { name "work_level_offs_50"; addr $07b2; size 5; comment "unknown"; }; label { name "work_level_offs_55"; addr $07b7; size 3; comment "unknown, always $00 $00 $00"; }; label { name "work_level_offs_58"; addr $07ba; size 2; comment "unknown, not a ROM address"; }; label { name "work_level_offs_60"; addr $07bc; size 4; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -43,17 +47,21 @@ label { name "cur_level_points_per_bomb"; addr $07d0; size 1; comment "points aw label { name "cur_level_time_bonus"; addr $07d1; size 2; comment "amount of time bonus at start of level"; }; label { name "cur_level_offs_19"; addr $07d3; size 1; comment "always $00"; }; label { name "cur_level_unkn_table0"; addr $07d4; size 2; comment "pointer to ROM table or $06xx"; }; -label { name "cur_level_map0"; addr $07d6; size 2; comment "map data"; }; -label { name "cur_level_map1"; addr $07d8; size 2; comment "map data"; }; -label { name "cur_level_bomblist"; addr $07da; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +label { name "cur_level_map"; addr $07d6; size 2; comment "used to draw the level initially (see also map_changes)"; }; +label { name "cur_level_map_bombs"; addr $07d8; size 2; comment "start of bombs in map data (which must come last!)"; }; +label { name "cur_level_bomblist"; addr $07da; size 2; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; label { name "cur_level_map_changes"; addr $07dc; size 2; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -label { name "cur_level_offs_30"; addr $07de; size 2; comment "always $0000"; }; +label { name "cur_level_indirect_subs"; addr $07de; size 2; comment "pointer to list of indirect subs, always $0000 in this game"; }; label { name "cur_level_sub_bomb"; addr $07e0; size 2; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; label { name "cur_level_sub_start"; addr $07e2; size 2; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; label { name "cur_level_sub6"; addr $07e4; size 2; comment "always $9740 aka game_main_loop"; }; label { name "cur_level_sub_eol"; addr $07e6; size 2; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; label { name "cur_level_offs_40"; addr $07e8; size 6; comment "all zeroes"; }; -label { name "cur_level_offs_46"; addr $07ee; size 9; comment "unknown"; }; +label { name "cur_level_colpf3"; addr $07ee; size 1; comment "color (not sure what gets drawn in this color yet)"; }; +label { name "cur_level_colpf0"; addr $07ef; size 1; comment "color for girders and up-ropes"; }; +label { name "cur_level_colpf1"; addr $07f0; size 1; comment "color for ladders and down-ropes"; }; +label { name "cur_level_colpf2"; addr $07f1; size 1; comment "color for bombs"; }; +label { name "cur_level_offs_50"; addr $07f2; size 5; comment "unknown"; }; label { name "cur_level_offs_55"; addr $07f7; size 3; comment "unknown, always $00 $00 $00"; }; label { name "cur_level_offs_58"; addr $07fa; size 2; comment "unknown, not a ROM address"; }; label { name "cur_level_offs_60"; addr $07fc; size 4; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -73,17 +81,21 @@ range { name "level00_points_per_bomb"; start $a010; end $a010; type bytetable; range { name "level00_time_bonus"; start $a011; end $a012; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level00_offs_19"; start $a013; end $a013; type bytetable; comment "always $00"; }; range { name "level00_unkn_table0"; start $a014; end $a015; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level00_map0"; start $a016; end $a017; type addrtable; comment "map data"; }; -range { name "level00_map1"; start $a018; end $a019; type addrtable; comment "map data"; }; -range { name "level00_bomblist"; start $a01a; end $a01b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level00_map"; start $a016; end $a017; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level00_map_bombs"; start $a018; end $a019; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level00_bomblist"; start $a01a; end $a01b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level00_map_changes"; start $a01c; end $a01d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level00_offs_30"; start $a01e; end $a01f; type bytetable; comment "always $0000"; }; +range { name "level00_indirect_subs"; start $a01e; end $a01f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level00_sub_bomb"; start $a020; end $a021; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level00_sub_start"; start $a022; end $a023; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level00_sub6"; start $a024; end $a025; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level00_sub_eol"; start $a026; end $a027; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level00_offs_40"; start $a028; end $a02d; type bytetable; comment "all zeroes"; }; -range { name "level00_offs_46"; start $a02e; end $a036; type bytetable; comment "unknown"; }; +range { name "level00_colpf3"; start $a02e; end $a02e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level00_colpf0"; start $a02f; end $a02f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level00_colpf1"; start $a030; end $a030; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level00_colpf2"; start $a031; end $a031; type bytetable; comment "color for bombs"; }; +range { name "level00_offs_50"; start $a032; end $a036; type bytetable; comment "unknown"; }; range { name "level00_offs_55"; start $a037; end $a039; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level00_offs_58"; start $a03a; end $a03b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level00_offs_60"; start $a03c; end $a03f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -103,17 +115,21 @@ range { name "level01_points_per_bomb"; start $a050; end $a050; type bytetable; range { name "level01_time_bonus"; start $a051; end $a052; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level01_offs_19"; start $a053; end $a053; type bytetable; comment "always $00"; }; range { name "level01_unkn_table0"; start $a054; end $a055; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level01_map0"; start $a056; end $a057; type addrtable; comment "map data"; }; -range { name "level01_map1"; start $a058; end $a059; type addrtable; comment "map data"; }; -range { name "level01_bomblist"; start $a05a; end $a05b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level01_map"; start $a056; end $a057; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level01_map_bombs"; start $a058; end $a059; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level01_bomblist"; start $a05a; end $a05b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level01_map_changes"; start $a05c; end $a05d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level01_offs_30"; start $a05e; end $a05f; type bytetable; comment "always $0000"; }; +range { name "level01_indirect_subs"; start $a05e; end $a05f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level01_sub_bomb"; start $a060; end $a061; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level01_sub_start"; start $a062; end $a063; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level01_sub6"; start $a064; end $a065; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level01_sub_eol"; start $a066; end $a067; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level01_offs_40"; start $a068; end $a06d; type bytetable; comment "all zeroes"; }; -range { name "level01_offs_46"; start $a06e; end $a076; type bytetable; comment "unknown"; }; +range { name "level01_colpf3"; start $a06e; end $a06e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level01_colpf0"; start $a06f; end $a06f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level01_colpf1"; start $a070; end $a070; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level01_colpf2"; start $a071; end $a071; type bytetable; comment "color for bombs"; }; +range { name "level01_offs_50"; start $a072; end $a076; type bytetable; comment "unknown"; }; range { name "level01_offs_55"; start $a077; end $a079; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level01_offs_58"; start $a07a; end $a07b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level01_offs_60"; start $a07c; end $a07f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -133,17 +149,21 @@ range { name "level02_points_per_bomb"; start $a090; end $a090; type bytetable; range { name "level02_time_bonus"; start $a091; end $a092; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level02_offs_19"; start $a093; end $a093; type bytetable; comment "always $00"; }; range { name "level02_unkn_table0"; start $a094; end $a095; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level02_map0"; start $a096; end $a097; type addrtable; comment "map data"; }; -range { name "level02_map1"; start $a098; end $a099; type addrtable; comment "map data"; }; -range { name "level02_bomblist"; start $a09a; end $a09b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level02_map"; start $a096; end $a097; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level02_map_bombs"; start $a098; end $a099; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level02_bomblist"; start $a09a; end $a09b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level02_map_changes"; start $a09c; end $a09d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level02_offs_30"; start $a09e; end $a09f; type bytetable; comment "always $0000"; }; +range { name "level02_indirect_subs"; start $a09e; end $a09f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level02_sub_bomb"; start $a0a0; end $a0a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level02_sub_start"; start $a0a2; end $a0a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level02_sub6"; start $a0a4; end $a0a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level02_sub_eol"; start $a0a6; end $a0a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level02_offs_40"; start $a0a8; end $a0ad; type bytetable; comment "all zeroes"; }; -range { name "level02_offs_46"; start $a0ae; end $a0b6; type bytetable; comment "unknown"; }; +range { name "level02_colpf3"; start $a0ae; end $a0ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level02_colpf0"; start $a0af; end $a0af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level02_colpf1"; start $a0b0; end $a0b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level02_colpf2"; start $a0b1; end $a0b1; type bytetable; comment "color for bombs"; }; +range { name "level02_offs_50"; start $a0b2; end $a0b6; type bytetable; comment "unknown"; }; range { name "level02_offs_55"; start $a0b7; end $a0b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level02_offs_58"; start $a0ba; end $a0bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level02_offs_60"; start $a0bc; end $a0bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -163,17 +183,21 @@ range { name "level03_points_per_bomb"; start $a0d0; end $a0d0; type bytetable; range { name "level03_time_bonus"; start $a0d1; end $a0d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level03_offs_19"; start $a0d3; end $a0d3; type bytetable; comment "always $00"; }; range { name "level03_unkn_table0"; start $a0d4; end $a0d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level03_map0"; start $a0d6; end $a0d7; type addrtable; comment "map data"; }; -range { name "level03_map1"; start $a0d8; end $a0d9; type addrtable; comment "map data"; }; -range { name "level03_bomblist"; start $a0da; end $a0db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level03_map"; start $a0d6; end $a0d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level03_map_bombs"; start $a0d8; end $a0d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level03_bomblist"; start $a0da; end $a0db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level03_map_changes"; start $a0dc; end $a0dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level03_offs_30"; start $a0de; end $a0df; type bytetable; comment "always $0000"; }; +range { name "level03_indirect_subs"; start $a0de; end $a0df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level03_sub_bomb"; start $a0e0; end $a0e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level03_sub_start"; start $a0e2; end $a0e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level03_sub6"; start $a0e4; end $a0e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level03_sub_eol"; start $a0e6; end $a0e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level03_offs_40"; start $a0e8; end $a0ed; type bytetable; comment "all zeroes"; }; -range { name "level03_offs_46"; start $a0ee; end $a0f6; type bytetable; comment "unknown"; }; +range { name "level03_colpf3"; start $a0ee; end $a0ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level03_colpf0"; start $a0ef; end $a0ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level03_colpf1"; start $a0f0; end $a0f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level03_colpf2"; start $a0f1; end $a0f1; type bytetable; comment "color for bombs"; }; +range { name "level03_offs_50"; start $a0f2; end $a0f6; type bytetable; comment "unknown"; }; range { name "level03_offs_55"; start $a0f7; end $a0f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level03_offs_58"; start $a0fa; end $a0fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level03_offs_60"; start $a0fc; end $a0ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -193,17 +217,21 @@ range { name "level04_points_per_bomb"; start $a110; end $a110; type bytetable; range { name "level04_time_bonus"; start $a111; end $a112; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level04_offs_19"; start $a113; end $a113; type bytetable; comment "always $00"; }; range { name "level04_unkn_table0"; start $a114; end $a115; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level04_map0"; start $a116; end $a117; type addrtable; comment "map data"; }; -range { name "level04_map1"; start $a118; end $a119; type addrtable; comment "map data"; }; -range { name "level04_bomblist"; start $a11a; end $a11b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level04_map"; start $a116; end $a117; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level04_map_bombs"; start $a118; end $a119; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level04_bomblist"; start $a11a; end $a11b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level04_map_changes"; start $a11c; end $a11d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level04_offs_30"; start $a11e; end $a11f; type bytetable; comment "always $0000"; }; +range { name "level04_indirect_subs"; start $a11e; end $a11f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level04_sub_bomb"; start $a120; end $a121; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level04_sub_start"; start $a122; end $a123; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level04_sub6"; start $a124; end $a125; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level04_sub_eol"; start $a126; end $a127; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level04_offs_40"; start $a128; end $a12d; type bytetable; comment "all zeroes"; }; -range { name "level04_offs_46"; start $a12e; end $a136; type bytetable; comment "unknown"; }; +range { name "level04_colpf3"; start $a12e; end $a12e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level04_colpf0"; start $a12f; end $a12f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level04_colpf1"; start $a130; end $a130; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level04_colpf2"; start $a131; end $a131; type bytetable; comment "color for bombs"; }; +range { name "level04_offs_50"; start $a132; end $a136; type bytetable; comment "unknown"; }; range { name "level04_offs_55"; start $a137; end $a139; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level04_offs_58"; start $a13a; end $a13b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level04_offs_60"; start $a13c; end $a13f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -223,17 +251,21 @@ range { name "level05_points_per_bomb"; start $a150; end $a150; type bytetable; range { name "level05_time_bonus"; start $a151; end $a152; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level05_offs_19"; start $a153; end $a153; type bytetable; comment "always $00"; }; range { name "level05_unkn_table0"; start $a154; end $a155; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level05_map0"; start $a156; end $a157; type addrtable; comment "map data"; }; -range { name "level05_map1"; start $a158; end $a159; type addrtable; comment "map data"; }; -range { name "level05_bomblist"; start $a15a; end $a15b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level05_map"; start $a156; end $a157; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level05_map_bombs"; start $a158; end $a159; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level05_bomblist"; start $a15a; end $a15b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level05_map_changes"; start $a15c; end $a15d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level05_offs_30"; start $a15e; end $a15f; type bytetable; comment "always $0000"; }; +range { name "level05_indirect_subs"; start $a15e; end $a15f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level05_sub_bomb"; start $a160; end $a161; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level05_sub_start"; start $a162; end $a163; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level05_sub6"; start $a164; end $a165; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level05_sub_eol"; start $a166; end $a167; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level05_offs_40"; start $a168; end $a16d; type bytetable; comment "all zeroes"; }; -range { name "level05_offs_46"; start $a16e; end $a176; type bytetable; comment "unknown"; }; +range { name "level05_colpf3"; start $a16e; end $a16e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level05_colpf0"; start $a16f; end $a16f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level05_colpf1"; start $a170; end $a170; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level05_colpf2"; start $a171; end $a171; type bytetable; comment "color for bombs"; }; +range { name "level05_offs_50"; start $a172; end $a176; type bytetable; comment "unknown"; }; range { name "level05_offs_55"; start $a177; end $a179; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level05_offs_58"; start $a17a; end $a17b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level05_offs_60"; start $a17c; end $a17f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -253,17 +285,21 @@ range { name "level06_points_per_bomb"; start $a190; end $a190; type bytetable; range { name "level06_time_bonus"; start $a191; end $a192; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level06_offs_19"; start $a193; end $a193; type bytetable; comment "always $00"; }; range { name "level06_unkn_table0"; start $a194; end $a195; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level06_map0"; start $a196; end $a197; type addrtable; comment "map data"; }; -range { name "level06_map1"; start $a198; end $a199; type addrtable; comment "map data"; }; -range { name "level06_bomblist"; start $a19a; end $a19b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level06_map"; start $a196; end $a197; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level06_map_bombs"; start $a198; end $a199; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level06_bomblist"; start $a19a; end $a19b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level06_map_changes"; start $a19c; end $a19d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level06_offs_30"; start $a19e; end $a19f; type bytetable; comment "always $0000"; }; +range { name "level06_indirect_subs"; start $a19e; end $a19f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level06_sub_bomb"; start $a1a0; end $a1a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level06_sub_start"; start $a1a2; end $a1a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level06_sub6"; start $a1a4; end $a1a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level06_sub_eol"; start $a1a6; end $a1a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level06_offs_40"; start $a1a8; end $a1ad; type bytetable; comment "all zeroes"; }; -range { name "level06_offs_46"; start $a1ae; end $a1b6; type bytetable; comment "unknown"; }; +range { name "level06_colpf3"; start $a1ae; end $a1ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level06_colpf0"; start $a1af; end $a1af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level06_colpf1"; start $a1b0; end $a1b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level06_colpf2"; start $a1b1; end $a1b1; type bytetable; comment "color for bombs"; }; +range { name "level06_offs_50"; start $a1b2; end $a1b6; type bytetable; comment "unknown"; }; range { name "level06_offs_55"; start $a1b7; end $a1b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level06_offs_58"; start $a1ba; end $a1bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level06_offs_60"; start $a1bc; end $a1bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -283,17 +319,21 @@ range { name "level07_points_per_bomb"; start $a1d0; end $a1d0; type bytetable; range { name "level07_time_bonus"; start $a1d1; end $a1d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level07_offs_19"; start $a1d3; end $a1d3; type bytetable; comment "always $00"; }; range { name "level07_unkn_table0"; start $a1d4; end $a1d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level07_map0"; start $a1d6; end $a1d7; type addrtable; comment "map data"; }; -range { name "level07_map1"; start $a1d8; end $a1d9; type addrtable; comment "map data"; }; -range { name "level07_bomblist"; start $a1da; end $a1db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level07_map"; start $a1d6; end $a1d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level07_map_bombs"; start $a1d8; end $a1d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level07_bomblist"; start $a1da; end $a1db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level07_map_changes"; start $a1dc; end $a1dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level07_offs_30"; start $a1de; end $a1df; type bytetable; comment "always $0000"; }; +range { name "level07_indirect_subs"; start $a1de; end $a1df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level07_sub_bomb"; start $a1e0; end $a1e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level07_sub_start"; start $a1e2; end $a1e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level07_sub6"; start $a1e4; end $a1e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level07_sub_eol"; start $a1e6; end $a1e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level07_offs_40"; start $a1e8; end $a1ed; type bytetable; comment "all zeroes"; }; -range { name "level07_offs_46"; start $a1ee; end $a1f6; type bytetable; comment "unknown"; }; +range { name "level07_colpf3"; start $a1ee; end $a1ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level07_colpf0"; start $a1ef; end $a1ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level07_colpf1"; start $a1f0; end $a1f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level07_colpf2"; start $a1f1; end $a1f1; type bytetable; comment "color for bombs"; }; +range { name "level07_offs_50"; start $a1f2; end $a1f6; type bytetable; comment "unknown"; }; range { name "level07_offs_55"; start $a1f7; end $a1f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level07_offs_58"; start $a1fa; end $a1fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level07_offs_60"; start $a1fc; end $a1ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -313,17 +353,21 @@ range { name "level08_points_per_bomb"; start $a210; end $a210; type bytetable; range { name "level08_time_bonus"; start $a211; end $a212; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level08_offs_19"; start $a213; end $a213; type bytetable; comment "always $00"; }; range { name "level08_unkn_table0"; start $a214; end $a215; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level08_map0"; start $a216; end $a217; type addrtable; comment "map data"; }; -range { name "level08_map1"; start $a218; end $a219; type addrtable; comment "map data"; }; -range { name "level08_bomblist"; start $a21a; end $a21b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level08_map"; start $a216; end $a217; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level08_map_bombs"; start $a218; end $a219; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level08_bomblist"; start $a21a; end $a21b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level08_map_changes"; start $a21c; end $a21d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level08_offs_30"; start $a21e; end $a21f; type bytetable; comment "always $0000"; }; +range { name "level08_indirect_subs"; start $a21e; end $a21f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level08_sub_bomb"; start $a220; end $a221; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level08_sub_start"; start $a222; end $a223; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level08_sub6"; start $a224; end $a225; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level08_sub_eol"; start $a226; end $a227; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level08_offs_40"; start $a228; end $a22d; type bytetable; comment "all zeroes"; }; -range { name "level08_offs_46"; start $a22e; end $a236; type bytetable; comment "unknown"; }; +range { name "level08_colpf3"; start $a22e; end $a22e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level08_colpf0"; start $a22f; end $a22f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level08_colpf1"; start $a230; end $a230; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level08_colpf2"; start $a231; end $a231; type bytetable; comment "color for bombs"; }; +range { name "level08_offs_50"; start $a232; end $a236; type bytetable; comment "unknown"; }; range { name "level08_offs_55"; start $a237; end $a239; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level08_offs_58"; start $a23a; end $a23b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level08_offs_60"; start $a23c; end $a23f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -343,17 +387,21 @@ range { name "level09_points_per_bomb"; start $a250; end $a250; type bytetable; range { name "level09_time_bonus"; start $a251; end $a252; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level09_offs_19"; start $a253; end $a253; type bytetable; comment "always $00"; }; range { name "level09_unkn_table0"; start $a254; end $a255; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level09_map0"; start $a256; end $a257; type addrtable; comment "map data"; }; -range { name "level09_map1"; start $a258; end $a259; type addrtable; comment "map data"; }; -range { name "level09_bomblist"; start $a25a; end $a25b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level09_map"; start $a256; end $a257; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level09_map_bombs"; start $a258; end $a259; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level09_bomblist"; start $a25a; end $a25b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level09_map_changes"; start $a25c; end $a25d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level09_offs_30"; start $a25e; end $a25f; type bytetable; comment "always $0000"; }; +range { name "level09_indirect_subs"; start $a25e; end $a25f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level09_sub_bomb"; start $a260; end $a261; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level09_sub_start"; start $a262; end $a263; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level09_sub6"; start $a264; end $a265; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level09_sub_eol"; start $a266; end $a267; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level09_offs_40"; start $a268; end $a26d; type bytetable; comment "all zeroes"; }; -range { name "level09_offs_46"; start $a26e; end $a276; type bytetable; comment "unknown"; }; +range { name "level09_colpf3"; start $a26e; end $a26e; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level09_colpf0"; start $a26f; end $a26f; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level09_colpf1"; start $a270; end $a270; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level09_colpf2"; start $a271; end $a271; type bytetable; comment "color for bombs"; }; +range { name "level09_offs_50"; start $a272; end $a276; type bytetable; comment "unknown"; }; range { name "level09_offs_55"; start $a277; end $a279; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level09_offs_58"; start $a27a; end $a27b; type bytetable; comment "unknown, not a ROM address"; }; range { name "level09_offs_60"; start $a27c; end $a27f; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -373,17 +421,21 @@ range { name "level10_points_per_bomb"; start $a290; end $a290; type bytetable; range { name "level10_time_bonus"; start $a291; end $a292; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level10_offs_19"; start $a293; end $a293; type bytetable; comment "always $00"; }; range { name "level10_unkn_table0"; start $a294; end $a295; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level10_map0"; start $a296; end $a297; type addrtable; comment "map data"; }; -range { name "level10_map1"; start $a298; end $a299; type addrtable; comment "map data"; }; -range { name "level10_bomblist"; start $a29a; end $a29b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level10_map"; start $a296; end $a297; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level10_map_bombs"; start $a298; end $a299; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level10_bomblist"; start $a29a; end $a29b; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level10_map_changes"; start $a29c; end $a29d; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level10_offs_30"; start $a29e; end $a29f; type bytetable; comment "always $0000"; }; +range { name "level10_indirect_subs"; start $a29e; end $a29f; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level10_sub_bomb"; start $a2a0; end $a2a1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level10_sub_start"; start $a2a2; end $a2a3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level10_sub6"; start $a2a4; end $a2a5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level10_sub_eol"; start $a2a6; end $a2a7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level10_offs_40"; start $a2a8; end $a2ad; type bytetable; comment "all zeroes"; }; -range { name "level10_offs_46"; start $a2ae; end $a2b6; type bytetable; comment "unknown"; }; +range { name "level10_colpf3"; start $a2ae; end $a2ae; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level10_colpf0"; start $a2af; end $a2af; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level10_colpf1"; start $a2b0; end $a2b0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level10_colpf2"; start $a2b1; end $a2b1; type bytetable; comment "color for bombs"; }; +range { name "level10_offs_50"; start $a2b2; end $a2b6; type bytetable; comment "unknown"; }; range { name "level10_offs_55"; start $a2b7; end $a2b9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level10_offs_58"; start $a2ba; end $a2bb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level10_offs_60"; start $a2bc; end $a2bf; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -403,17 +455,21 @@ range { name "level11_points_per_bomb"; start $a2d0; end $a2d0; type bytetable; range { name "level11_time_bonus"; start $a2d1; end $a2d2; type wordtable; comment "amount of time bonus at start of level"; }; range { name "level11_offs_19"; start $a2d3; end $a2d3; type bytetable; comment "always $00"; }; range { name "level11_unkn_table0"; start $a2d4; end $a2d5; type addrtable; comment "pointer to ROM table or $06xx"; }; -range { name "level11_map0"; start $a2d6; end $a2d7; type addrtable; comment "map data"; }; -range { name "level11_map1"; start $a2d8; end $a2d9; type addrtable; comment "map data"; }; -range { name "level11_bomblist"; start $a2da; end $a2db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF."; }; +range { name "level11_map"; start $a2d6; end $a2d7; type addrtable; comment "used to draw the level initially (see also map_changes)"; }; +range { name "level11_map_bombs"; start $a2d8; end $a2d9; type addrtable; comment "start of bombs in map data (which must come last!)"; }; +range { name "level11_bomblist"; start $a2da; end $a2db; type addrtable; comment "addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF."; }; range { name "level11_map_changes"; start $a2dc; end $a2dd; type addrtable; comment "address of list of addresses of map data, used for changing the map when certain bombs are picked up"; }; -range { name "level11_offs_30"; start $a2de; end $a2df; type bytetable; comment "always $0000"; }; +range { name "level11_indirect_subs"; start $a2de; end $a2df; type bytetable; comment "pointer to list of indirect subs, always $0000 in this game"; }; range { name "level11_sub_bomb"; start $a2e0; end $a2e1; type addrtable; comment "called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine"; }; range { name "level11_sub_start"; start $a2e2; end $a2e3; type addrtable; comment "called at start of level, $06E6 for some levels, or else a ROM subroutine"; }; range { name "level11_sub6"; start $a2e4; end $a2e5; type addrtable; comment "always $9740 aka game_main_loop"; }; range { name "level11_sub_eol"; start $a2e6; end $a2e7; type addrtable; comment "called at end of level (all bombs picked up). $06E6 for all but level07"; }; range { name "level11_offs_40"; start $a2e8; end $a2ed; type bytetable; comment "all zeroes"; }; -range { name "level11_offs_46"; start $a2ee; end $a2f6; type bytetable; comment "unknown"; }; +range { name "level11_colpf3"; start $a2ee; end $a2ee; type bytetable; comment "color (not sure what gets drawn in this color yet)"; }; +range { name "level11_colpf0"; start $a2ef; end $a2ef; type bytetable; comment "color for girders and up-ropes"; }; +range { name "level11_colpf1"; start $a2f0; end $a2f0; type bytetable; comment "color for ladders and down-ropes"; }; +range { name "level11_colpf2"; start $a2f1; end $a2f1; type bytetable; comment "color for bombs"; }; +range { name "level11_offs_50"; start $a2f2; end $a2f6; type bytetable; comment "unknown"; }; range { name "level11_offs_55"; start $a2f7; end $a2f9; type bytetable; comment "unknown, always $00 $00 $00"; }; range { name "level11_offs_58"; start $a2fa; end $a2fb; type bytetable; comment "unknown, not a ROM address"; }; range { name "level11_offs_60"; start $a2fc; end $a2ff; type bytetable; comment "unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00"; }; @@ -115,8 +115,10 @@ label { name "init_next_level"; addr $9BE8; size 1; comment "..."; }; label { name "show_get_ready_prompt"; addr $9624; size 1; comment "only in multiplayer games"; }; label { name "check_bomb_coll"; addr $87A0; size 1; comment "check whether Jumpman just touched a bomb (RTS if not)"; }; label { name "check_bomb_coll_jv"; addr $8033; size 1; comment "check whether Jumpman just touched a bomb (RTS if not)"; }; -label { name "bomb_pickup"; addr $87A8; size 1; comment "Jumpman just picked up a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, do some other stuff I don't understand yet"; }; +label { name "bomb_pickup"; addr $87A8; size 1; comment "Jumpman just touched a bomb, award points, play sfx_bomb_pickup, make the bomb disappear, etc."; }; +label { name "coarse_grid"; addr $87C4; size 1; comment "screen X range approx $32 to $C6, Y $18 to $C0, meaning the coarse grid visible screen range is X 1-6, Y 0-6"; }; label { name "erase_bomb"; addr $8879; size 1; comment "make the bomb disappear by drawing sh_blank in its location"; }; +label { name "wait_bomb"; addr $888A; size 1; comment "wait for bomb to really disappear"; }; label { name "bomb_add_points"; addr $8865; size 1; comment "add points to score for picking up bomb (theoretically different on every level, but really $64 aka 100 for all of them)"; }; label { name "call_bomb_sub"; addr $8856; size 1; comment "call bomb pickup subroutine for this level (which might just do an RTS if there's no special action)"; }; label { name "call_bomb_indirect_sub"; addr $883E; size 1; comment "this would call a subroutine via pointer-to-pointer, but I'm almost 100% certain it's never used (maybe a holdover from original Jumpman?)"; }; @@ -125,8 +127,8 @@ label { name "bl_ok"; addr $87D7; size 1; }; label { name "bomb_found"; addr $87E0; size 1; }; label { name "bombloc"; addr $B6; size 1; comment "bomb_pickup: position of the bomb Jumpman just touched, on 8x8 coarse grid"; }; label { name "mul_y"; addr $87EA; size 1; comment "multiply Y by 1.5 (only works because Y will always be even at this point)"; }; -label { name "unkn1"; addr $87F2; size 1; comment "find out: why are we storing this at 06DC?"; }; -label { name "change_map"; addr $881B; size 1; comment "this has to do with redrawing parts of the level (e.g. disappearing platforms on level00)"; }; +label { name "store_bomb_coords"; addr $87F2; size 1; comment "store actual bomb coordinates (not the coarse ones) for bomb subs to use"; }; +label { name "change_map"; addr $881B; size 1; comment "some bombs redraw parts of the level (e.g. disappearing platforms on level00)"; }; label { name "check_ind_sub"; addr $8831; size 1; comment "see if this bomb calls an indirect sub (none of them do in this game, this is useless code)"; }; label { name "blistptr"; addr $B4; size 2; comment "bomb_pickup: points to current level's bomblist"; }; range { name "gr7_or_masks"; start $8143; end $8152; type bytetable; }; @@ -300,7 +302,21 @@ label { name "electrocution_done"; addr $A4DD; comment "turn off electrocution e label { name "electrocute"; addr $A509; comment "electrocution effect"; }; label { name "level02_collisions"; addr $A53D; comment "skip a couple of the collision regs, so we don't register a collision when Jumpman is being electrocuted"; }; label { name "start_jump"; addr $99A0; comment "start jumping, play sfx_jump"; }; -range { name "level00_map"; start $A300; end $a497; type bytetable; comment "level map data starts here"; }; + +range { name "l00_map"; start $A300; end $a365; type bytetable; comment "level map data starts here"; }; + +range { name "l00_map_bombs"; start $A366; end $A38A; type bytetable; comment "gfx_draw instructions for bombs, used by bomb_pickup to get bomb coords. $ff terminated"; }; +range { name "l00_bombs"; start $A38B; end $a3a2; type bytetable; comment "2 bytes per entry, terminated by $FF. 1st byte is coarse grid coords (top nybble = X, bottom = Y), 2nd byte is index into map_changes"; }; +range { name "l00_bombs_term"; start $a3a3; end $a3a3; type bytetable; comment "terminator for l00_bombs"; }; +range { name "l00_map_changes"; start $A3A4; end $a3ad; type addrtable; comment "0000 = no change"; }; +range { name "l00_map_change_0"; start $A3AE; end $a3d5; type bytetable; }; +label { name "l00_map_change_1"; addr $a3b8; }; +label { name "l00_map_change_2"; addr $a3c2; }; +label { name "l00_map_change_3"; addr $a3cc; }; +range { name "zero_filler_a3d6"; start $a3d6; end $a3df; type bytetable; comment "probably just filler"; }; + +range { name "l01_map"; start $A3e0; end $a497; type bytetable; comment "level map data starts here"; }; + range { name "sfx_electrocution"; start $A52D; end $A53C; type bytetable; }; range { name "data_a542"; start $A542; end $A68B; type bytetable; comment "dunno, referenced by electrocution_bomb_pickup"; }; range { name "dumbwaiter_player"; start $a782; end $A826; type bytetable; comment "the dumbwaiters from level02. stored upside-down."; }; @@ -524,7 +540,9 @@ label { name "HPOSP0_minus_two"; addr $CFFE; size 1; }; label { name "position_pm_vert"; addr $8322; size 1; }; label { name "clear_pm"; addr $8342; size 1; comment "write zeroes to unused portion of this player/missile"; }; label { name "position_done"; addr $82E8; size 1; }; -label { name "clear_pm_mem"; addr $872A; size 1; comment "clear P/M mem"; }; +label { name "clear_pm_mem"; addr $88A8; size 1; comment "clear P/M memory, called from enable_joystick"; }; +label { name "clr_loop"; addr $88AB; size 1; }; +label { name "prepare_level"; addr $872A; size 1; comment "misc stuff, called from enable_joystick"; }; label { name "clear_screen_mem"; addr $8714; size 1; comment "clear the gameboard screen memory (called before drawing a level, natch)"; }; label { name "clear_screen_mem_jv"; addr $801E; size 1; comment "clear the gameboard screen memory (called before drawing a level, natch)"; }; label { name "csm_loop"; addr $871F; size 1; }; diff --git a/mklevelinfo.pl b/mklevelinfo.pl index 2e481e1..a95bc10 100644 --- a/mklevelinfo.pl +++ b/mklevelinfo.pl @@ -16,17 +16,21 @@ 17 => [ 2, 'time_bonus', 'amount of time bonus at start of level' ], 19 => [ 1, 'offs', 'always $00' ], 20 => [ 2, 'unkn_table0', 'pointer to ROM table or $06xx' ], - 22 => [ 2, 'map0', 'map data' ], - 24 => [ 2, 'map1', 'map data' ], - 26 => [ 2, 'bomblist', 'addr of list of bombs, indexed by player position on coarse 8x8 grid. terminated by $FF.' ], + 22 => [ 2, 'map', 'used to draw the level initially (see also map_changes)' ], + 24 => [ 2, 'map_bombs', 'start of bombs in map data (which must come last!)' ], + 26 => [ 2, 'bomblist', 'addr of list of bombs, indexed by player position on coarse 8x8 grid. 2 bytes each, 1st is coarse-grid position, 2nd is: hi 4 bits = change_map index, lo 4 = indirect sub (unused). terminated by $FF.' ], 28 => [ 2, 'map_changes', 'address of list of addresses of map data, used for changing the map when certain bombs are picked up' ], - 30 => [ 2, 'offs', 'always $0000' ], + 30 => [ 2, 'indirect_subs', 'pointer to list of indirect subs, always $0000 in this game' ], 32 => [ 2, 'sub_bomb', 'called when a bomb is picked up. $06E6 for most levels (just an RTS), or else a ROM subroutine' ], 34 => [ 2, 'sub_start', 'called at start of level, $06E6 for some levels, or else a ROM subroutine' ], 36 => [ 2, 'sub6', 'always $9740 aka game_main_loop' ], 38 => [ 2, 'sub_eol', 'called at end of level (all bombs picked up). $06E6 for all but level07' ], 40 => [ 6, 'offs', 'all zeroes' ], - 46 => [ 9, 'offs', 'unknown' ], + 46 => [ 1, 'colpf3', 'color (not sure what gets drawn in this color yet)' ], + 47 => [ 1, 'colpf0', 'color for girders and up-ropes' ], + 48 => [ 1, 'colpf1', 'color for ladders and down-ropes' ], + 49 => [ 1, 'colpf2', 'color for bombs' ], + 50 => [ 5, 'offs', 'unknown' ], 55 => [ 3, 'offs', 'unknown, always $00 $00 $00' ], 58 => [ 2, 'offs', 'unknown, not a ROM address' ], 60 => [ 4, 'offs', 'unknown, level05 (walls) has $ff $ff $ff $ff, all others $00 $00 $00 $00' ], |