-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMAIN.REF
437 lines (369 loc) · 7.9 KB
/
MAIN.REF
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
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
@#BERRY
#IF BERRY > 1 THEN
#IF BERRY < 25 THEN
#WRITE
`C`%You pick some more wildberries...
#SET BERRY + 5;
#ENDIF
#ENDIF
#IF BERRY = 25 THEN
#WRITE
`C`%Don't you think you have enough?
#ENDIF
#IF BERRY = 0 THEN
#WRITE
`C`%You pick some wildberries...
#SET BERRY = 5;
#ENDIF
@END
@#BANKHILL
#IF ACCOUNT = 0 THEN
#CLS
#PRINT 1
`2You don't have an account with us yet. Do you wish to start one?
#CHOICE 2
Yes...
No...
#IFCHOICE 2
@DONE
#IFCHOICE 1
#SET ACCOUNT = 1;
#RETURN
@DONE
#ENDIF
#CLS
#PRINT 2
`2Welcome... You have `$$`vBANK``2 in your account.
`2You have `$$`g`2 on hand.
#CHOICE 4
Deposit...
Withdraw...
Close Account...
Get out of here...
#IFCHOICE 1
#CLS
#PRINT 5
`2Your account has `$$`vBANK``2.
`2You have `$$`g`2.
`2How much do you want to deposit?
`2Press 1 to Deposit all your gold on hand.
#INPUT
15
1
6
#FIX LASTRESPONSE
#IF LASTRESPONSE <= 0 THEN
#RETURN
#ENDIF
#IF LASTRESPONSE = 1 THEN
#SET BANK +1 GOLD;
#SET GOLD = 0;
#ENDIF
#IF GOLD >1 LASTRESPONSE THEN
#SET GOLD -1 LASTRESPONSE;
#SET BANK +1 LASTRESPONSE;
#ENDIF
#RETURN
@DONE
#IFCHOICE 2
#CLS
#PRINT 5
`2Your account has `$$`vBANK``2.
`2You have `$$`g`2.
`2How much do you want to withdraw?
`2Press 1 to withdraw all money in bank.
#INPUT
15
1
6
#IF LASTRESPONSE <= 0 THEN
#RETURN
#ENDIF
#IF LASTRESPONSE = 1 THEN
#SET GOLD +1 BANK;
#SET BANK = 0;
#ENDIF
#IF LASTRESPONSE <1 BANK THEN
#SET GOLD +1 LASTRESPONSE;
#SET BANK -1 LASTRESPONSE;
#ENDIF
#RETURN
@DONE
#IFCHOICE 4
@DONE
#IFCHOICE 3
#CLS
#PRINT 1
`2Are you sure you want to close your account??
#CHOICE 2
Yes..
No..
#IFCHOICE 1
#SET GOLD +1 BANK;
#SET BANK = 0;
#SET ACCOUNT = 0;
@DONE
#IFCHOICE 2
#RETURN
@DONE
@DONECHOICE
@END
@#TRAVELSTONE
#CLS
#PRINT 4
`C`2Stone Valley Travel Office
`X27`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-
`%"`2Welcome to the Travel office`F2C`%" says the woman behind the desk.
#CHOICE 2
Depart to Hill Valley...
Leave the Office...
#IFCHOICE 2
@DONE
#IFCHOICE 1
#CLS
#PRINT 2
`2It will cost `$$20`2 to goto Hill Valley.
`2You have `$$`g`2.
#CHOICE 2
Pay..
Don't Pay..
#IFCHOICE 1
#GOLD- 20
#GOTO 163
#NEWPOS 47 11
#MAPSCREEN 163
#DONE
#ENDIF
@DONE
#IFCHOICE 2
#RETURN
@DONE
@DONECHOICE
@END
@#TRAVELHILL
#CLS
#PRINT 4
`C`2Hill Valley Travel Office
`X27`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-`2=`0-
`%"`2Welcome to the Travel office`F2C`%" says the woman behind the desk.
#CHOICE 2
Depart to Stone Valley...
Leave the Office...
#IFCHOICE 2
@DONE
#IFCHOICE 1
#CLS
#PRINT 2
`2It will cost `$$30`2 to goto Stone Valley.
`2You have `$$`g`2.
#CHOICE 2
Pay..
Don't Pay..
#IFCHOICE 1
#GOLD- 30
#GOTO 82
#MAPSCREEN 82
#NEWPOS 65 18
#DONE
#ENDIF
@DONE
#IFCHOICE 2
#RETURN
@DONE
@DONECHOICE
@END
@#ROSHI
#CLS
#IF PORTCITYPASS = 0 THEN
#PRINT 11
`$A Man Says:
`2Psst`F2C hey`F2C boy!! If you beat me`F2C I'll give you a pass to `7Port City`2!
`2You have:
`%`e`2 experience points...
`@`h`2 hitpoints...
`!`a`2 attack points...
`!`d`2 defense points...
`2You have a `#`i`2 and a `#`z`2.
#ENDIF
#IF PORTCITYPASS = 1 THEN
#PRINT 11
`$Master Roshi says:
`2Welcome back!! Ready for a rematch!!!!
`2You have:
`%`e`2 experience points...
`@`h`2 hitpoints...
`!`a`2 attack points...
`!`d`2 defense points...
`2You have a `#`i`2 and a `#`z`2.
#ENDIF
#CHOICE 2
Challenge Him
Leave
#IFCHOICE 2
@DONE
#IFCHOICE 1
#MONSTER
Beat me if you can... Loser!!
Master Roshi
350
1000
100
50
45
#CLS
#PRINT 1
`2Sorry... You loose.. try again later...
#IF LASTMONSTER = 1 THEN
#CLS
#MAXENERGY
#SET MAXENERGY + 25;
#MAXENERGY
#SET STRENGTH + 10;
#SET DEFENSE + 10;
#IF PORTCITYPASS = 0 THEN
#PRINT 9
`$You are a great man.. YOU HAVE BESTED ME!
`2You get `%100 `2more experience points for a total of `%`e`2.
`2You get `@25 `2more hitpoints for a total of `@`h`2.
`2You get `!10 `2extra attack points for a total of `!`a`2.
`2You get `!10 `2extra defense points for a total of `!`d`2.
`2AND, as promised, your `$PASS `2to Port City. Good Luck! Come back anytime!
Press any key...
#ENDIF
#IF PORTCITYPASS = 1 THEN
#PRINT 8
`$Hey!! You beat me again!
`2You get `%100 `2more experience points for a total of `%`e`2.
`2You get `@25 `2more hitpoints for a total of `@`h`2.
`2You get `!10 `2extra attack points for a total of `!`a`2.
`2You get `!10 `2extra defense points for a total of `!`d`2.
Press any key...
#ENDIF
#SET PORTCITYPASS = 1;
#ENDIF
#WAIT
@DONE
@DONECHOICE
@END
@#HEALER
#CLS
#PRINT 7
`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0= `0Healer's Hut `0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-`0=`2-
`2You walk into the healers hut and find that the place already quite full.
`2You take a number, and then a seat. Finally, you hear your number called.
`2The nurse says, "`%How may we help you?`2"
#CHOICE 3
Ask for a complete heal...
Ask for some damage`F2C but not all`F2C to be healed...
Leave the hut...
#IFCHOICE 3
@DONE
#IFCHOICE 2
#CLS
#DECLARE HEAL
#SET HEAL =1 MAXENERGY;
#SET HEAL -1 HITPOINT;
#DECLARE NEWGOLD
#SET NEWGOLD =1 GOLD;
#SET NEWGOLD / 2;
#FIX NEWGOLD
#IF NEWGOLD >2 HEAL THEN
#SET NEWGOLD =1 HEAL;
#ENDIF
#PRINT 4
`2You have `%`vHITPOINT` `2hitpoint(s). It costs `$$2`2 For every hitpoint
`2we heal. With your current funds, we could heal up to `%`vNEWGOLD` `2hitpoints.
`2Please input the amount of hitpoints to heal. Enter `0(`$1`0) `2for all possible.:
#INPUT
10
1
5
#FIX LASTRESPONSE
#IF HITPOINT =1 MAXENERGY THEN
#CLS
#PRINT 3
`2I'm sorry, but you do not need to be healed! Maybe another time...
`0<`2Continue`0>
#WAIT
#RETURN
#ENDIF
#IF LASTRESPONSE >2 NEWGOLD THEN
#CLS
#PRINT 3
`2I'm sorry, but you do not have the funds. Maybe another time...
`0<`2Continue`0>
#WAIT
#RETURN
#ENDIF
#IF LASTRESPONSE = 0 THEN
#RETURN
#ENDIF
#IF LASTRESPONSE < 0 THEN
#RETURN
#ENDIF
#IF LASTRESPONSE < 2 THEN
#SET HITPOINT +1 NEWGOLD;
#SET NEWGOLD * 2;
#SET GOLD -1 NEWGOLD;
#PRINT 4
`!All Done!!! `2You are now healed.
`0<`2Continue`0>
#WAIT
@GOTO DONE
#ENDIF
#IF LASTRESPONSE <1 NEWGOLD THEN
#SET HITPOINT +1 LASTRESPONSE;
#SET LASTRESPONSE * 2;
#SET GOLD -1 LASTRESPONSE;
#PRINT 4
`!All Done!!! `2You are now healed.
`0<`2Continue`0>
#WAIT
#ENDIF
@#DONE
#ENDIF
@DONE
#IFCHOICE 1
#CLS
#DECLARE HEALER
#SET HEALER = MAXENERGY;
#SET HEALER - HITPOINT;
#SET HEALER * 2;
#Print 6
`2It costs `$2$`2 for every hitpoint healed.
`2You have `%`vHITPOINT` `2hitpoints.
`2It will cost you `$`vHEALER`$ `2to be completely healed.
`2Continue?
#CHOICE 2
Yes..
No..
#IFCHOICE 2
#RETURN
#IFCHOICE 1
#IF HITPOINT =1 MAXENERGY THEN
#PRINT 5
`2You don't need to be healed!!! You are perfectly ok!!!
`0<`2Continue`0>
#WAIT
@DONE
#ENDIF
#IF GOLD >1 HEALER THEN
#SET GOLD -1 HEALER;
#MAXENERGY
#PRINT 5
`!All done!!! `2You are now completely healed.
`0<`2Continue`0>
#WAIT
@DONE
#ENDIF
#IF GOLD <2 HEALER THEN
#PRINT 6
`4Your don't exactly have enough money for this...
`2You think to yourself, "Maybe later..."
`0<`2Continue`0>
#WAIT
#ENDIF
#RETURN
@DONE
@DONECHOICE
@END