-
Notifications
You must be signed in to change notification settings - Fork 0
/
printout.txt
201 lines (201 loc) · 4.41 KB
/
printout.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
1 LET hi=0: GO SUB 7000
5 PAPER 5: CLS
10 LET c=14
20 LET sub=0
30 LET f1=0: LET f2=0
40 PRINT AT 4,0;"_____________
_ ______________"
50 BORDER 2
60 FOR n=5 TO 21
70 PRINT AT n,0; PAPER 1;"
"
80 NEXT n
90 LET d=.9
100 LET score=0
110 PRINT AT 0,0; PAPER 2;"SCOR
E=00000-------HI-SCORE=00000----
-------LIVES=3--------------"
120 LET subm=0
130 LET lives=3
140 PRINT PAPER 2;AT 0,28+(hi<1
000)+(hi<100)+(hi<10);hi
150 INPUT ""
1000 LET z$=CHR$ PEEK 23556
1010 IF z$="5" AND c>0 THEN LET
c=c-1: PRINT AT 4,c;" _"
1020 IF z$="8" AND c<28 THEN LET
c=c+1: PRINT AT 4,c-1;"_ "
1030 IF f1=1 THEN GO SUB 2500
1040 IF f2=1 THEN GO SUB 3500
1050 IF z$="1" AND f1=0 THEN IF
c>0 THEN GO SUB 2000
1060 IF z$="2" AND f2=0 THEN IF
c<28 THEN GO SUB 3000
1070 IF sub=0 AND RND>d THEN LET
sub=1: GO SUB 4000: GO TO 1090
1080 IF sub=1 THEN GO SUB 4500
1090 PRINT AT 0,7+(score<1000)+(
score<100)+(score<10); PAPER 2;s
core
1100 IF sub=1 AND subm=0 AND RND
>d THEN GO SUB 5000: GO TO 1120
1110 IF subm=1 THEN GO SUB 5500
1120 IF lives=0 THEN GO TO 9000
1130 GO TO 1000
2000 REM init f1
2010 LET f1=1
2020 LET l1=5
2030 LET c1=c-1
2500 REM f1
2510 LET l1=l1+1
2520 IF SCREEN$ (l1,c1)<>" " THE
N GO TO 2700
2530 IF l1=21 THEN GO TO 2900
2540 PRINT AT l1-1,c1; PAPER 1;"
";AT l1,c1;" "
2550 RETURN
2700 REM bang f1
2710 LET sub=0
2720 LET f1=0
2730 PRINT AT l1-1,c1; PAPER 1;"
";AT l1,c1; PAPER 2; INK 6; FLA
SH 1;" "
2740 FOR i=1 TO 10: NEXT i
2750 PRINT AT sl,sc; PAPER 1;"
"
2760 LET score=score+10*sl
2770 LET d=d-.05+.05*(d=0)
2780 RETURN
2900 REM boom f1
2910 PRINT AT l1-1,c1; PAPER 1;"
";AT l1,c1; PAPER 2; INK 6; FLA
SH 1;" "
2920 FOR i=1 TO 10: NEXT i
2930 PRINT AT l1,c1; PAPER 1;" "
2940 LET f1=0
2950 RETURN
3000 REM init f2
3010 LET f2=1
3020 LET l2=5
3030 LET c2=c+4
3500 REM f2
3510 LET l2=l2+1
3520 IF SCREEN$ (l2,c2)<>" " THE
N GO TO 3700
3530 IF l2=21 THEN GO TO 3900
3540 PRINT AT l2-1,c2; PAPER 1;"
";AT l2,c2;" "
3550 RETURN
3700 REM bang f2
3710 LET sub=0
3720 LET f2=0
3730 PRINT AT l2-1,c2; PAPER 1;"
";AT l2,c2; PAPER 2; INK 6; FLA
SH 1;" "
3740 FOR i=1 TO 10: NEXT i
3750 PRINT AT sl,sc; PAPER 1;"
"
3760 LET score=score+10*sl
3770 LET d=d-.05+.05*(d=0)
3780 RETURN
3900 REM boom f2
3910 PRINT AT l2-1,c2; PAPER 1;"
";AT l2,c2; PAPER 2; INK 6; FLA
SH 1;" "
3920 FOR i=1 TO 10: NEXT i
3930 PRINT AT l2,c2; PAPER 1;" "
3940 LET f2=0
3950 RETURN
4000 REM init sub
4010 LET sl=6+INT (RND*16)
4020 LET r=RND
4030 IF r>.5 THEN LET sd=-1
4040 IF r<=.5 THEN LET sd=1
4050 IF sd=-1 THEN LET sc=28
4060 IF sd=1 THEN LET sc=0
4070 LET sub=1
4500 REM sub
4510 IF (sc=1 AND sd=-1) OR (sc=
27 AND sd=1) THEN GO TO 4700
4520 LET sc=sc+sd
4530 IF sd=1 THEN PRINT AT sl,sc
-1; PAPER 1;" "
4540 IF sd=-1 THEN PRINT AT sl,s
c; PAPER 1;" "
4550 RETURN
4700 REM sub stop
4710 LET sub=0
4720 PRINT AT sl,sc; PAPER 1;"
"
4730 RETURN
5000 REM sub missile init
5010 LET sml=sl-1
5020 LET smc=sc+1
5030 LET subm=1
5500 REM sub missile
5510 LET sml=sml-1
5520 IF SCREEN$ (sml,smc)="" AND
sml=4 THEN GO TO 6500
5530 IF sml=4 THEN GO TO 6000
5540 PRINT AT sml+1,smc; PAPER 1
;" ";AT sml,smc;" "
5550 RETURN
6000 REM sub missile boom
6010 PRINT AT sml+1,smc; PAPER 2
; INK 6; FLASH 1;" "
6020 FOR i=1 TO 10: NEXT i
6030 PRINT AT sml+1,smc; PAPER 1
;" "
6040 LET subm=0
6050 RETURN
6500 REM sub missile bang
6510 PRINT AT 4,c; PAPER 2; INK
6; FLASH 1;" "
6520 PRINT AT sml+1,smc; PAPER 1
;" "
6530 FOR i=1 TO 30: NEXT i
6540 LET lives=lives-1
6560 PRINT AT 4,c;" "
6570 PRINT AT 1,17; PAPER 2;live
s
6580 LET subm=0
6590 RETURN
7000 REM characters
7010 RESTORE 7010: FOR n=1 TO 11
: READ a$: FOR m=0 TO 7: READ z:
POKE USR a$+m,z: NEXT m: NEXT n
: RETURN
7020 DATA " ",0,0,0,60,60,0,0,0
7030 DATA " ",145,82,52,7,224,44
,74,137
7040 DATA " ",0,64,60,28,255,127
,63,255
7050 DATA " ",0,53,53,127,255,25
5,255,255
7060 DATA " ",128,241,251,255,25
5,255,255,255
7070 DATA " ",0,2,28,156,255,254
,252,255
7080 DATA " ",0,24,24,24,24,24,3
6,36
7090 DATA " ",0,0,0,0,127,255,25
5,127
7100 DATA " ",0,0,62,8,255,255,2
55,255
7110 DATA " ",126,126,126,126,25
5,255,255,255
7120 DATA " ",0,0,0,0,254,255,25
5,254
9000 PRINT AT 10,10; FLASH 1; PA
PER 1; INK 7;"YOU ARE DEAD!"
9010 IF score>hi THEN LET hi=sco
re: PRINT AT 12,10; INVERSE 1; F
LASH 1; PAPER 1; INK 7;"NEW HIGH
-SCORE!"
9020 PRINT AT 14,8; PAPER 1; INK
7; FLASH 1;"ANOTHER GAME Y/N?"
9030 IF INKEY$="y" OR INKEY$="Y"
THEN GO TO 5
9040 IF INKEY$="n" OR INKEY$="N"
THEN STOP
9050 GO TO 9030