diff --git a/games/ootw/ootw_c14/graphics/l14_arena/Makefile b/games/ootw/ootw_c14/graphics/l14_arena/Makefile index 1dd3cc74..cad236ec 100644 --- a/games/ootw/ootw_c14/graphics/l14_arena/Makefile +++ b/games/ootw/ootw_c14/graphics/l14_arena/Makefile @@ -8,7 +8,9 @@ all: ootw_c14_arena.inc ##### ootw_c14_arena.inc: \ + blank.lzsa \ arena_main_bg.lzsa \ + arena_panel_bg.lzsa \ inside_bg.lzsa \ inside03.lzsa inside04.lzsa inside05.lzsa inside06.lzsa \ inside07.lzsa inside08.lzsa inside09.lzsa inside10.lzsa \ @@ -44,8 +46,13 @@ ootw_c14_arena.inc: \ arena_next13.lzsa arena_next14.lzsa arena_next15.lzsa arena_next16.lzsa \ arena_next17.lzsa arena_next18.lzsa arena_next19.lzsa arena_next20.lzsa \ arena_next21.lzsa arena_next22.lzsa arena_next23.lzsa arena_next24.lzsa \ - arena_next25.lzsa arena_next26.lzsa arena_next27.lzsa + arena_next25.lzsa arena_next26.lzsa arena_next27.lzsa \ + eject01.lzsa eject02.lzsa eject03.lzsa eject04.lzsa eject05.lzsa \ + eject06.lzsa eject07.lzsa eject08.lzsa eject09.lzsa eject10.lzsa \ + sky_bg.lzsa \ + sky01.lzsa sky02.lzsa sky03.lzsa sky04.lzsa sky05.lzsa echo "arena_main_bg_lzsa: .incbin \"arena_main_bg.lzsa\"" > ootw_c14_arena.inc + echo "arena_panel_bg_lzsa: .incbin \"arena_panel_bg.lzsa\"" >> ootw_c14_arena.inc echo "inside_bg_lzsa: .incbin \"inside_bg.lzsa\"" >> ootw_c14_arena.inc echo "inside03_lzsa: .incbin \"inside03.lzsa\"" >> ootw_c14_arena.inc echo "inside04_lzsa: .incbin \"inside04.lzsa\"" >> ootw_c14_arena.inc @@ -136,6 +143,7 @@ ootw_c14_arena.inc: \ echo "entering11_lzsa: .incbin \"entering11.lzsa\"" >> ootw_c14_arena.inc echo "entering12_lzsa: .incbin \"entering12.lzsa\"" >> ootw_c14_arena.inc echo "entering13_lzsa: .incbin \"entering13.lzsa\"" >> ootw_c14_arena.inc + echo "blank_lzsa: .incbin \"blank.lzsa\"" >> ootw_c14_arena.inc echo "arena_next_bg_lzsa: .incbin \"arena_next_bg.lzsa\"" >> ootw_c14_arena.inc echo "arena_next01_lzsa: .incbin \"arena_next01.lzsa\"" >> ootw_c14_arena.inc echo "arena_next02_lzsa: .incbin \"arena_next02.lzsa\"" >> ootw_c14_arena.inc @@ -164,9 +172,22 @@ ootw_c14_arena.inc: \ echo "arena_next25_lzsa: .incbin \"arena_next25.lzsa\"" >> ootw_c14_arena.inc echo "arena_next26_lzsa: .incbin \"arena_next26.lzsa\"" >> ootw_c14_arena.inc echo "arena_next27_lzsa: .incbin \"arena_next27.lzsa\"" >> ootw_c14_arena.inc - - - + echo "eject01_lzsa: .incbin \"eject01.lzsa\"" >> ootw_c14_arena.inc + echo "eject02_lzsa: .incbin \"eject02.lzsa\"" >> ootw_c14_arena.inc + echo "eject03_lzsa: .incbin \"eject03.lzsa\"" >> ootw_c14_arena.inc + echo "eject04_lzsa: .incbin \"eject04.lzsa\"" >> ootw_c14_arena.inc + echo "eject05_lzsa: .incbin \"eject05.lzsa\"" >> ootw_c14_arena.inc + echo "eject06_lzsa: .incbin \"eject06.lzsa\"" >> ootw_c14_arena.inc + echo "eject07_lzsa: .incbin \"eject07.lzsa\"" >> ootw_c14_arena.inc + echo "eject08_lzsa: .incbin \"eject08.lzsa\"" >> ootw_c14_arena.inc + echo "eject09_lzsa: .incbin \"eject09.lzsa\"" >> ootw_c14_arena.inc + echo "eject10_lzsa: .incbin \"eject10.lzsa\"" >> ootw_c14_arena.inc + echo "sky_bg_lzsa: .incbin \"sky_bg.lzsa\"" >> ootw_c14_arena.inc + echo "sky01_lzsa: .incbin \"sky01.lzsa\"" >> ootw_c14_arena.inc + echo "sky02_lzsa: .incbin \"sky02.lzsa\"" >> ootw_c14_arena.inc + echo "sky03_lzsa: .incbin \"sky03.lzsa\"" >> ootw_c14_arena.inc + echo "sky04_lzsa: .incbin \"sky04.lzsa\"" >> ootw_c14_arena.inc + echo "sky05_lzsa: .incbin \"sky05.lzsa\"" >> ootw_c14_arena.inc ##### diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next01.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next01.png index f239e2da..132a43e0 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next01.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next01.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next02.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next02.png index fafc97c7..72635eb3 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next02.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next02.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next05.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next05.png index 40ca0a54..03c76f7f 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next05.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next05.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next06.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next06.png index 7b5afa33..e73cf1f2 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next06.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next06.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next07.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next07.png index 286bedfb..cb970b1c 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next07.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next07.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next08.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next08.png index 71e37b15..3ead4d17 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next08.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next08.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next09.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next09.png index 4167e163..2c899282 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next09.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next09.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next10.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next10.png index 66ab78f3..a44c75f1 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next10.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next10.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next11.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next11.png index a99149aa..6c66251e 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next11.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next11.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next12.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next12.png index 02642081..c4eb632f 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next12.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next12.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next13.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next13.png index 5b16fefa..9eb1a1d7 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next13.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next13.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next14.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next14.png index c1cf40ce..27a84db9 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next14.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next14.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next15.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next15.png index d6e3d84d..95bd956e 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next15.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next15.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next16.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next16.png index 3b01a5f6..9bb1e151 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next16.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next16.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next17.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next17.png index e1c1e1aa..52f2e437 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next17.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next17.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next18.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next18.png index f62b8b72..ca8f96f2 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next18.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next18.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next19.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next19.png index 92c93f9e..86ade5a8 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next19.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next19.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next20.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next20.png index a64ad945..8dcb1818 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next20.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next20.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next21.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next21.png index 30b228ee..07c329b5 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next21.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next21.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next22.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next22.png index 9941f7b9..a48181d3 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next22.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next22.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next23.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next23.png index 66bf64e1..e5baae53 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next23.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next23.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next24.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next24.png index d89f88b2..7e3c9186 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next24.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next24.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next25.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next25.png index 36b53e91..59fbf6d4 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next25.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next25.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next26.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next26.png index d4f3a603..a06911e3 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next26.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next26.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_next27.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_next27.png index 059a16f8..7c8af0b0 100644 Binary files a/games/ootw/ootw_c14/graphics/l14_arena/arena_next27.png and b/games/ootw/ootw_c14/graphics/l14_arena/arena_next27.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/arena_panel_bg.png b/games/ootw/ootw_c14/graphics/l14_arena/arena_panel_bg.png new file mode 100644 index 00000000..46c6cc78 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/arena_panel_bg.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/blank.png b/games/ootw/ootw_c14/graphics/l14_arena/blank.png new file mode 100644 index 00000000..58c2b9d8 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/blank.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject01.png b/games/ootw/ootw_c14/graphics/l14_arena/eject01.png new file mode 100644 index 00000000..2899703c Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject01.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject02.png b/games/ootw/ootw_c14/graphics/l14_arena/eject02.png new file mode 100644 index 00000000..cd3c1162 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject02.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject03.png b/games/ootw/ootw_c14/graphics/l14_arena/eject03.png new file mode 100644 index 00000000..0f4d8df4 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject03.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject04.png b/games/ootw/ootw_c14/graphics/l14_arena/eject04.png new file mode 100644 index 00000000..bbb41a2a Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject04.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject05.png b/games/ootw/ootw_c14/graphics/l14_arena/eject05.png new file mode 100644 index 00000000..ef28e33b Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject05.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject06.png b/games/ootw/ootw_c14/graphics/l14_arena/eject06.png new file mode 100644 index 00000000..7c2c4468 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject06.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject07.png b/games/ootw/ootw_c14/graphics/l14_arena/eject07.png new file mode 100644 index 00000000..fa8399f3 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject07.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject08.png b/games/ootw/ootw_c14/graphics/l14_arena/eject08.png new file mode 100644 index 00000000..84098d74 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject08.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject09.png b/games/ootw/ootw_c14/graphics/l14_arena/eject09.png new file mode 100644 index 00000000..2046058f Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject09.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/eject10.png b/games/ootw/ootw_c14/graphics/l14_arena/eject10.png new file mode 100644 index 00000000..5138a4c3 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/eject10.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky01.png b/games/ootw/ootw_c14/graphics/l14_arena/sky01.png new file mode 100644 index 00000000..1b18eef9 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky01.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky02.png b/games/ootw/ootw_c14/graphics/l14_arena/sky02.png new file mode 100644 index 00000000..ed505102 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky02.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky03.png b/games/ootw/ootw_c14/graphics/l14_arena/sky03.png new file mode 100644 index 00000000..f0830534 Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky03.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky04.png b/games/ootw/ootw_c14/graphics/l14_arena/sky04.png new file mode 100644 index 00000000..c33e57fb Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky04.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky05.png b/games/ootw/ootw_c14/graphics/l14_arena/sky05.png new file mode 100644 index 00000000..6d4d2eaa Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky05.png differ diff --git a/games/ootw/ootw_c14/graphics/l14_arena/sky_bg.png b/games/ootw/ootw_c14/graphics/l14_arena/sky_bg.png new file mode 100644 index 00000000..3068dd2a Binary files /dev/null and b/games/ootw/ootw_c14/graphics/l14_arena/sky_bg.png differ diff --git a/games/ootw/ootw_c14/ootw_c14.s b/games/ootw/ootw_c14/ootw_c14.s index bbd303ac..dfc7ba75 100644 --- a/games/ootw/ootw_c14/ootw_c14.s +++ b/games/ootw/ootw_c14/ootw_c14.s @@ -51,21 +51,23 @@ ootw_c14_restart: jsr ootw_c14_level_init ;=========================== - ; c14_new_room + ; c14 startup ;=========================== - ; enter new room on level 14 -c14_new_room: lda #0 sta GAME_OVER + sta BUTTON_PRESS + + lda #6 + sta HAND_X + lda #14 + sta HAND_Y ;==================================== - ; Initialize room based on WHICH_ROOM - ; and then play until we exit + ; play until we exit ;==================================== - jsr ootw_c14_setup_room_and_play - + jsr ootw_c14_play ;==================================== ; we exited the room @@ -77,12 +79,15 @@ c14_check_done: beq quit_level ;===================================================== - ; Check to see which room to enter next - ; If it's a special value, means we succesfully beat the level + ; we beat the level, run the eject sequence c14_defeated: - lda WHICH_ROOM - cmp #$ff - bne c14_new_room + + lda #eject_sequence + sta INTRO_LOOPH + + jsr run_sequence ; point to next level ; and exit to the level loader @@ -139,31 +144,27 @@ ootw_c14_level_init: ;=========================== ;=========================== - ; enter new room + ; play the arena ;=========================== ;=========================== -ootw_c14_setup_room_and_play: +ootw_c14_play: - ;=============================== - ; Room0 -- the arena - ;=============================== -room: + ;=================== ; load background - lda #>(arena_main_bg_lzsa) + ;=================== + + lda #>(arena_panel_bg_lzsa) sta getsrc_smc+2 ; LZSA_SRC_HI - lda #<(arena_main_bg_lzsa) - -room_setup_done: - + lda #<(arena_panel_bg_lzsa) sta getsrc_smc+1 ; LZSA_SRC_LO lda #$c ; load to page $c00 jsr decompress_lzsa2_fast ; tail call -ootw_room_already_set: ;=========================== ; Enable graphics + ;=========================== bit LORES bit SET_GR @@ -205,6 +206,34 @@ room_loop: jsr handle_keypress + + ;=============================== + ; draw hand + ;=============================== + + lda HAND_X + sta XPOS + lda HAND_Y + sta YPOS + + lda BUTTON_PRESS + beq regular_hand +button_hand: + lda #hand_press_sprite + dec BUTTON_PRESS + jmp hand_ready + +regular_hand: + lda #hand_sprite +hand_ready: + sta INH + jsr put_sprite_crop + + ;===================================== ; draw foreground action ;===================================== @@ -298,14 +327,14 @@ room_frame_no_oflo: ;========================== lda GAME_OVER - beq still_in_room + beq still_in_arena - cmp #$ff ; if $ff, we died - beq done_room +; cmp #$ff ; if $ff, we died + jmp done_room ; loop forever -still_in_room: +still_in_arena: lda #0 sta GAME_OVER @@ -323,7 +352,7 @@ end_message: .include "../decompress_fast_v2.s" .include "../gr_copy.s" ;.include "../gr_putsprite.s" -;.include "../gr_putsprite_crop.s" +.include "../gr_putsprite_crop.s" .include "../gr_offsets.s" ;.include "../gr_hlin.s" ;.include "../keyboard.s" @@ -360,7 +389,6 @@ end_message: ; D or -> : start moving right ; W or up : jump or elevator/transporter up ; S or down : crouch or pickup or elevator/transporter down -; L : charge gun ; space : action ; escape : quit @@ -408,11 +436,13 @@ check_left: ;==================== ;==================== left_pressed: -; inc GUN_FIRE ; fire gun if charging + lda HAND_X + beq no_hand_left - ; left==0 -; lda DIRECTION ; if facing right, turn to face left -; bne left_going_right + dec HAND_X + dec HAND_X + +no_hand_left: jmp done_keypress @@ -431,6 +461,15 @@ check_right: ;=================== ;=================== right_pressed: + lda HAND_X + cmp #12 + beq no_hand_right + + inc HAND_X + inc HAND_X + +no_hand_right: + jmp done_keypress @@ -451,7 +490,16 @@ check_up: ;========================== ;========================== up: + lda HAND_Y + cmp #6 + beq no_hand_up + dec HAND_Y + dec HAND_Y + dec HAND_Y + dec HAND_Y + +no_hand_up: jmp done_keypress @@ -468,6 +516,15 @@ check_down: ;========================== ;========================== down: + lda HAND_Y + cmp #14 + beq no_hand_up + + inc HAND_Y + inc HAND_Y + inc HAND_Y + inc HAND_Y + jmp done_keypress @@ -477,13 +534,29 @@ down: check_space: cmp #' ' beq space -; cmp #$15 ; ascii 21=?? - jmp unknown + cmp #$D ; enter + bne unknown ;====================== ; SPACE -- Keypress, also look for enter? ;====================== space: + lda #5 + sta BUTTON_PRESS + + lda HAND_X + cmp #4 + bne no_eject + + lda HAND_Y + cmp #10 + bne no_eject + + lda #$01 ; done, set so we exit + sta GAME_OVER + +no_eject: + jmp done_keypress unknown: done_keypress: @@ -600,7 +673,8 @@ tank_intro_sequence: .byte 128+2 ; .word entering10_lzsa ; (2) .byte 128+2 ; .word entering11_lzsa ; (2) .byte 128+2 ; .word entering12_lzsa ; (2) - .byte 128+32 ; .word entering13_lzsa ; (16) pause a bit + .byte 128+2 ; .word entering13_lzsa ; (2) + .byte 128+32 ; .word blank_lzsa ; (16) pause a bit .byte 255 ; load to bg .word arena_next_bg_lzsa ; this .byte 128+28 ; .word arena_next01_lzsa ; (14) @@ -630,5 +704,48 @@ tank_intro_sequence: .byte 128+14 ; .word arena_next25_lzsa ; (7) .byte 128+14 ; .word arena_next26_lzsa ; (7) .byte 128+14 ; .word arena_next27_lzsa ; (7) - .byte 0 ; ending + + +eject_sequence: + .byte 255 ; load to bg + .word arena_main_bg_lzsa ; this + .byte 6 + .word eject01_lzsa ; (3) + .byte 128+6 ; .word eject02_lzsa ; (3) + .byte 128+10 ; .word eject03_lzsa ; (5) + .byte 128+4 ; .word eject04_lzsa ; (2) + .byte 128+6 ; .word eject05_lzsa ; (3) + .byte 128+12 ; .word eject06_lzsa ; (6) + .byte 128+4 ; .word eject07_lzsa ; (2) + .byte 128+10 ; .word eject08_lzsa ; (5) + .byte 128+4 ; .word eject09_lzsa ; (2) + .byte 128+6 ; .word eject10_lzsa ; (3) + .byte 255 ; load to bg + .word sky_bg_lzsa ; this + .byte 128+8 ; .word sky01_lzsa ; (4) + .byte 128+10 ; .word sky02_lzsa ; (5) + .byte 128+20 ; .word sky03_lzsa ; (10) + .byte 128+16 ; .word sky04_lzsa ; (8) + .byte 128+12 ; .word sky05_lzsa ; (6) + .byte 20 + .word blank_lzsa ; (10) + .byte 0 + + + +hand_sprite: + .byte 3,4 + .byte $AA,$bA,$AA + .byte $AA,$bb,$AA + .byte $bb,$bb,$bA + .byte $bb,$bb,$bb + +hand_press_sprite: + .byte 3,4 + .byte $AA,$bb,$AA + .byte $bA,$bb,$AA + .byte $bb,$bb,$bb + .byte $bb,$bb,$bb + + diff --git a/games/ootw/zp.inc b/games/ootw/zp.inc index 3d58f0c0..8445de91 100644 --- a/games/ootw/zp.inc +++ b/games/ootw/zp.inc @@ -229,6 +229,7 @@ BUBBLES_Y = $EB ; C1 underwater BEFORE_SWING = $EB ; C1 SHOOTING_BOTTOM = $EB ; C2 cage CART_OUT = $EB ; C2 jail +BUTTON_PRESS = $EB ; c14 arena CUTFRAME = $EC DISP_PAGE = $ED ; ALL @@ -237,9 +238,11 @@ OFFSET = $EF INTRO_LOOPL = $F0 ; INTRO PHYSICIST_X = $F0 ; ALL +HAND_X = $F0 ; C14 INTRO_LOOPH = $F1 ; INTRO PHYSICIST_Y = $F1 ; ALL +HAND_Y = $F1 ; C14 SPRITETEMP = $F2 ; ALL XPOS = $F3 ; ALL