Advertisement
NovaYoshi

color fade

Feb 24th, 2017
427
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.   ldy #0
  2. @Loop:
  3.   jsr WaitVblank
  4.   lda #$3f
  5.   sta PPUADDR ; $2006
  6.   lda #$00
  7.   sta PPUADDR
  8.   lda FadeColors,y
  9.   sta PPUDATA ; $2007
  10.   lda #0
  11.   sta PPUSCROLL ; $2005
  12.   sta PPUSCROLL
  13.  
  14.   ; delay between colors
  15.   ldx #4
  16. : jsr WaitVblank
  17.   dex
  18.   bne :-
  19.  
  20.   ; next color
  21.   iny
  22.   cpy #8
  23.   bne @Loop
  24.   rts
  25.  
  26. FadeColors:
  27.   .byt $10, $00, $0f, $0f, $00, $10, $30
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement