Compucolor.org – Virtual Media

Listing of file='SHOOT2.BAS;01' on disk='vmedia/word_puzzle-sector.ccvf'

100 REM 		FOR COMPUCOLOR II COPYRIGHT (C) 1979
110 REM 		BY COMPUCOLOR CORP.
120 REM 		WRITTEN BY A.W. GROGONO

130 DIM H(159),X0(1),SC(1)
140 PLOT 14,12,3,18,0
150 PRINT "C O M P U C O L O R  -  S H O O T"
160 PLOT 10:PRINT "INSTRUCTIONS:"
170 PRINT "  THE OBJECT IS TO SHOOT YOUR OPPONENT."
180 PRINT " EACH PLAYER: 1.ENTER GUN ELEVATION IN DEGREES & HIT ENTER"
190 PRINT "              2.ENTER NUMBER OF BAGS OF GUNPOWDER & HIT ENTER"
200 PLOT 10:PRINT "         THAT IS:  75 <ENTER> 9 <ENTER>":PLOT 10
210 PRINT "   NOTE: TO ABORT A GAME ENTER -9 FOR THE ANGLE"
215 PLOT 10:PRINT "..... TO RESTART GAME ENTER -5 FOR THE ANGLE."
220 PLOT 10:PRINT "NOW WAIT FOR THE END OF THE COUNTDOWN:"
230 PLOT 3,128,21,31,17:PRINT " COUNTDOWN: ";:PLOT 3,64,0
240 PLOT 6:PLOT 2
250 YH= 90* RND (1)
260 LH= 4* INT (10* RND (1)+ 1)
270 RH= 4* INT (10* RND (1)+ 1)
280 WH= 4+ 12* RND (1)
290 XH= 55.5+ 16* RND (1)
300 G= .1
310 WF= .003
320 VW= 20* RND (1)- 10
330 A= XH/ WH:B= 1/ WH:C= LH/ YH:D= RH/ YH
340 FOR I= 0TO 127:J= A- I* B:Y= YH* EXP (- J* J)
350 IF I> XHTHEN H(I)= RH+ Y- Y* D:GOTO 370
360 H(I)= LH+ Y- Y* C
370 PLOT 3,128,32,31,17
380 PRINT SPC( 4- LEN (STR$ (127- I)))127- I" "
390 PLOT 3,64,0:NEXT
400 PLOT 12:PLOT 15
410 PLOT 2:PLOT 246:PLOT 0
420 FOR I= 1TO 127:PLOT I,H(I):NEXT :PLOT 255
425 GOSUB 430:GOTO 500
430 PLOT 3,27,0
435 PLOT 29,18
440 PRINT "WIND ";INT (4* ABS (VW)+ .5);"  ":REM  2 SPACES
450 PLOT 3,27,1
460 IF VW> 0THEN 480
470 PRINT "<------":VW$= "LEFT.":GOTO 490
480 PRINT "------>":VW$= "RIGHT":GOTO 490
490 PLOT 3,27,2:PRINT "TO "VW$
495 RETURN
500 FOR P= - 1TO 1STEP 2:C= 19.5+ 2.5* P
510 X((P+ 1)/ 2)= XH+ P* (WH+ 32+ 12* RND (1))
520 PLOT 30:PLOT C:PLOT 29:PLOT C
530 PLOT 2:PLOT X((P+ 1)/ 2):PLOT H(X((P+ 1)/ 2)):PLOT 255
540 PLOT 30:PLOT 16:PLOT 29
550 PLOT 3,25+ 25* P,1
560 PRINT "PLAYER "(P+ 3)/ 2
570 PLOT 3,25+ 25* P,2
580 PRINT "SCORE: "SC((P+ 1)/ 2)
590 PLOT 3,25+ 25* P,4
600 PRINT "ANGLE/BAGS":NEXT
610 P= 2* INT (2* RND (1))- 1
620 T= .5
622 IF RND (1)> .5THEN 630
624 VW= VW+ INT (4* RND (1))- 2
626 GOSUB 430
630 P= - P:T= T+ .5
640 PLOT 19.5+ 2.5* P
650 L= 0:GOSUB 1020
660 L= 2+ LEN (I$)
670 E= VAL (I$)
680 IF E< 0THEN 1030
690 GOSUB 1020
700 VI= VAL (I$)/ 2
710 R= (E- 90)* P/ 57.2958
720 VX= VI* SIN (R)
730 VY= VI* COS (R)
740 X= X((P+ 1)/ 2):Y= H(X((P+ 1)/ 2))
750 Y= INT (Y/ 4)* 4+ 4
760 X0= X:Y0= Y
770 PLOT 30:PLOT 2
780 IF Y< 0THEN 910
790 IF X< 0OR X> 127THEN 910
800 IF Y> 127THEN 830
810 OUT 7,64
820 PLOT X:PLOT Y:PLOT X0:PLOT Y0:X0= X:Y0= Y
830 VX= VX+ (VW- VX)* WF:VY= VY- G:X= X+ VX:Y= Y+ VY
840 IF X< 0OR X> 127THEN 910
850 IF Y> H(X)THEN 780
860 OUT 7,64
870 X= X+ VX* (H(X)- Y)/ VY
880 X= INT (X):IF X> 159THEN X= 159
890 Y= H(X)
900 PLOT X0:PLOT Y0:PLOT X:PLOT Y
910 PLOT 255:PLOT 30:PLOT 16:PLOT 29
920 IF INT (X((1- P)/ 2)/ 2)< > INT (X/ 2)THEN 622
930 OUT 7,64
940 PLOT 14:PLOT 17
950 PLOT 3,ABS (INT (X/ 2)- 5),21- INT (Y/ 4+ .5)
960 PRINT "KA-POW-EE";
970 PLOT 26:PLOT 26:PLOT 26:PLOT 26:PLOT 26:PLOT 26:PLOT 10
980 GOTO 2000
990 OUT 7,64
1000 SC((P+ 1)/ 2)= SC((P+ 1)/ 2)+ 1
1010 GOTO 230
1020 PLOT 3,L+ 25+ 25* P,4+ INT (T):INPUT "";I$:PLOT 3,64,0:RETURN
1030 PLOT 6,2,12
1050 IF E= - 5THEN 230
1060 LOAD "MENU":RUN
2000 PLOT 29,19
2010 PLOT 2,X,Y,242,X- 2,Y+ 21,253,X,Y,242,X+ 3,Y+ 7,253,X,Y,242,X- 3,Y+ 15
2020 FOR J= 1TO 150:NEXT
2030 PLOT 253,X,Y+ 13,X- 2,Y+ 7,X+ 2,Y+ 20,X,Y,242,X+ 5,Y+ 20,255
2040 PLOT 16
2050 PLOT 2,X,Y,242,X- 3,Y+ 15,255
2060 PLOT 23
2070 PLOT 2,X- 1,Y+ 20,X+ 3,Y+ 25,X,Y,242,X+ 2,Y+ 11,253,X,Y,X- 1,Y+ 30
2080 PLOT 253,X,Y,242,X+ 1,Y+ 8,255
2090 PLOT 16
2100 PLOT 2,X,Y,242,X+ 2,Y+ 11,253,X,Y,242,X+ 5,Y+ 20
2110 PLOT 253,X,Y,242,X+ 1,Y+ 8,253,X,Y,242,X- 1,Y+ 30
2120 FOR J= 1TO 50:NEXT
2130 PLOT 253,X,Y+ 13,X- 2,Y+ 7,X+ 2,Y+ 20,X,Y,242,X- 2,Y+ 21
2140 PLOT 253,X,Y,242,X+ 3,Y+ 7,253,X- 1,Y+ 20,X+ 3,Y+ 25,255
2150 GOTO 990