Capture call colors
This commit is contained in:
parent
add22703ad
commit
1b8c1d88a0
|
@ -97,13 +97,14 @@ BRK
|
||||||
|
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
@draw-col ( distance -- )
|
@draw-col ( distance color -- )
|
||||||
|
|
||||||
|
#04 SFT ,&color STR
|
||||||
STH
|
STH
|
||||||
#8000
|
#8000
|
||||||
&l
|
&l
|
||||||
#00 OVR .Screen/y DEO2
|
#00 OVR .Screen/y DEO2
|
||||||
DUP STHkr ;get-color JSR2 .Screen/pixel DEO
|
DUP STHkr ;get-color JSR2 [ LIT &color $1 ] ADD .Screen/pixel DEO
|
||||||
INC GTHk ,&l JCN
|
INC GTHk ,&l JCN
|
||||||
POP2
|
POP2
|
||||||
POPr
|
POPr
|
||||||
|
@ -113,7 +114,6 @@ JMP2r
|
||||||
@get-color ( y distance -- color )
|
@get-color ( y distance -- color )
|
||||||
|
|
||||||
OVR #40 GTH ,&bottom JCN
|
OVR #40 GTH ,&bottom JCN
|
||||||
|
|
||||||
#01 SFT GTH INC
|
#01 SFT GTH INC
|
||||||
|
|
||||||
JMP2r
|
JMP2r
|
||||||
|
@ -130,7 +130,7 @@ JMP2r
|
||||||
.player/x LDZ2
|
.player/x LDZ2
|
||||||
.player/y LDZ2
|
.player/y LDZ2
|
||||||
|
|
||||||
[ #00 ;cast JSR2 ]
|
[ #00 ;cast JSR2 ] POP
|
||||||
STH2k ;raycast JSR2
|
STH2k ;raycast JSR2
|
||||||
OVR2 .player/x LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
OVR2 .player/x LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
||||||
OVR2 .player/y LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
OVR2 .player/y LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
||||||
|
@ -141,17 +141,20 @@ JMP2r
|
||||||
|
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
@cast ( -- range )
|
@cast ( -- range tile )
|
||||||
|
|
||||||
#8001
|
#8001
|
||||||
&r
|
&r
|
||||||
#00 OVR STH2k ;raycast JSR2
|
#00 OVR STH2k ;raycast JSR2
|
||||||
SWP2 .player/x LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
SWP2 .player/x LDZ2 STH2kr #01 SFT2 SUB2 ADD2
|
||||||
SWP2 .player/y LDZ2 STH2r #01 SFT2 SUB2 ADD2
|
SWP2 .player/y LDZ2 STH2r #01 SFT2 SUB2 ADD2
|
||||||
;get-tile JSR2 #00 NEQ ,&collide JCN
|
;get-tile JSR2
|
||||||
|
DUP #00 EQU ,&continue JCN
|
||||||
|
ROT POP JMP2r
|
||||||
|
&continue
|
||||||
|
POP
|
||||||
INC GTHk ,&r JCN
|
INC GTHk ,&r JCN
|
||||||
&collide
|
NIP #00
|
||||||
NIP
|
|
||||||
|
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue