Advertisement
NovaYoshi

1bpp to whatever bpp

Jan 21st, 2014
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ChrPointer = 10
  2. TilesLeft = 12
  3.   lda #$00
  4.   sta PPUADDR
  5.   sta PPUADDR
  6.   lda #<CHR
  7.   sta ChrPointer+0
  8.   lda #>CHR
  9.   sta ChrPointer+1
  10.   lda #48
  11.   sta TilesLeft
  12.  
  13. CharLoop:
  14.   .repeat 2
  15.     ldy #0
  16.   : lda (ChrPointer),y
  17.     sta PPUDATA
  18.     iny
  19.     cpy #8
  20.     bne :-
  21.   .endrep
  22.  
  23.   ; alternatively make all but the first plane empty with a loop here
  24.  
  25.   lda ChrPointer+0
  26.   add #8
  27.   sta ChrPointer+0
  28.   bcc :+
  29.     inc ChrPointer+1
  30.   :
  31.  
  32.   dec TilesLeft
  33.   bne CharLoop
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement