From 9ae51a4c210b8f01718e21eda592c498715a642b Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Wed, 11 Mar 2026 23:44:13 +0100 Subject: Initial implementation for items MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This now only supports the appearance of shuttle parts and the fact that the player can collect them at a very specific order and drop them so to stack up the final shuttle. This is of course just the skeleton and there's a bunch of TODO's left. Signed-off-by: Miquel Sabaté Solà --- src/interrupts.s | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'src/interrupts.s') diff --git a/src/interrupts.s b/src/interrupts.s index c5eb306..81709ed 100644 --- a/src/interrupts.s +++ b/src/interrupts.s @@ -62,7 +62,7 @@ ;; Do we need to update the lifes from players on the HUD? lda Player::zp_state and #%00001000 - beq @global_flags + beq @shuttle_update ;; Yeah! @@ -97,9 +97,21 @@ and #%11110111 sta Player::zp_state -@global_flags: - ;; TODO: some actions here will depend on the status of the game... +@shuttle_update: + ;; Should the shuttle be updated? lda Globals::zp_flags + tax + and #%00100000 + beq @game_status + jsr Items::update_shuttle + + ;; And unset the flag. + lda Globals::zp_flags + and #%11011111 + sta Globals::zp_flags + +@game_status: + txa and #%00000001 bne @ppu_registers -- cgit v1.2.3