1
TI-BASIC / Movement on the graph screen
« on: November 03, 2012, 04:12:47 pm »
Hello,
I have read this nice tutorial about movement and I tried to do the same thing, but on the graph screen. I tried to add movement in the second dimension. For some reason it doesn't work - once any of the arrow keys is pressed, the pixel goes to the top of the screen and can only be moved horizontally.
Also I know that this is a very simple subject, but I'm just a beginner and I can't figure this by myself.
I have read this nice tutorial about movement and I tried to do the same thing, but on the graph screen. I tried to add movement in the second dimension. For some reason it doesn't work - once any of the arrow keys is pressed, the pixel goes to the top of the screen and can only be moved horizontally.
Code: [Select]
AxesOff:
FnOff:
ClrDraw:
ClrHome:
32->Y:
48->X:
Repeat K=45:
Pxl-On(Y,X:
Repeat Ans:
Getkey->K:
End:
ClrDraw:
X+(K=26 and X<94)-(K=24 and X>0)->X:
Y+(K=34 and Y<62)-(K=25 and Y>0)->Y:
End:
Also I know that this is a very simple subject, but I'm just a beginner and I can't figure this by myself.