diff options
| author | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-02-04 11:00:22 +0100 |
|---|---|---|
| committer | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-02-04 22:00:07 +0100 |
| commit | 6c4ac7727094259b3b5a25e8c168245983e70b2f (patch) | |
| tree | 089c185a436f57a58f43b6c0ed3eed53e8b93da5 /shared | |
| parent | fdf44365e56c3741f47cbd421a57f0d074a5492c (diff) | |
| download | code.nes-6c4ac7727094259b3b5a25e8c168245983e70b2f.tar.gz code.nes-6c4ac7727094259b3b5a25e8c168245983e70b2f.zip | |
scroll: Implement a roulette-like game
Signed-off-by: Miquel Sabaté Solà <mikisabate@gmail.com>
Diffstat (limited to 'shared')
| -rw-r--r-- | shared/diskun.s | 6 | ||||
| -rw-r--r-- | shared/ppu.s | 11 |
2 files changed, 14 insertions, 3 deletions
diff --git a/shared/diskun.s b/shared/diskun.s index d8bab90..8349748 100644 --- a/shared/diskun.s +++ b/shared/diskun.s @@ -26,9 +26,9 @@ ;; Background .byte DEFAULT_COLOR, $36, $17, $0F - .byte DEFAULT_COLOR, $00, $00, $00 - .byte DEFAULT_COLOR, $00, $00, $00 - .byte DEFAULT_COLOR, $00, $00, $00 + .byte DEFAULT_COLOR, $28, $0F, $30 + .byte DEFAULT_COLOR, $20, $0F, $30 + .byte DEFAULT_COLOR, $2F, $20, $30 ;; Foreground .byte DEFAULT_COLOR, $28, $0F, $30 diff --git a/shared/ppu.s b/shared/ppu.s new file mode 100644 index 0000000..42acb06 --- /dev/null +++ b/shared/ppu.s @@ -0,0 +1,11 @@ +;; WRITE_PPU_DATA is a macro that will write into PPUADDR the given address and +;; into PPUDATA the given byte value. +.macro WRITE_PPU_DATA address, value + bit $2002 + lda #.HIBYTE(address) + sta $2006 + lda #.LOBYTE(address) + sta $2006 + lda #value + sta $2007 +.endmacro |
