Trailing-Edge
-
PDP-10 Archives
-
decus_20tap2_198111
-
decus/20-0070/gun001.bas
There are 2 other files named gun001.bas in the archive. Click here to see a list.
00100 ' NAME--GUNNER.BAS
00110 '
00120 ' DESCRIPTION--GENERATES GAME OF TARGET PRACTICE
00130 '
00140 ' SOURCE--KENNETH A. ASCHER, EASTERN MICHIGAN UNIVERSITY
00150 ' YPSILANTI, MICHIGAN 48197 U.S.A.
00160 '
00170 ' COPYRIGHT--1974 BY KENNETH A. ASCHER
00180 '
00190 ' WRITTEN--SEPTEMBER 5, 1968 REVISED JANUARY 11, 1974
00200 '
00210 ' INSTRUCTIONS--TYPE "RUN" AND FOLLOW INSTRUCTIONS
00220 '
00230 '
00240 ' * * * * * * * * * MAIN PROGRAM * * * * * * * * *
00250 '
00260 RANDOMIZE
00270 ' "N" IS THE INITIAL DISTANCE OF THE TARGET
00280 LET N=RND*10
00290 LET M1=46500
00300 PRINT"THIS IS THE GAME OF GUNNER WRITTEN BY KENNETH A. ASCHER"
00310 PRINT"WOULD YOU LIKE TO SEE THE INSTRUCTIONS...";
00320 INPUT R$
00330 IF R$="YES" THEN 390
00340 IF R$="Y" THEN 390
00350 IF R$="NO" THEN 550
00360 IF R$="N" THEN 550
00370 PRINT"PLEASE ANSWER 'YES' OR 'NO'...TRY AGAIN...";
00380 GO TO 320
00390 PRINT
00400 PRINT"YOU ARE AN ARTILLERY OFFICER WHO GIVES FIRING ORDERS TO A GUN"
00410 PRINT"CREW, TELLING THEM THE DEGREES OF ELEVATION WHICH YOU THINK"
00420 PRINT"WILL PLACE THE PROJECTILE ON TARGET. MAXIMUM RANGE OF YOUR"
00430 PRINT"GUN IS 46,500 METERS. A HIT WITHIN 100 METERS OF THE TARGET"
00440 PRINT"WILL DESTROY IT, HOWEVER WIND GUSTS CAN CAUSE UP TO 200 METER"
00450 PRINT"ERRORS.....AND...YOUR TARGET WILL BE SHOOTING BACK, SO MAKE"
00460 PRINT"ALL OF YOUR SHOTS COUNT..."
00470 PRINT"BUT FIRST, PLEASE TELL ME YOUR FIRST NAME...";
00480 INPUT A$
00490 IF A$ = " " THEN 510
00500 GO TO 580
00510 PRINT"YOU INDICATE THAT YOU DO NOT HAVE A NAME. YOU ARE A VERY WEIRD"
00520 PRINT"PERSON. PLEASE GIVE YOURSELF A NAME AND TRY AGAIN..."
00530 PRINT"NOW...WHAT IS YOUR FIRST NAME...";
00540 GO TO 480
00550 PRINT
00560 PRINT"BEFORE WE BEGIN, PLEASE TELL ME YOUR FIRST NAME...";
00570 GO TO 480
00580 LET S7=0
00590 LET Z=0
00600 LET Y=0
00610 FOR I=1 TO N
00620 LET X=RND(X)
00630 NEXT I
00640 LET N=N+1
00650 LET Q9=0
00660 PRINT
00670 PRINT"ENTER YOUR FIRING ORDERS AS REQUESTED."
00680 ' T=DISTANCE TO TARGET
00690 ' I=DISTANCE OF SHOT
00700 ' E=DISTANCE OVER (NEGATIVE), OR UNDER (POSITIVE) TARGET
00710 LET M2=30000
00720 LET T=43000-30000*RND(X)
00730 LET Y=Y+1
00740 LET S=0
00750 GO TO 1500
00760 PRINT"MINIMUM ELEVATION OF GUN IS ONE DEGREE."
00770 GO TO 790
00780 PRINT"MAXIMUM ELEVATION OF GUN IS 89 DEGREES."
00790 PRINT"YOU ARE WASTING VALUABLE SHOTS, "A$". ARE YOU TRYING TO"
00800 PRINT"BECOME A FRAGGING CANDIDATE? LET'S AIM THAT GUN WHERE"
00810 PRINT"IT WILL DO SOME GOOD."
00820 GO TO 2010
00830 PRINT"OVER TARGET BY";ABS(E);"METERS."
00840 GO TO 1890
00850 PRINT"SHORT OF TARGET BY";ABS(E);"METERS."
00860 GO TO 1890
00870 PRINT
00880 ' DON'T WORRY ABOUT THE CONTROL GEES IN THE NEXT LINE...
00890 PRINT"<<<<<TARGET DESTROYED>>>>>"
00900 LET X$="ROUNDS"
00910 ' THE NEXT INSTRUCTIONS TAKE CARE OF PLURALS...
00920 IF S=1 THEN 940
00930 GO TO 950
00940 LET X$="ROUND"
00950 PRINT S""X$" EXPENDED."
00960 IF S=1 THEN 980
00970 GO TO 1040
00980 PRINT
00990 PRINT"***EXCELLENT SHOT "A$". YOU KILLED THE TARGET ON THE FIRST TRY!!"
01000 PRINT"KEEP UP THE GREAT WORK!!!"
01010 PRINT
01020 PRINT" SINCERELY,"
01030 PRINT" THE PRESIDENT"
01040 LET Z=Z+1
01050 LET M2=S*5000
01060 PRINT
01070 PRINT"THE FORWARD OBSERVER HAS LOCATED A NEW TARGET."
01080 LET M1=46500
01090 LET M3=0
01100 PRINT"CAN YOU CONTINUE FIRING...";
01110 INPUT B$
01120 IF B$="YES" THEN 720
01130 IF B$="Y" THEN 720
01140 IF B$="NO" THEN 1250
01150 ' IF "NAME" IS TYPED, THEN A NEW PLAYER'S NAME MAY BE USED
01160 IF B$="N" THEN 1250
01170 IF B$="NAME"THEN 2540
01180 ' IF "I" IS TYPED, THE GAME WILL RESTART GIVING THE FIRST
01190 ' SET OF INSTRUCTIONS AGAIN
01200 IF B$="I" THEN 1240
01210 PRINT"COME ON, "A$", YOU CAN ONLY ANSWER THIS QUESTION YES OR NO."
01220 PRINT"TRY AGAIN, "A$", BUT THIS TIME BE MORE ACCURATE IN YOUR TYPING...";
01230 GO TO 1110
01240 LET Q9=2
01250 PRINT
01260 LET X$="ROUNDS"
01270 IF S7=1 THEN 1290
01280 GO TO 1300
01290 LET X$="ROUND"
01300 PRINT"YOU EXPENDED"S7""X$" TOTAL."
01310 LET Y$=X$="TARGETS"
01320 IF Y=1 THEN 1350
01330 IF Z=1 THEN 1370
01340 GO TO 1380
01350 LET Y$="TARGET"
01360 GO TO 1330
01370 LET X$="TARGET"
01380 PRINT"YOU DESTROYED"Z""X$" OUT OF"Y""Y$"."
01390 LET Z=(Z/Y)*100
01400 PRINT"YOUR EFFICIENCY RATING, "A$", IS"Z"%."
01410 IF Z=100 THEN 2590
01420 IF Z=0 THEN 2680
01430 ON INT((Z/10)+.999999)GO TO 2720,2740,2760,2800,2830,2860,2880,2900,2930,2960,2590
01440 IF Q9=1 THEN 2560
01450 IF Q9=2 THEN 2990
01460 PRINT
01470 PRINT"DISMISS YOUR CREW, ";A$;", AND WE'LL"
01480 PRINT"LET YOU BUY THE BEER AND CHECKOUT THE ACTION!!!"
01490 STOP
01500 PRINT
01510 LET Q2=Q2 + 0.1
01520 PRINT"DISTANCE TO THE TARGET IS";INT(T);"METERS."
01530 PRINT
01540 PRINT"ELEVATION ";
01550 INPUT B
01560 IF B>180 THEN 1850
01570 IF B<0 THEN 1850
01580 LET S=S+1
01590 LET S7=S7 + 1
01600 IF B=90 THEN 1730
01610 IF B>89 THEN 780
01620 IF B=0 THEN 2500
01630 IF B<1 THEN 760
01640 LET B2=2*B/57.3
01650 LET I=46500*SIN(B2)
01660 LET X=T-I
01670 LET N=RND(-N)*400-200
01680 LET E=INT(X)
01690 LET E=E+INT(N)
01700 IF E>100 THEN 850
01710 IF E<-100 THEN 830
01720 GO TO 870
01730 PRINT A$",";
01740 PRINT" YOU SHOT STRAIGHT UP......"
01750 PRINT"THE PROJECTILE WENT STRAIGHT UP....."
01760 PRINT"THE PROJECTILE CAME STRAIGHT DOWN....."
01770 PRINT"YOU JUST BLEW YOUR HEAD OFF, YOU STUPID IDIOT..."
01780 PRINT
01790 PRINT"TOO BAD....."
01800 PRINT"WE WILL MAKE YOU ALIVE AGAIN, BUT THIS TIME,"
01810 PRINT"DON'T BLOW YOURSELF UP!!!"
01820 PRINT"IF YOUR WOUNDS ARE NOT TOO GREAT, ";A$;", AND"
01830 PRINT"YOU WANT TO PLAY AGAIN, TYPE IN 'YES'"
01840 GO TO 1110
01850 PRINT"THAT'S IMPOSSIBLE, YOU NITWIT."
01860 PRINT"KEEP IT UP, "A$", AND YOU'LL END UP AS A PRIVATE."
01870 PRINT"LET'S TRY AGAIN, "A$", BUT THIS TIME USE YOUR HEAD."
01880 GO TO 1540
01890 IF ABS(E)<1000 THEN 2010
01900 IF M1-ABS(E)>0 THEN 2010
01910 PRINT A$", YOU CAME CLOSER LAST TIME...ARE YOU TRYING TO GET"
01920 IF M3=1 THEN 1950
01930 PRINT"A PURPLE HEART?"
01940 GO TO 2000
01950 PRINT"KILLED?"
01960 PRINT"...OR MAYBE YOU WANT YOUR CREW TO QUESTION THE"
01970 PRINT"MARITAL STATUS OF YOUR PARENTS"
01980 LET M3=0
01990 GO TO 2010
02000 LET M3=1
02010 LET M5=RND(X)
02020 LET M1=ABS(INT(E))
02030 LET X=-T/1000
02040 IF M5<.05 THEN 2010
02050 IF M5>.45 THEN 2010
02060 LET M2=INT(M2*M5)
02070 IF M2<=100 THEN 2120
02080 PRINT A$", THE TARGET RETURNED FIRE AND...MISSED YOU BY";M2;"METERS."
02090 IF M2<350 THEN 2440
02100 IF S<3 THEN 1530
02110 ON INT(10*RND(X)+1) GO TO 2200,2220,2240,2260,2300,2320,2340,2360,2380,2400,2420
02120 PRINT A$", THE TARGET RETURNED FIRE AND...STRUCK!!!"
02130 PRINT"BACK TO O.C.S."
02140 PRINT
02150 PRINT
02160 PRINT"YOU NOW HAVE A NEW CREW... BE MORE CAREFUL THIS TIME."
02170 PRINT
02180 LET M2=ABS((9-S)*10000)
02190 GO TO 1070
02200 PRINT"ARE YOU TRYING TO GET KILLED? WATCH IT..."
02210 GO TO 1530
02220 PRINT"THAT WAS CLOSE, TRY AGAIN..."
02230 GO TO 1530
02240 PRINT"WHAT A BREAK. MISSED..."
02250 GO TO 1530
02260 PRINT"WHEW...";
02270 GO TO 1530
02280 PRINT"GULP... THAT'S TOO CLOSE FOR COMFORT."
02290 GO TO 1530
02300 PRINT"YOU HAD BETTER MAKE THIS ONE COUNT...OR ELSE..."
02310 GO TO 1530
02320 PRINT"AW, COME ON..."
02330 GO TO 1530
02340 PRINT"AHEMMM..."
02350 GO TO 1530
02360 PRINT"LOOK OUT... NOW YOU'RE IN TROUBLE..."
02370 GO TO 1530
02380 PRINT"BETTER DUCK...TRY AGAIN BUT BE MORE CAREFUL..."
02390 GO TO 1530
02400 PRINT"WANT TO BET ON THE NEXT ONE????"
02410 GO TO 1530
02420 PRINT"NOW HE HAS THE RANGE... LOOK OUT FOR THE NEXT ONE..."
02430 GO TO 1530
02440 IF M2<200 THEN 2480
02450 PRINT"YOU SUSTAINED MINOR INJURIES THAT TIME."
02460 PRINT"BETTER GET HIM."
02470 GO TO 1530
02480 PRINT"YOU SUSTAINED MAJOR INJURIES THAT TIME."
02490 GO TO 2460
02500 PRINT
02510 PRINTA$;", ARE YOU TRYING TO DIG A CANAL??"
02520 PRINT"GET THAT GUN UP WHERE IT WILL DO SOME GOOD."
02530 GO TO 2010
02540 LET Q9=1
02550 GO TO 1250
02560 PRINT
02570 PRINT"WHAT IS YOUR FIRST NAME";
02580 GO TO 480
02590 PRINT"YOU'RE ONE HELL OF A SHOT, "A$". YOU HIT EVERY TARGET."
02600 PRINT"***CONGRAGULATIONS --- NOW JOIN THE RIOT SQUAD OF YOUR LOCAL POLICE***"
02610 GO TO 1440
02620 PRINT"YOU CHEATER...HOW CAN YOU DESTROY MORE TARGETS THAN"
02630 PRINT"WERE AVAILABLE???????"
02640 GO TO 1440
02650 PRINT"THIS MUST BE A COMPUTER ERROR SINCE YOU CAN'T GET LESS"
02660 PRINT"THAN ZERO PERCENT!!!!!"
02670 GO TO 1440
02680 PRINT"DO YOU REALIZE JUST HOW BAD OF A SHOT YOU ARE?"
02690 PRINT"YOUR SHOOTING STINKS!!!!! YOU DIDN'T EVEN HIT ONE"
02700 PRINT"SINGLE TARGET. PATHETIC, "A$". JUST PATHETIC."
02710 GO TO 1440
02720 PRINT"ONE OF THE POOREST EXHIBITIONS OF SHOOTING I HAVE EVER SEEN."
02730 GO TO 1440
02740 PRINT"EXTREMELY POOR. I WISH YOU WERE ON THEIR SIDE."
02750 GO TO 1440
02760 PRINT"YOU ARE WAY BELOW AVERAGE, "A$", AND YOU NEED HELP IN"
02770 PRINT"LEARNING WHICH END OF THE GUN TO SHOOT. BY THE WAY, WHEN DID"
02780 PRINT"YOU LAST HAVE YOUR EYSIGHT CHECKED?"
02790 GO TO 1440
02800 PRINT A$", YOU ARE BELOW AVERAGE. YOU NEED ONE HELL OF ALOT OF"
02810 PRINT"PRACTICE TO BEAT THE LONE RANGER!!!"
02820 GO TO 1440
02830 PRINT"ONLY AVERAGE...YOU WILL NEED MUCH MORE PRACTICE IF YOU"
02840 PRINT"EVER WANT TO MAKE IT TO THE TOP, "A$"."
02850 GO TO 1440
02860 PRINT"A LITTLE BETTER THAN AVERAGE....BUT NOT MUCH!!!!!"
02870 GO TO 1440
02880 PRINT"YOU ARE RATED 'O.K.', WHICH IS A LONG WAY FROM GOOD."
02890 GO TO 1440
02900 PRINT"YOU SCORED FAR SUPERIOR THAN MOST PEOPLE I KNOW...NEXT TIME,"
02910 PRINT"TRY FOR A HIGHER SCORE..."
02920 GO TO 1440
02930 PRINT"VERY GOOD. A LOT OF PEOPLE NEVER GET THIS HIGH"
02940 PRINT"EXCEPT ON POT. CONSIDER YOURSELF A SHARPSHOOTER!!!"
02950 GO TO 1440
02960 PRINT"EXCELLENT...YOU ARE A REAL CRACK SHOT...TRY TO GET ALL"
02970 PRINT"OF THE TARGETS NEXT TIME..."
02980 GO TO 1440
02990 PRINT
03000 PRINT"NEW GAME:"
03010 PRINT
03020 GO TO 400
03030 END
IIIAAAA>>AAA> AA@@@@IIIA>AQQ1@@@IIIA )F``III6~~FIII1*U*%?