home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
8bitfiles.net/archives
/
archives.tar
/
archives
/
genie-commodore-file-library
/
C64Software
/
CADV3.ARC
/
%d3
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2019-04-13
|
1KB
|
39 lines
1 GOTO16
2 GETA$:IFA$=""THEN10
3 IFA$>"/"ANDA$<":"THENSF=VAL(A$)-SS*(A$="0"):GOTO10
4 IFA$="[147]"THENSYS36888:GOTO10
5 IFA$="!"THENSYS36867:GOTO10
6 IFA$="="THENSYS36882:GOTO10
7 IFA$="&"THENSYS36879:GOTO10
8 IFA$=""THENSYS36885:GOTO10
9 A=USR(33),0:LOAD"CMND",D0
10 X=X+USR(121)*SF:Y=Y-USR(122)*SF
11 IFX>331THENX=331
12 IFX<12THENX=12
13 IFY>239THENY=239
14 IFY<40THENY=40
15 A=USR(34),X,Y,0:A=USR(34),16,Y,6:A=USR(34),X,231,7:RETURN
16 A=USR(33),0:A=USR(34),0,Y,6:A=USR(34),X,255,7:A=USR(0),0,1,4
17 A=USR(21):A=USR(17):A=USR(19):A=USR(1):GOSUB38
18 PRINTCHR$(14)"[147][197]NTER THE INCHES PER FOOT. [213]SE DECIMAL":PRINT"VALUES."
19 INPUTA$:L=VAL(A$):IFL=0THEN9
20 PRINT"[147]":A=USR(0),1,7,14:A=USR(1):A=USR(16):GOSUB38:GOTO21
21 A=USR(32),0
22 GOSUB2:A=USR(117):IFA<>16THEN22
23 SYS36864:X1=X-12:Y1=Y-40
24 A=USR(117):IFA<>0THEN24
25 A=USR(33),0:A=USR(34),0,Y,6:A=USR(34),X,255,7:A=USR(0),0,1,4
26 A=USR(21):A=USR(17):A=USR(19):A=USR(1)
27 PRINTCHR$(14)"[147]":PRINT
28 A$="":INPUT"[204]ENGTH (FEET,INCHES)";A$,B$
29 R=(VAL(A$)+VAL(B$)/12)*60*L:IFR=0THEN37
30 A$="":INPUT"[212]HETA=";A$:IFLEN(A$)<1THEN37
31 T=VAL(A$):IFT>175THENT=T+.05
32 X2=X1+R*COS(T/180*(null)):Y2=Y1-R*SIN(T/180*(null))
33 IF(X2>320)OR(X2<0)OR(Y2>200)OR(Y2<0)THEN35
34 PRINT"[147]":A=USR(0),1,7,14:A=USR(1):A=USR(16):A=USR(66),X1,Y1,X2,Y2:GOTO21
35 PRINT:PRINT"[210] VALUE IS TOO LARGE.":PRINT"[200]IT ANY KEY TO CONTINUE."
36 GETA$:IFA$=""THEN36
37 PRINT"[147]":A=USR(0),1,7,14:A=USR(1):A=USR(16):GOTO21
38 OPEN15,D0,15,"I":CLOSE15:RETURN