(wireworld.tal) Fixed mouse picking issue

This commit is contained in:
neauoire 2023-06-07 09:58:10 -07:00
parent 3f162f6258
commit 59035ab291
1 changed files with 7 additions and 10 deletions

View File

@ -82,27 +82,24 @@ BRK
@on-mouse-down ( -> ) @on-mouse-down ( -> )
.Mouse/y DEI2 #03 SFT2 NIP #02 NEQ ?&no-menu
.Mouse/x DEI2 #03 SFT2 NIP .Mouse/x DEI2 #03 SFT2 NIP
.Mouse/y DEI2 #03 SFT2 NIP DUP #02 NEQ ?&no-color1
#0202 NEQ2k NIP2 ?&no-color1
#01 set-color #01 set-color
POP2 BRK
&no-color1 &no-color1
#0302 NEQ2k NIP2 ?&no-color2 DUP #03 NEQ ?&no-color2
#02 set-color #02 set-color
POP2 BRK
&no-color2 &no-color2
#0402 NEQ2k NIP2 ?&no-color3 DUP #04 NEQ ?&no-color3
#03 set-color #03 set-color
POP2 BRK
&no-color3 &no-color3
#0602 NEQ2k NIP2 ?&no-toggle DUP #06 NEQ ?&no-toggle
.timer/play LDZk #00 EQU SWP STZ .timer/play LDZk #00 EQU SWP STZ
#00 .Mouse/state DEO #00 .Mouse/state DEO
draw-ui draw-ui
POP2 BRK
&no-toggle &no-toggle
POP2 POP
&no-menu
( color ) .color LDZ .Mouse/state DEI #01 GTH #00 EQU MUL ( color ) .color LDZ .Mouse/state DEI #01 GTH #00 EQU MUL
( cell* ) .Mouse/x DEI2 #02 SFT2 NIP .Mouse/y DEI2 #02 SFT2 NIP ( cell* ) .Mouse/x DEI2 #02 SFT2 NIP .Mouse/y DEI2 #02 SFT2 NIP