From ae857d302cd6f81c130b216f5dcc16655a09b4ac Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Tue, 13 May 2025 14:57:15 +0200 Subject: Implement the base for moving bullets MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This establishes a way for bullets to move, be displayed as independent sprites, cycle these sprites, and check for the collision on the background. This is still lacking the collision check with enemies and has some obvious bugs that will be fixed on the next commits. Signed-off-by: Miquel Sabaté Solà --- src/player.s | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/player.s') diff --git a/src/player.s b/src/player.s index aac5dd0..c7b65af 100644 --- a/src/player.s +++ b/src/player.s @@ -110,6 +110,9 @@ ;; How many frames are we allowing for each walk animation state? WALK_COUNTER_MAX = (HZ / 10) + ;; Number of sprites from which the player is made of. + PLAYER_SPRITES_COUNT = 6 + ;; Initialize the player's sprite. Note that for the sprite to look ;; correctly on screen you still need to call `Player::update` afterwards. .proc init -- cgit v1.2.3