diff --git a/uxn-client/xrxs.rom b/uxn-client/xrxs.rom deleted file mode 100644 index 3d4f0f7..0000000 Binary files a/uxn-client/xrxs.rom and /dev/null differ diff --git a/uxn-client/xrxs.tal b/uxn-client/xrxs.tal index 670755c..f7387df 100644 --- a/uxn-client/xrxs.tal +++ b/uxn-client/xrxs.tal @@ -1,10 +1,5 @@ ( utility macros ) -%+ { ADD } %- { SUB } %* { MUL } %/ { DIV } -%< { LTH } %> { GTH } %= { EQU } %! { NEQ } -%++ { ADD2 } %-- { SUB2 } %** { MUL2 } %// { DIV2 } -%<< { LTH2 } %>> { GTH2 } %== { EQU2 } %!! { NEQ2 } - %INC-X { .Screen/x DEI2 #0008 ADD2 .Screen/x DEO2 } ( -- ) %INC-Y { .Screen/y DEI2 #0008 ADD2 .Screen/y DEO2 } ( -- ) @@ -16,9 +11,6 @@ %NEXT-TILE { DUP2 #0010 ADD2 } -%DEBUG { ;print-hex JSR2 #0a .Console/write DEO } -%DEBUG2 { SWP ;print-hex JSR2 ;print-hex JSR2 #0a .Console/write DEO } - %RTN { JMP2r } ( devices ) @@ -41,14 +33,21 @@ @state $1 @ticker $1 + +@logo-coords [ + &x $2 + &y $2 +] + @cart $64 @realm $64 ( program ) -|0100 ( -> ) -@init - ( theme ) +|0100 +@init ( -> ) + + ( steppewnolf-dark theme ) #02c1 .System/r DEO2 #02cd .System/g DEO2 #02cb .System/b DEO2 @@ -65,16 +64,21 @@ #00 .ticker STZ #00 .state STZ + CENTER-X .logo-coords/x STZ2 + CENTER-Y .logo-coords/y STZ2 + ;on-frame .Screen/vector DEO2 BRK @on-frame ( -> ) - ( wait a couple frames, draw uxn logo ) + + ( draw a piece of the logos ~ every half second ) + .ticker LDZ #01 ADD DUP #20 EQU ,&next-render JCN .ticker STZ - BRK + BRK &next-render .state LDZ #00 .ticker STZ @@ -95,15 +99,15 @@ BRK @draw-uxn-logo ( -> ) - CENTER-X #0020 SUB2 .Screen/x DEO2 - CENTER-Y #0010 SUB2 .Screen/y DEO2 + .logo-coords/x LDZ2 #0020 SUB2 .Screen/x DEO2 + .logo-coords/y LDZ2 #0010 SUB2 .Screen/y DEO2 #0100 #0000 &while EQU2k ,&end JCN DUP2 ;uxnlogo ADD2 .Screen/addr DEO2 #81 .Screen/sprite DEO INC-X NEXT-TILE #0030 AND2 #0000 NEQ2 ,&no-inc-y JCN - CENTER-X #0020 SUB2 .Screen/x DEO2 + .logo-coords/x LDZ2 #0020 SUB2 .Screen/x DEO2 INC-Y &no-inc-y #0010 ADD2 ,&while JMP &end POP2 POP2 @@ -112,15 +116,15 @@ RTN @draw-xrxs-logo-xr ( -> ) - CENTER-X .Screen/x DEO2 - CENTER-Y #0010 SUB2 .Screen/y DEO2 + .logo-coords/x LDZ2 .Screen/x DEO2 + .logo-coords/y LDZ2 #0010 SUB2 .Screen/y DEO2 #0080 #0000 &while EQU2k ,&end JCN DUP2 ;xrxslogo ADD2 .Screen/addr DEO2 #81 .Screen/sprite DEO INC-X NEXT-TILE #0030 AND2 #0000 NEQ2 ,&no-inc-y JCN - CENTER-X .Screen/x DEO2 + .logo-coords/x LDZ2 .Screen/x DEO2 INC-Y &no-inc-y #0010 ADD2 ,&while JMP &end POP2 POP2 @@ -129,15 +133,15 @@ RTN @draw-xrxs-logo-xs ( -> ) - CENTER-X .Screen/x DEO2 - CENTER-Y .Screen/y DEO2 + .logo-coords/x LDZ2 .Screen/x DEO2 + .logo-coords/y LDZ2 .Screen/y DEO2 #0100 #0080 &while EQU2k ,&end JCN DUP2 ;xrxslogo ADD2 .Screen/addr DEO2 #81 .Screen/sprite DEO INC-X NEXT-TILE #0030 AND2 #0000 NEQ2 ,&no-inc-y JCN - CENTER-X .Screen/x DEO2 + .logo-coords/x LDZ2 .Screen/x DEO2 INC-Y &no-inc-y #0010 ADD2 ,&while JMP &end POP2 POP2