diff options
| author | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-05-12 21:20:33 +0200 |
|---|---|---|
| committer | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-05-12 21:20:33 +0200 |
| commit | ad830a7f81871e15f43d7255f7af5463d9dd0bc5 (patch) | |
| tree | 6217d30e13a96f8bc3a7675ab3e45c9e9c3f967a /src/bullets.s | |
| parent | d2cab2f600b4a5efea34fce9e17de0c2ba964c6c (diff) | |
| download | jetpac.nes-ad830a7f81871e15f43d7255f7af5463d9dd0bc5.tar.gz jetpac.nes-ad830a7f81871e15f43d7255f7af5463d9dd0bc5.zip | |
reset: Do not zero out RAM
This is usually done so the programmer can forget about initializing in
the future, but it not only hides programming mistakes, but we are also
resetting memory addresses which are never to be used by this simple
game. Hence, just skip resetting RAM altogether.
Last but not least, sprite initialization in `reset` code has also been
optimized so instead of around 2000 cycles it takes half of that. This
is done by only touching the first byte of the four bytes for a sprite
in OAM, which is enough for hiding random sprites and the cost of extra
`inx` instructions is far cheaper than all the extra `sta` to absolute
address with X-index from the old code.
Signed-off-by: Miquel Sabaté Solà <mikisabate@gmail.com>
Diffstat (limited to 'src/bullets.s')
0 files changed, 0 insertions, 0 deletions
