Draw frame
This commit is contained in:
parent
de35b9908f
commit
abfb3f4760
|
@ -39,6 +39,16 @@
|
||||||
@fill-icn [ ffff ffff ffff ffff ]
|
@fill-icn [ ffff ffff ffff ffff ]
|
||||||
@pointer-icn [ 80c0 e0f0 f8e0 1000 ]
|
@pointer-icn [ 80c0 e0f0 f8e0 1000 ]
|
||||||
|
|
||||||
|
@btn-chr [
|
||||||
|
0000 1f3f 3f3f 3f3f 001f 3f7f 7f7f 7f7f
|
||||||
|
0000 ffff ffff ffff 00ff ffff ffff ffff
|
||||||
|
0000 f8fc fcfc fcfc 00f8 fcfe fefe fefe
|
||||||
|
fcfc fcfc fcfc fcfc fefe fefe fefe fefe
|
||||||
|
3f3f 3f3f 3f3f 3f3f 7f7f 7f7f 7f7f 7f7f
|
||||||
|
3f3f 3f3f 3f1f 0000 7f7f 7f5f 4020 1f00
|
||||||
|
ffff ffff ffff 0000 ffff ffff 0000 ff00
|
||||||
|
fcfc fcfc fcf8 0000 fefe fefa 0204 f800 ]
|
||||||
|
|
||||||
@button-icn
|
@button-icn
|
||||||
&top [
|
&top [
|
||||||
0000 1f3f 3f3f 3f3f 001f 3f7f 7f7f 7f7f
|
0000 1f3f 3f3f 3f3f 001f 3f7f 7f7f 7f7f
|
||||||
|
|
|
@ -53,11 +53,38 @@
|
||||||
#0009 DIV2k MUL2 SUB2 #0020 MUL2 #0008 ADD2 .Screen/x DEO2
|
#0009 DIV2k MUL2 SUB2 #0020 MUL2 #0008 ADD2 .Screen/x DEO2
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
|
@<draw-frame> ( x* y* w h sprite* -- )
|
||||||
|
.Screen/addr DEO2
|
||||||
|
,&h STR
|
||||||
|
,&w STR
|
||||||
|
DUP2 .Screen/y DEO2
|
||||||
|
,&y STR2
|
||||||
|
DUP2 .Screen/x DEO2
|
||||||
|
,&x STR2
|
||||||
|
#01 .Screen/auto DEO
|
||||||
|
#81 .Screen/sprite DEO
|
||||||
|
,&next JSR [ LIT &w $1 ] ,&repeat JSR #02 .Screen/auto DEO
|
||||||
|
,&next JSR #81 .Screen/sprite DEO
|
||||||
|
,&next JSR [ LIT &h $1 ] ,&repeat JSR
|
||||||
|
( left ) [ LIT2 &y $2 ] #0008 ADD2 .Screen/y DEO2
|
||||||
|
[ LIT2 &x $2 ] .Screen/x DEO2
|
||||||
|
,&next JSR ,&h LDR ,&repeat JSR #01 .Screen/auto DEO
|
||||||
|
,&next JSR #81 .Screen/sprite DEO
|
||||||
|
,&next JSR ,&w LDR ,&repeat JSR ,&next JSR #81 .Screen/sprite DEO
|
||||||
|
( fill ) ,&next JSR ,&x LDR2 #0008 ADD2 .Screen/x DEO2
|
||||||
|
,&y LDR2 #0008 ADD2 .Screen/y DEO2
|
||||||
|
JMP2r
|
||||||
|
&next .Screen/addr DEI2k #0010 ADD2 ROT DEO2
|
||||||
|
JMP2r
|
||||||
|
&repeat #00 &repeat-loop #81 .Screen/sprite DEO
|
||||||
|
INC GTHk ?&repeat-loop
|
||||||
|
POP2 JMP2r
|
||||||
|
|
||||||
@<draw-keyboard> ( -- )
|
@<draw-keyboard> ( -- )
|
||||||
#0020 #0000
|
#0020 #0000
|
||||||
&l ( -- )
|
&l ( -- )
|
||||||
DUP2 #00 <draw-key-id>
|
DUP2 #00 <draw-key-id>
|
||||||
( ) INC2 GTH2k ?&l
|
INC2 GTH2k ?&l
|
||||||
POP2 POP2 JMP2r
|
POP2 POP2 JMP2r
|
||||||
|
|
||||||
@<draw-key-id> ( id* state -- )
|
@<draw-key-id> ( id* state -- )
|
||||||
|
@ -77,8 +104,8 @@
|
||||||
|
|
||||||
@<draw-key> ( a* b* c* -- )
|
@<draw-key> ( a* b* c* -- )
|
||||||
<draw-button>
|
<draw-button>
|
||||||
.Screen/x DEI2k #0006 ADD2 ROT DEO2
|
.Screen/x DEI2k #0002 SUB2 ROT DEO2
|
||||||
.Screen/y DEI2k #0004 ADD2 ROT DEO2
|
.Screen/y DEI2k #0024 SUB2 ROT DEO2
|
||||||
( | a )
|
( | a )
|
||||||
<draw-glyph>
|
<draw-glyph>
|
||||||
.Screen/x DEI2k #0002 SUB2 ROT DEO2
|
.Screen/x DEI2k #0002 SUB2 ROT DEO2
|
||||||
|
@ -105,19 +132,10 @@
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
@<draw-button> ( -- )
|
@<draw-button> ( -- )
|
||||||
.Screen/x DEI2 .Screen/y DEI2
|
.Screen/x DEI2 .Screen/y DEI2 #0204 ;btn-chr <draw-frame>
|
||||||
( | draw )
|
;fill-icn .Screen/addr DEO2
|
||||||
[ LIT2 36 -Screen/auto ] DEO
|
[ LIT2 12 -Screen/auto ] DEO
|
||||||
;button-icn/top .Screen/addr DEO2
|
[ LIT2 03 -Screen/sprite ] DEOk DEOk DEOk DEO
|
||||||
[ LIT2 81 -Screen/sprite ] DEOk DEOk
|
|
||||||
( ) ;button-icn/middle .Screen/addr DEO2
|
|
||||||
DEOk
|
|
||||||
( ) ;button-icn/middle .Screen/addr DEO2
|
|
||||||
DEOk
|
|
||||||
( ) ;button-icn/middle .Screen/addr DEO2
|
|
||||||
DEOk DEO
|
|
||||||
.Screen/y DEO2
|
|
||||||
.Screen/x DEO2
|
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
@<update-pointer> ( color addr* -- )
|
@<update-pointer> ( color addr* -- )
|
||||||
|
|
Binary file not shown.
Loading…
Reference in New Issue