diff options
| author | Miquel Sabaté Solà <mssola@mssola.com> | 2026-03-02 22:34:27 +0100 |
|---|---|---|
| committer | Miquel Sabaté Solà <mssola@mssola.com> | 2026-03-02 22:34:27 +0100 |
| commit | 8ffad74ae370c0125c62b56ba23d8d74d48a4b3d (patch) | |
| tree | f2ea617b7c74c81b156c891b6bc0cc3592c311d7 /src | |
| parent | b9c8c62adac37df60480c10ca54a193d4a1459eb (diff) | |
| download | jetpac.nes-8ffad74ae370c0125c62b56ba23d8d74d48a4b3d.tar.gz jetpac.nes-8ffad74ae370c0125c62b56ba23d8d74d48a4b3d.zip | |
Small optimization on bullet initialization
Signed-off-by: Miquel Sabaté Solà <mssola@mssola.com>
Diffstat (limited to 'src')
| -rw-r--r-- | src/bullets.s | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/bullets.s b/src/bullets.s index 335e478..93ff8c5 100644 --- a/src/bullets.s +++ b/src/bullets.s @@ -64,7 +64,7 @@ ;; Initializing the pool is a matter of setting to $FF the state byte ;; for each bullet object. ldx #0 - ldy #0 + ldy #BULLETS_POOL_CAPACITY lda #$FF @pool_init_loop: sta zp_bullets_pool_base, x @@ -72,8 +72,7 @@ inx inx - iny - cpy #BULLETS_POOL_CAPACITY + dey bne @pool_init_loop rts |
