0
0
Fork 0
mirror of https://git.sr.ht/~rabbits/uxn synced 2024-12-22 16:30:27 +00:00

(snake) Faster tail drawing

This commit is contained in:
Devine Lu Linvega 2024-03-24 10:36:25 -07:00
parent c9b691448b
commit 220983d694

View file

@ -110,12 +110,12 @@
STH
( | draw tail )
;snake-icns .Screen/addr DEO2
.snake/length LDZ #00
.snake/tail .snake/length LDZ DUP ADD OVR ADD SWP
&>loop ( -- )
DUPk ADD .snake/tail ADD LDZ #0005 SFT2 .Screen/x DEO2
DUPk ADD .snake/tail ADD INC LDZ #0005 SFT2 .Screen/y DEO2
LDZk #0005 SFT2 .Screen/x DEO2
INCk LDZ #0005 SFT2 .Screen/y DEO2
STHkr .Screen/sprite DEO
INC GTHk ?&>loop
INC INC GTHk ?&>loop
POP2
( | draw head )
.snake/x LDZ #0005 SFT2 .Screen/x DEO2