From 122654c1ef9d99af8210ce95dee4eb4d1bc04b67 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Thu, 15 May 2025 16:27:36 +0200 Subject: Define the notion of a level MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is for now just a variable that will be set during initialization, and that it can be influenced through the `LEVEL` make variable. Both the level and the level "kind" notions are used tracking, at least, which kind of enemy wave we have to send. Signed-off-by: Miquel Sabaté Solà --- src/jetpac.s | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/jetpac.s') diff --git a/src/jetpac.s b/src/jetpac.s index 0c75bf4..ada5d1f 100644 --- a/src/jetpac.s +++ b/src/jetpac.s @@ -58,6 +58,19 @@ sta Joypad::zp_buttons1 sta Joypad::zp_buttons2 + ;; Initialize the level. We allow the build system to pass its own value for + ;; this in `LEVEL`, just in case we want to debug the enemy of a specific + ;; level. + .ifdef LEVEL + lda #LEVEL + sta Globals::zp_level + and #%00000111 + sta Globals::zp_level_kind + .else + sta Globals::zp_level + sta Globals::zp_level_kind + .endif + ;; Initialize the assets for the game. jsr Assets::init -- cgit v1.2.3