Optimised DIV2 by powers of 2 to SFT2

This commit is contained in:
Andrew Alderwick 2021-05-24 22:36:15 +01:00
parent e5f2c2bbd2
commit 00df90c47e
14 changed files with 74 additions and 56 deletions

View File

@ -6,6 +6,7 @@
%RTN { JMP2r } %RTN { JMP2r }
%MOD { DUP2 DIV MUL SUB } %MOD { DUP2 DIV MUL SUB }
%TOS { #00 SWP } %TOS { #00 SWP }
%2// { #01 SFT2 }
( devices ) ( devices )
@ -38,8 +39,8 @@
;on-mouse .Mouse/vector DEO2 ;on-mouse .Mouse/vector DEO2
( find center ) ( find center )
.Screen/width DEI2 #0002 DIV2 .center/x STZ2 .Screen/width DEI2 2// .center/x STZ2
.Screen/height DEI2 #0002 DIV2 .center/y STZ2 .Screen/height DEI2 2// .center/y STZ2
( background ) ( background )
;tiles ;cover-pattern JSR2 ;tiles ;cover-pattern JSR2

View File

@ -15,11 +15,12 @@
%RTN { JMP2r } %MOD { DUP2 / * - } %RTN { JMP2r } %MOD { DUP2 / * - }
%MOD8 { #07 AND } %MOD2 { #01 AND } %MOD8 { #07 AND } %MOD2 { #01 AND }
%SFL { #40 SFT SFT } %SFL { #40 SFT SFT }
%2// { #01 SFT2 } %8// { #03 SFT2 }
%WIDTH { #40 } %HEIGHT { #40 } %WIDTH { #40 } %HEIGHT { #40 }
%BANK1 { #8000 } %BANK2 { #a000 } %BANK1 { #8000 } %BANK2 { #a000 }
%GET-SIZE { WIDTH TOS #0008 // HEIGHT TOS ** } %GET-SIZE { WIDTH TOS 8// HEIGHT TOS ** }
%GET-ITERATORS { SWP2k POP SWP POP } %GET-ITERATORS { SWP2k POP SWP POP }
( devices ) ( devices )
@ -58,8 +59,8 @@
#07 #05 ;set-cell JSR2 #07 #05 ;set-cell JSR2
#06 #05 ;set-cell JSR2 #06 #05 ;set-cell JSR2
.Screen/width DEI2 #0002 // WIDTH TOS -- .anchor/x STZ2 .Screen/width DEI2 2// WIDTH TOS -- .anchor/x STZ2
.Screen/height DEI2 #0002 // HEIGHT TOS -- .anchor/y STZ2 .Screen/height DEI2 2// HEIGHT TOS -- .anchor/y STZ2
#01 .world/paused STZ #01 .world/paused STZ

View File

@ -2,8 +2,8 @@
%RTN { JMP2r } %RTN { JMP2r }
%8++ { #0008 ADD2 } %8-- { #0008 SUB2 } %8++ { #0008 ADD2 } %8-- { #0008 SUB2 }
%8** { #0008 MUL2 } %8// { #0008 DIV2 } %8** { #0008 MUL2 } %8// { #03 SFT2 }
%++ { #0001 ADD2 } %++ { #0001 ADD2 } %2// { #01 SFT2 }
%MOD8 { #07 AND } %MOD8 { #07 AND }
%TRACK { ;track/ch1 #00 .track/active LDZ #0020 MUL2 ADD2 } %TRACK { ;track/ch1 #00 .track/active LDZ #0020 MUL2 ADD2 }
@ -43,9 +43,9 @@
( vectors ) ;on-mouse .Mouse/vector DEO2 ( vectors ) ;on-mouse .Mouse/vector DEO2
( vectors ) ;on-button .Controller/vector DEO2 ( vectors ) ;on-button .Controller/vector DEO2
.Screen/width DEI2 #0002 DIV2 DUP2 #0080 SUB2 .trkframe/x1 STZ2 .Screen/width DEI2 2// DUP2 #0080 SUB2 .trkframe/x1 STZ2
#0080 ADD2 .trkframe/x2 STZ2 #0080 ADD2 .trkframe/x2 STZ2
.Screen/height DEI2 #0002 DIV2 DUP2 #0038 SUB2 #0010 SUB2 .trkframe/y1 STZ2 .Screen/height DEI2 2// DUP2 #0038 SUB2 #0010 SUB2 .trkframe/y1 STZ2
#0038 ADD2 #0010 SUB2 .trkframe/y2 STZ2 #0038 ADD2 #0010 SUB2 .trkframe/y2 STZ2
.trkframe/x1 LDZ2 .chnframe/x1 STZ2 .trkframe/y2 LDZ2 .chnframe/y1 STZ2 .trkframe/x1 LDZ2 .chnframe/x1 STZ2 .trkframe/y2 LDZ2 .chnframe/y1 STZ2

View File

@ -11,6 +11,9 @@
%LTS2 { #8000 ++ SWP2 #8000 ++ >> } %LTS2 { #8000 ++ SWP2 #8000 ++ >> }
%GTS2 { #8000 ++ SWP2 #8000 ++ << } %GTS2 { #8000 ++ SWP2 #8000 ++ << }
%INCR { SWP #01 + SWP } %INCR { SWP #01 + SWP }
%2// { #01 SFT2 }
%4// { #02 SFT2 }
%8// { #03 SFT2 }
%WAVEFORM { #1000 } %WAVEFORM { #1000 }
@ -62,8 +65,8 @@
;saw-path .File/name DEO2 #0100 .File/length DEO2 WAVEFORM #0500 ++ .File/load DEO2 ;saw-path .File/name DEO2 #0100 .File/length DEO2 WAVEFORM #0500 ++ .File/load DEO2
( find center ) ( find center )
.Screen/width DEI2 #0002 // .center/x STZ2 .Screen/width DEI2 2// .center/x STZ2
.Screen/height DEI2 #0002 // .center/y STZ2 .Screen/height DEI2 2// .center/y STZ2
( place octave ) ( place octave )
.center/x LDZ2 #0080 -- .octave-view/x1 STZ2 .center/x LDZ2 #0080 -- .octave-view/x1 STZ2
@ -191,8 +194,8 @@ BRK
@on-touch-octave-view ( -> ) @on-touch-octave-view ( -> )
.Mouse/x DEI2 .octave-view/x1 LDZ2 -- #0008 // SWP POP #09 ! ,&no-mod JCN .Mouse/x DEI2 .octave-view/x1 LDZ2 -- 8// SWP POP #09 ! ,&no-mod JCN
.Mouse/y DEI2 .octave-view/y1 LDZ2 -- #0008 // SWP POP .Mouse/y DEI2 .octave-view/y1 LDZ2 -- 8// SWP POP
DUP #00 ! ,&no-incr JCN DUP #00 ! ,&no-incr JCN
.octave LDZ #01 + .octave STZ &no-incr .octave LDZ #01 + .octave STZ &no-incr
DUP #02 ! ,&no-decr JCN DUP #02 ! ,&no-decr JCN
@ -203,8 +206,8 @@ BRK
BRK BRK
&no-mod &no-mod
.Mouse/x DEI2 .octave-view/x1 LDZ2 -- #0008 // SWP POP #06 > ,&no-key JCN .Mouse/x DEI2 .octave-view/x1 LDZ2 -- 8// SWP POP #06 > ,&no-key JCN
.Mouse/x DEI2 .octave-view/x1 LDZ2 -- #0008 // DUP2 SWP POP .last-note STZ ;notes ++ LDA ;play JSR2 .Mouse/x DEI2 .octave-view/x1 LDZ2 -- 8// DUP2 SWP POP .last-note STZ ;notes ++ LDA ;play JSR2
( release ) #00 .Mouse/state DEO ( release ) #00 .Mouse/state DEO
;draw-octave JSR2 ;draw-octave JSR2
&no-key &no-key
@ -213,7 +216,7 @@ BRK
@on-touch-adsr-view ( -> ) @on-touch-adsr-view ( -> )
.Mouse/x DEI2 .adsr-view/x1 LDZ2 -- #0008 // SWP POP #03 / .Mouse/x DEI2 .adsr-view/x1 LDZ2 -- 8// SWP POP #03 /
DUP #00 ! ,&no-a JCN DUP #00 ! ,&no-a JCN
.Audio0/adsr DEI .Audio0/adsr DEI
#10 .Mouse/state DEI #10 = #e0 * + + #10 .Mouse/state DEI #10 = #e0 * + +
@ -363,7 +366,7 @@ RTN
&no-dot &no-dot
OVR TOS .Audio0/addr DEI2 ++ LDA OVR TOS .Audio0/addr DEI2 ++ LDA
#02 / #02 /
TOS #0004 // .wave-view/y1 LDZ2 ++ .Screen/y DEO2 TOS 4// .wave-view/y1 LDZ2 ++ .Screen/y DEO2
.Screen/x DEI2 #0001 ++ .Screen/x DEO2 .Screen/x DEI2 #0001 ++ .Screen/x DEO2
( draw ) OVR .Audio0/length DEI2 SWP POP > #02 * #01 + .Screen/color DEO ( draw ) OVR .Audio0/length DEI2 SWP POP > #02 * #01 + .Screen/color DEO
( incr ) INCR ( incr ) INCR

View File

@ -1,6 +1,8 @@
( polycat ) ( polycat )
%RTN { JMP2r } %RTN { JMP2r }
%2// { #01 SFT2 }
%4// { #02 SFT2 }
( devices ) ( devices )
@ -25,8 +27,8 @@
#0caf .System/b DEO2 #0caf .System/b DEO2
( find center ) ( find center )
.Screen/width DEI2 #0002 DIV2 #0008 SUB2 .cat/x STZ2 .Screen/width DEI2 2// #0008 SUB2 .cat/x STZ2
.Screen/height DEI2 #0004 DIV2 #0003 MUL2 #0018 SUB2 .cat/y STZ2 .Screen/height DEI2 4// #0003 MUL2 #0018 SUB2 .cat/y STZ2
( vectors ) ( vectors )
;on-mouse .Mouse/vector DEO2 ;on-mouse .Mouse/vector DEO2

View File

@ -2,7 +2,8 @@
%RTN { JMP2r } %RTN { JMP2r }
%++ { #0001 ADD2 } %++ { #0001 ADD2 }
%2/ { #01 SFT2 } %2// { #01 SFT2 }
%4// { #02 SFT2 }
%8+ { #0008 ADD2 } %8+ { #0008 ADD2 }
%STEP8 { #33 SFT2 } %STEP8 { #33 SFT2 }
@ -48,8 +49,8 @@
#0050 .window/h STZ2 #0050 .window/h STZ2
( center window ) ( center window )
.Screen/width DEI2 2/ .window/w LDZ2 2/ SUB2 .window/x1 STZ2 .Screen/width DEI2 2// .window/w LDZ2 2// SUB2 .window/x1 STZ2
.Screen/height DEI2 2/ .window/h LDZ2 2/ SUB2 .window/y1 STZ2 .Screen/height DEI2 2// .window/h LDZ2 2// SUB2 .window/y1 STZ2
#01 .theme/r1 STZ #02 .theme/g1 STZ #03 .theme/b1 STZ #01 .theme/r1 STZ #02 .theme/g1 STZ #03 .theme/b1 STZ
#04 .theme/r2 STZ #06 .theme/g2 STZ #07 .theme/b2 STZ #04 .theme/r2 STZ #06 .theme/g2 STZ #07 .theme/b2 STZ
@ -57,8 +58,8 @@
#0c .theme/r4 STZ #0b .theme/g4 STZ #0d .theme/b4 STZ #0c .theme/r4 STZ #0b .theme/g4 STZ #0d .theme/b4 STZ
( find screen center ) ( find screen center )
.Screen/width DEI2 2/ .center/x STZ2 .Screen/width DEI2 2// .center/x STZ2
.Screen/height DEI2 2/ .center/y STZ2 .Screen/height DEI2 2// .center/y STZ2
;update-theme JSR2 ;update-theme JSR2
;draw-background JSR2 ;draw-background JSR2
@ -76,22 +77,22 @@ BRK
DUP2 #0010 NEQ2 ,&no-touch-red JCN DUP2 #0010 NEQ2 ,&no-touch-red JCN
.Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-red JCN .Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-red JCN
.Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-red JCN .Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-red JCN
( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 #0004 DIV2 SWP POP ;theme/r1 #00 .selection LDZ ADD2 STA ( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 4// SWP POP ;theme/r1 #00 .selection LDZ ADD2 STA
&no-touch-red &no-touch-red
DUP2 #0020 NEQ2 ,&no-touch-green JCN DUP2 #0020 NEQ2 ,&no-touch-green JCN
.Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-green JCN .Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-green JCN
.Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-green JCN .Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-green JCN
( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 #0004 DIV2 SWP POP ;theme/g1 #00 .selection LDZ ADD2 STA ( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 4// SWP POP ;theme/g1 #00 .selection LDZ ADD2 STA
&no-touch-green &no-touch-green
DUP2 #0030 NEQ2 ,&no-touch-blue JCN DUP2 #0030 NEQ2 ,&no-touch-blue JCN
.Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-blue JCN .Mouse/x DEI2 .window/x1 LDZ2 #0060 ADD2 LTH2 ,&no-touch-blue JCN
.Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-blue JCN .Mouse/x DEI2 .window/x1 LDZ2 #009c ADD2 GTH2 ,&no-touch-blue JCN
( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 #0004 DIV2 SWP POP ;theme/b1 #00 .selection LDZ ADD2 STA ( get new value ) .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0060 SUB2 4// SWP POP ;theme/b1 #00 .selection LDZ ADD2 STA
&no-touch-blue &no-touch-blue
DUP2 #0040 NEQ2 ,&no-touch-radio JCN DUP2 #0040 NEQ2 ,&no-touch-radio JCN
.Mouse/x DEI2 .window/x1 LDZ2 #0050 ADD2 LTH2 ,&no-touch-radio JCN .Mouse/x DEI2 .window/x1 LDZ2 #0050 ADD2 LTH2 ,&no-touch-radio JCN
.Mouse/x DEI2 .window/x1 LDZ2 #008c ADD2 GTH2 ,&no-touch-radio JCN .Mouse/x DEI2 .window/x1 LDZ2 #008c ADD2 GTH2 ,&no-touch-radio JCN
.Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0050 SUB2 STEP8 2/ #0008 DIV2 SWP POP .selection STZ .Mouse/x DEI2 .window/x1 LDZ2 SUB2 #0050 SUB2 STEP8 2// #0008 DIV2 SWP POP .selection STZ
&no-touch-radio &no-touch-radio
POP2 POP2

View File

@ -2,6 +2,7 @@
%++ { #0001 ADD2 } %++ { #0001 ADD2 }
%-- { #0001 SUB2 } %-- { #0001 SUB2 }
%2// { #01 SFT2 }
( devices ) ( devices )
@ -28,8 +29,8 @@
;on-frame .Screen/vector DEO2 ;on-frame .Screen/vector DEO2
( set origin ) ( set origin )
.Screen/width DEI2 #0002 DIV2 .Screen/x DEO2 .Screen/width DEI2 2// .Screen/x DEO2
.Screen/height DEI2 #0002 DIV2 .Screen/y DEO2 .Screen/height DEI2 2// .Screen/y DEO2
;default_icn .Screen/addr DEO2 ;default_icn .Screen/addr DEO2
#31 .Screen/color DEO #31 .Screen/color DEO

View File

@ -1,10 +1,13 @@
( Dev/Time ) ( Dev/Time )
%2// { #01 SFT2 }
%4// { #02 SFT2 }
%RTN { JMP2r } %RTN { JMP2r }
%MOD { DUP2 DIV MUL SUB } %MOD { DUP2 DIV MUL SUB }
%ABS2 { DUP2 #0f SFT2 EQU #04 JCN #ffff MUL2 } %ABS2 { DUP2 #0f SFT2 EQU #04 JCN #ffff MUL2 }
%SCALEX { #0002 DIV2 .Screen/width DEI2 #0002 DIV2 ADD2 #0040 SUB2 } %SCALEX { 2// .Screen/width DEI2 2// ADD2 #0040 SUB2 }
%SCALEY { #0002 DIV2 .Screen/height DEI2 #0002 DIV2 ADD2 #0040 SUB2 } %SCALEY { 2// .Screen/height DEI2 2// ADD2 #0040 SUB2 }
%12HOURS { DUP #0c GTH #0c MUL SUB } %12HOURS { DUP #0c GTH #0c MUL SUB }
%LTS2 { #8000 ADD2 SWP2 #8000 ADD2 GTH2 } %LTS2 { #8000 ADD2 SWP2 #8000 ADD2 GTH2 }
%GTS2 { #8000 ADD2 SWP2 #8000 ADD2 LTH2 } %GTS2 { #8000 ADD2 SWP2 #8000 ADD2 LTH2 }
@ -55,11 +58,11 @@ BRK
#00 SWP SCALEY .needles/sy STZ2 #00 SWP SCALEY .needles/sy STZ2
#00 SWP SCALEX .needles/sx STZ2 #00 SWP SCALEX .needles/sx STZ2
#00 .DateTime/minute DEI #0002 MUL2 ;table ADD2 LDA2 #00 .DateTime/minute DEI #0002 MUL2 ;table ADD2 LDA2
#00 SWP #0004 DIV2 #0003 MUL2 #0020 ADD2 SCALEY .needles/my STZ2 #00 SWP 4// #0003 MUL2 #0020 ADD2 SCALEY .needles/my STZ2
#00 SWP #0004 DIV2 #0003 MUL2 #0020 ADD2 SCALEX .needles/mx STZ2 #00 SWP 4// #0003 MUL2 #0020 ADD2 SCALEX .needles/mx STZ2
#00 .DateTime/hour DEI 12HOURS #05 MUL #0002 MUL2 ;table ADD2 LDA2 #00 .DateTime/hour DEI 12HOURS #05 MUL #0002 MUL2 ;table ADD2 LDA2
#00 SWP #0002 DIV2 #0040 ADD2 SCALEY .needles/hy STZ2 #00 SWP 2// #0040 ADD2 SCALEY .needles/hy STZ2
#00 SWP #0002 DIV2 #0040 ADD2 SCALEX .needles/hx STZ2 #00 SWP 2// #0040 ADD2 SCALEX .needles/hx STZ2
( needles ) ( needles )
#0080 SCALEX #0080 SCALEY .needles/sx LDZ2 .needles/sy LDZ2 #02 ;draw-line JSR2 #0080 SCALEX #0080 SCALEY .needles/sx LDZ2 .needles/sy LDZ2 #02 ;draw-line JSR2
@ -83,8 +86,8 @@ BRK
@draw-display ( -- ) @draw-display ( -- )
.Screen/height DEI2 #0002 DIV2 #0048 ADD2 .Screen/y DEO2 .Screen/height DEI2 2// #0048 ADD2 .Screen/y DEO2
.Screen/width DEI2 #0002 DIV2 .Screen/width DEI2 2//
DUP2 #0020 SUB2 .Screen/x DEO2 DUP2 #0020 SUB2 .Screen/x DEO2
;font-hex #00 .DateTime/hour DEI #0a DIV #08 MUL ADD2 .Screen/addr DEO2 ;font-hex #00 .DateTime/hour DEI #0a DIV #08 MUL ADD2 .Screen/addr DEO2
#22 .Screen/color DEO #22 .Screen/color DEO

View File

@ -2,6 +2,7 @@
%RTN { JMP2r } %RTN { JMP2r }
%MOD { DUP2 DIV MUL SUB } %MOD { DUP2 DIV MUL SUB }
%2// { #01 SFT2 }
( devices ) ( devices )
@ -24,8 +25,8 @@
#0da4 .System/b DEO2 #0da4 .System/b DEO2
( find screen center ) ( find screen center )
.Screen/width DEI2 #0002 DIV2 .center/x STZ2 .Screen/width DEI2 2// .center/x STZ2
.Screen/height DEI2 #0002 DIV2 .center/y STZ2 .Screen/height DEI2 2// .center/y STZ2
( draw ) ( draw )
;draw-table JSR2 ;draw-table JSR2

View File

@ -1,5 +1,9 @@
( GUI Animation ) ( GUI Animation )
%2// { #01 SFT2 }
( devices )
|00 @System [ &vector $2 &pad $6 &r $2 &g $2 &b $2 ] |00 @System [ &vector $2 &pad $6 &r $2 &g $2 &b $2 ]
|20 @Screen [ &vector $2 &width $2 &height $2 &pad $2 &x $2 &y $2 &addr $2 &color $1 ] |20 @Screen [ &vector $2 &width $2 &height $2 &pad $2 &x $2 &y $2 &addr $2 &color $1 ]
@ -20,8 +24,8 @@
;on-frame .Screen/vector DEO2 ;on-frame .Screen/vector DEO2
( starting position ) ( starting position )
.Screen/width DEI2 #0002 DIV2 .dvd/x STZ2 .Screen/width DEI2 2// .dvd/x STZ2
.Screen/height DEI2 #0002 DIV2 .dvd/y STZ2 .Screen/height DEI2 2// .dvd/y STZ2
#21 ;draw-dvd JSR2 #21 ;draw-dvd JSR2

View File

@ -1,6 +1,7 @@
( GUI Labels ) ( GUI Labels )
%RTN { JMP2r } %RTN { JMP2r }
%2// { #01 SFT2 }
( devices ) ( devices )
@ -27,8 +28,8 @@ BRK
@draw ( -- ) @draw ( -- )
( find screen center ) ( find screen center )
.Screen/width DEI2 #0002 DIV2 .center/x STZ2 .Screen/width DEI2 2// .center/x STZ2
.Screen/height DEI2 #0002 DIV2 .center/y STZ2 .Screen/height DEI2 2// .center/y STZ2
( draw ver line ) ( draw ver line )
.center/x LDZ2 .Screen/x DEO2 #0000 .Screen/y DEO2 .center/x LDZ2 .Screen/x DEO2 #0000 .Screen/y DEO2
@ -61,7 +62,7 @@ RTN
@draw-label-middle ( x y color addr -- ) @draw-label-middle ( x y color addr -- )
( load ) .label/addr STZ2 .label/color STZ .Screen/y DEO2 ( load ) .label/addr STZ2 .label/color STZ .Screen/y DEO2
( align ) .label/addr LDZ2 ;get-text-length JSR2 #0008 MUL2 #0002 DIV2 SUB2 .Screen/x DEO2 ( align ) .label/addr LDZ2 ;get-text-length JSR2 #0008 MUL2 2// SUB2 .Screen/x DEO2
.label/addr LDZ2 .label/addr LDZ2
&loop &loop
( draw ) DUP2 LDA #00 SWP #0008 MUL2 ;font ADD2 .Screen/addr DEO2 .label/color LDZ .Screen/color DEO ( draw ) DUP2 LDA #00 SWP #0008 MUL2 ;font ADD2 .Screen/addr DEO2 .label/color LDZ .Screen/color DEO

View File

@ -85,7 +85,7 @@
JMP2r JMP2r
@arvelie-text ( -- ) @arvelie-text ( -- )
.Screen/width DEI2 #0002 DIV2 #0034 SUB2 .Screen/x DEO2 .Screen/width DEI2 #01 SFT2 #0034 SUB2 .Screen/x DEO2
.Screen/height DEI2 #0008 SUB2 .Screen/y DEO2 .Screen/height DEI2 #0008 SUB2 .Screen/y DEO2
.DateTime/year DEI2 #07d6 SUB2 .DateTime/year DEI2 #07d6 SUB2
#000a ;modf JSR2 ;digit JSR2 #000a ;modf JSR2 ;digit JSR2
@ -97,7 +97,7 @@
JMP2r JMP2r
@neralie-text ( -- ) @neralie-text ( -- )
.Screen/width DEI2 #0002 DIV2 #0004 SUB2 .Screen/x DEO2 .Screen/width DEI2 #01 SFT2 #0004 SUB2 .Screen/x DEO2
.neralie/n0123 LDZ2 .neralie/n0123 LDZ2
#03e8 ;modf JSR2 ,digit JSR #03e8 ;modf JSR2 ,digit JSR
#0064 ;modf JSR2 ,digit JSR #0064 ;modf JSR2 ,digit JSR

View File

@ -14,7 +14,7 @@
%RTN { JMP2r } %RTN { JMP2r }
%++ { #01 ADD } %-- { #01 SUB } %++ { #01 ADD } %-- { #01 SUB }
%8+ { #0008 ADD2 } %8+ { #0008 ADD2 }
%8* { #0008 MUL2 } %8/ { #0008 DIV2 } %8* { #0008 MUL2 } %8/ { #03 SFT2 }
%MOD { DUP2 DIV MUL SUB } %MOD { DUP2 DIV MUL SUB }
%MOD8 { #07 AND } %MOD8 { #07 AND }
%MOD2 { #01 AND } %MOD2 { #01 AND }