update for new uxn

This commit is contained in:
Nico 2021-05-04 20:44:49 +01:00
parent 108d27c2b9
commit 5bdfd021e6
1 changed files with 3 additions and 3 deletions

View File

@ -87,7 +87,7 @@ BRK
@draw-pattern-line ( addr ) @draw-pattern-line ( addr )
#00 .Draw/col POK #00 .Draw/col POK
&loop &loop
DUP2 GET ;draw-byte JSR2 DUP2 LDA ;draw-byte JSR2
.Screen/x DEI2 #0004 ADD2 .Screen/x DEO2 ( add spacing between digits ) .Screen/x DEI2 #0004 ADD2 .Screen/x DEO2 ( add spacing between digits )
#0001 ADD2 ( get the next byte in the pattern ) #0001 ADD2 ( get the next byte in the pattern )
#01 .Draw/col PEK ADD .Draw/col POK #01 .Draw/col PEK ADD .Draw/col POK
@ -119,8 +119,8 @@ BRK
#0000 .Playback/position POK2 #0000 .Playback/position POK2
&continue &continue
.Playback/position PEK2 .Playback/pattern-addr PEK2 ADD2 ( put pattern line address on the stack ) .Playback/position PEK2 .Playback/pattern-addr PEK2 ADD2 ( put pattern line address on the stack )
DUP2 VOL GET .Audio0/volume DEO ( ln -- ) ( put the address of the pattern line on the stack ) DUP2 VOL LDA .Audio0/volume DEO ( ln -- ) ( put the address of the pattern line on the stack )
NOTE GET ( get the current note ) NOTE LDA ( get the current note )
DUP #00 EQU ,&rest JNZ ( if the note is 00, aka empty, skip playing it ) DUP #00 EQU ,&rest JNZ ( if the note is 00, aka empty, skip playing it )
.Audio0/pitch DEO ( play the note ) .Audio0/pitch DEO ( play the note )
,&end JMP ( jump to the end ) ,&end JMP ( jump to the end )