diff options
| author | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-05-14 16:04:47 +0200 |
|---|---|---|
| committer | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-05-14 19:38:30 +0200 |
| commit | c9a37d15e270ef28b0048eba7cdab15b73b20331 (patch) | |
| tree | b23a8e62eabfc52b3dc490c66afad96c6d1c3519 /src/background.s | |
| parent | ae857d302cd6f81c130b216f5dcc16655a09b4ac (diff) | |
| download | jetpac.nes-c9a37d15e270ef28b0048eba7cdab15b73b20331.tar.gz jetpac.nes-c9a37d15e270ef28b0048eba7cdab15b73b20331.zip | |
Don't touch zp_arg2 on background checks
This was a leftover from a previous implementation and is no longer
needed. Moreover, I have also added a comment clarifying that the 'y'
register is preserved.
Signed-off-by: Miquel Sabaté Solà <mikisabate@gmail.com>
Diffstat (limited to 'src/background.s')
| -rw-r--r-- | src/background.s | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/background.s b/src/background.s index 28cb6df..add7059 100644 --- a/src/background.s +++ b/src/background.s @@ -11,6 +11,8 @@ ;; The boolean value is directly set into the `a` register; but the memory ;; will not be written in any way. Hence, you can still rely on the old ;; `zp_arg0` and `zp_arg1` values even after calling this function. + ;; + ;; The 'y' register is preserved. .proc collides ;; We iterate first on the rows, as that's how the data on ;; `Background::platforms` is actually sorted by. @@ -40,10 +42,7 @@ jmp @row_check @column_check: - ;; Save the first return argument, which is the Y tile coordinate. - sta Globals::zp_arg2 - - ;; Check the left edge + ;; Check the left edge. ;; ;; NOTE: small optimization on sky and ground which have $00 for the ;; left edge. |
