0 Members and 2 Guests are viewing this topic.
:ClrHome:0→S:9→O:9→P:9→Q:9→R:Goto Z:Lbl A:0→X:0→A:While X=0:(A+1)→A:If A=10:Goto B:getKey→X:End:Goto B:Lbl B:If X=24:Goto 1:If X=25:Goto 3:If X=26:Goto 4:If X=34:Goto 2:If O=2:(S-1)→S:If P=2:(S-1)→S:If Q=2:(S-1)→S:If R=2:(S-1)→S:Goto X:Lbl 1:If O=2:Then:(S+1)→S:9→O:Goto X:Else:(S-1)→S:Goto X:End:Lbl 2:If P=2:Then:(S+1)→S:9→P:Goto X:Else:(S-1)→S:Goto X:End:Lbl 3:If Q=2:Then:(S+1)→S:9→Q:Goto X:Else:(S-1)→S:Goto X:End:Lbl 4:If R=2:Then:(S+1)→S:9→R:Goto X:Else:(S-1)→S:Goto X:End:Lbl Z:randInt(1,4)→M:1→N:Goto X:Lbl X:If N=0:Goto Z:(N-1)→N:If M=1:Then:If O=9:(O-1)→O:End:If M=2:Then:If P=9:(P-1)→P:End:If M=3:Then:If Q=9:(Q-1)→Q:End:If M=4:Then:If R=9:(R-1)→R:End:0→M:Goto Y:Lbl Y:ClrHome:If O≤8:Then:Output(O,7,"<"):(O-1)→O:End:If P≤8:Then:Output(P,8,"V"):(P-1)→P:End:If Q≤8:Then:Output(Q,9,"^"):(Q-1)→Q:End:If R≤8:Then:Output(R,10,">"):(R-1)→R:End:Output(1,1,S):Output(3,6,"-":Output(3,11,"-":If O=0:9→O:If P=0:9→P:If Q=0:9→Q:If R=0:9→R:Goto A
While x=0If AGoto BEndLbl B
While x=0If A9>xend
:While X=0 and A<10:A+1→A:getKey→X:End:Goto B