Skip to content

Commit

Permalink
tetris-PRG.info: Add local labels for bulkCopyToPpu
Browse files Browse the repository at this point in the history
  • Loading branch information
ejona86 committed Jan 15, 2024
1 parent 93c6bda commit a8d6994
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 6 deletions.
2 changes: 1 addition & 1 deletion screens.s
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ my_bulkCopyToPpu:
sta tmp1
lda palettes+1,x
sta tmp2
jsr copyToPpu
jsr bulkCopyToPpu+2
rts

screens = 10
Expand Down
2 changes: 1 addition & 1 deletion taus.s
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ renderStats:
sta tmp2
lda copyToPpuDuringRenderAddr
sta tmp1
jsr copyToPpu
jsr bulkCopyToPpu+2
lda #$00
sta copyToPpuDuringRenderAddr
sta copyToPpuDuringRenderAddr+1
Expand Down
15 changes: 12 additions & 3 deletions tetris-PRG.info
Original file line number Diff line number Diff line change
Expand Up @@ -964,9 +964,18 @@ LABEL { ADDR $AA6B; NAME "waitForVBlankAndEnableNmi"; };
LABEL { ADDR $AA78; NAME "disableNmi"; };
LABEL { ADDR $AA7C; NAME "_updatePpuCtrl"; };
LABEL { ADDR $AA8A; NAME "copyCurrentScrollAndCtrlToPPU"; };
LABEL { ADDR $AA98; NAME "bulkCopyToPpu"; };
LABEL { ADDR $AAF2; NAME "copyToPpu"; COMMENT "Address to read from stored in tmp1/2"; };
LABEL { ADDR $AB21; NAME "copyAddrAtReturnAddressToTmp_incrReturnAddrBy2"; };
LABEL { ADDR $AA98; NAME "bulkCopyToPpu"; COMMENT "Return address should contain data address; ret addr+2 is actual return. $80-$FF end. $4C recurse, 2 byte cpu addr. $60 unrecurse. Otherwise NES data stripe, 2 byte ppu addr, 1 byte length, data. length controls RLE and write direction"; };
LABEL { ADDR $AA9E; NAME "@processStripe"; };
LABEL { ADDR $AAB5; NAME "@setDirection"; COMMENT "Bit 7 of length: 0-right, 1-down"; };
LABEL { ADDR $AAC2; NAME "@checkForZeroLength"; COMMENT "Bit 6 of length: 0-literal, 1-run. If bits 0-5 are zero, length is 128"; };
LABEL { ADDR $AAC7; NAME "@clearLengthFlagBits"; };
LABEL { ADDR $AACA; NAME "@copyByteLoop"; };
LABEL { ADDR $AACD; NAME "@copyByte"; };
LABEL { ADDR $AAE6; NAME "@pointToNext"; };
LABEL { ADDR $AAF2; NAME "@processInst"; COMMENT "Address to read from stored in tmp1/2"; };
LABEL { ADDR $AAFC; NAME "@checkUnrecurse"; };
LABEL { ADDR $AB0A; NAME "@checkRecurse"; };
LABEL { ADDR $AB21; NAME "bulkCopyToPpu_reworkReturnAddress"; COMMENT "Copies address at return to tmp0/tmp1. Increments return by two"; };
LABEL { ADDR $AB47; NAME "generateNextPseudorandomNumber"; COMMENT "reg x: zeropage addr of seed; reg y: size of seed"; }; # canon
LABEL { ADDR $AB57; NAME "@updateNextByteInSeed"; };
LABEL { ADDR $AB5E; NAME "copyOamStagingToOam"; COMMENT "canon is initializeOAM"; };
Expand Down
2 changes: 1 addition & 1 deletion twoplayer.s
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ twoplayer_game_nametable:

copyRleNametableToPpu:
.export copyRleNametableToPpu
jsr copyAddrAtReturnAddressToTmp_incrReturnAddrBy2
jsr bulkCopyToPpu_reworkReturnAddress
ldx PPUSTATUS
lda #$20
sta PPUADDR
Expand Down

0 comments on commit a8d6994

Please sign in to comment.