diff --git a/main.s b/main.s index 09aec21..680b183 100644 --- a/main.s +++ b/main.s @@ -16,6 +16,9 @@ .segment "CODE" +bg_pallets: + .byte 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 + check: cmp #5 bcc skip @@ -25,42 +28,16 @@ skip: rts reset: + ldx #15 lda #$3F sta $2006 lda #$00 sta $2006 - lda #0 - sta $2007 - lda #1 - sta $2007 - lda #2 - sta $2007 - lda #3 - sta $2007 - lda #0 - sta $2007 - lda #1 - sta $2007 - lda #2 - sta $2007 - lda #3 - sta $2007 - lda #0 - sta $2007 - lda #1 - sta $2007 - lda #2 - sta $2007 - lda #3 - sta $2007 - lda #0 - sta $2007 - lda #1 - sta $2007 - lda #2 - sta $2007 - lda #3 +loop: + lda bg_pallets, x sta $2007 + dex + bpl loop lda #173 sta $00 lda #0