10 REM >:0.$.OLD_DREAMS.OldDreams 20 REM 30 REM New Start, Old Dreams. 40 REM An adventure game for the Acorn Archimedes computer. 50 REM Currently only tested on a A310 machine. 60 REM Thanks to Terje Sletteboe and Georgis Delaveris so that I could 70 REM make my old dreams a reality. 80 REM 90 REM Created by Tor O. Houghton in 1989 Anno Domini. 95 REM Made Beeb compatible and debugged by C.J.Richardson. 100 REM 110 REM For last update, see file string for details 120 MODE7 121 A%=0:X%=&FF:F%=USR&FFF4 DIV&100 AND7:IF F%>2 MODE3+128 130 PROCsetvar 140 FOR I%=1 TO locs% 150 READ name$(I%):A=INKEY(W): IF W>1 PROCcheck(name$(I%)):PRINT I% 160 NEXT 170 FOR I%=1 TO locs% 180 FOR J%=1 TO 6 190 READ pdir%(I%,J%):A=INKEY(W): IF W>1 PRINT pdir%(I%,J%),I%,J% 200 NEXT 210 NEXT 220 FOR I%=1 TO numobj% 230 READ obj$(I%):A=INKEY(W):IF W>1 PRINT obj$(I%),I% 240 NEXT 250 FOR I%=1 TO numobj% 260 READ object$(I%):A=INKEY(W):IF W>1 PRINTobject$(I%),I% 270 NEXT 280 FOR I%=1 TO numcom% 290 READ com$(I%):A=INKEY(W):IF W>1 PRINT com$(I%),I% 300 NEXT 310 FOR I%=1 TO numobj% 320 READ objp%(I%):A=INKEY(W):IF W>1 PRINT objp%(I%),I% 330 NEXT 340 FOR I%=1 TO 6 350 READ dir$(I%):A=INKEY(W):IF W>1 PRINT dir$(I%),I% 360 NEXT 370 PROClk 380 REPEAT 390 REPEAT 410 IF cpos%=3 s%=FALSE 420 IF cpos%=2 AND gf3%=FALSE AND wf1%=1 s%=TRUE 430 IF wf1%=0 AND objp%(8)=0 AND oxf%=1 s%=FALSE 440 PROCcd 450 INPUT '"What now? "a$ 451 REM IF a$="CHEAT" INPUT cpos% 460 ON ERROR REPORT:PRINTERL:END:PRINT"That's beyond my knowledge." 470 IF a$="" THEN 450 480 a$=FNcase(a$) 490 S%=INSTR(a$," ") 500 IF S%=0 THEN comno%=FNcomno(a$):objno%=0:GOTO 530 510 comno%=FNcomno(LEFT$(a$,INSTR(a$," ")-1)) 520 objno%=FNobjno(MID$(a$,INSTR(a$," ")+1)) 530 IF comno%=0 THEN PRINT FNhuh 540 UNTIL comno%<>0 550 PRINT 560 IF comno%<7 PROCmove:GOTO 390 570 c%=comno%-6 571 IF c%=1 OR c%=2 PROCg 572 IF c%=3 PROCdr 573 IF c%=4PROCop 574 IFc%=5PROCcl 575 IFc%=6 OR c%=7 PROCht 576 IFc%=8PROCpsh 577 IFc%=9PROCins 578 IFc%=10PROCpl 579 IFc%=11PROCdg 580 IFc%=12PROClt 581 IFc%=13PROCtrn 582 IFc%=14PROCet 583 IFc%=15 OR c%=16 PROCdrnk 584 IFc%=17PROCenter 585 IFc%=18PROCgo 586 IFc%=19PROCinv 587 IFc%=20PROClk 588 IFc%=21PROChlp 589 IFc%=22PROChnt 590 IFc%=23PROCq 591 IFc%=24PROCexa 592 IFc%=25PROCrd 593 IFc%=26PROCcb 594 IFc%=27PROCuse 595 IFc%=28PROCjmp 596 IFc%=29PROCld 597 IFc%=30PROCld 598 IFc%>30 AND c%<35 PROCdst 599 IFc%=35PROCwer 600 IFc%=36PROCscre 601 UNTILFALSE 602 END 610 620 DEFPROCht 630 PRINT"You seem very violent." 640 ENDPROC 650 660 DEFPROClt 670 PRINT "Where and with what??" 680 ENDPROC 690 700 DEFPROCtime 710 m%=m%+1 720 IF wf1%=0 helm$=" (through the helmet)." ELSE helm$="." 730 IF m%=99 PRINT '"An explosion can be heard";helm$;"Then you see a bright flash."'"Oh dear, it seems to me that you have blown it."'"You are dead.":PROCscre:END 740 IF m%>75 AND m%<99 PRINT '"WaRnINg: SysTEM FAiLurE. MeLTdown iS CerTAin";helm$:ENDPROC 750 IF m%>44 AND m%<76 PRINT '"WaRNing: sYSteM FaIluRE. MAinFrameEe CCcomPutER CAn'T cOMpenSAte";helm$:ENDPROC 760 IF m%>39 AND m%<45 PRINT '"WARNING: THE REACTOR IS HAVING A MELT-DOWN";helm$:ENDPROC 770 IF m%>24 AND m%<40 PRINT '"WARNING: THE REACTOR IS OVERHEATING";helm$:ENDPROC 780 IF m%>19 AND m%<25 PRINT '"It sounds as if there's an overload somewhere";helm$:ENDPROC 790 IF m%>4 AND m%<20 PRINT '"A loud beeping sound can be heard";helm$:ENDPROC 800 IF m%<5 PRINT '"A faint beeping sound can be heard";helm$:ENDPROC 810 ENDPROC 820 830 DEFPROCscre 840 PRINT"You have scored ";score%;" out of 50 possible points." 850 ENDPROC 860 870 DEFPROCins 880 IF INSTR(a$,"disk")=0 GOTO 960 890 IF cpos%<>16 AND cpos%<>10 AND cpos%<>13 PRINT "Into what?":ENDPROC 900 IF cpos%=16 AND objp%(5)=0 GOTO 950 910 IF cpos%=10 AND objp%(1)=0 PRINT"Swish. The door opens...":gf1%=FALSE:PRINT"..but unfortunately the mechanism jammed, so it ate the card.":objp%(1)=-1:ENDPROC 920 IF cpos%=13 AND objp%(1)=0 PRINT"Swish. The door opens...":gf1%=FALSE:A=INKEY(70):PRINT"but unfortunately the mechanism jammed, so it ate the card.":objp%(1)=-1:ENDPROC 930 IF cpos%=16 AND objp%(objno%)=0 PRINT"That sounds stupid.":ENDPROC 940 GOTO 960 950 PRINT"You insert the disc into the mainframe computer. Almost instaneously"'"the computer lights up (it has most likely parallell RISC processors).":cf%=0:objp%(5)=-1:invno%=-1:ENDPROC 960 PRINT"I can't do that...YET." 970 ENDPROC 980 990 DEFPROCtrn 1000 IF objp%(8)=0 AND INSTR(a$,"oxygen")>0 AND INSTR(a$,"on")>0 PRINT FNok:oxf%=1:ENDPROC 1010 IF objp%(8)=0 AND INSTR(a$,"oxygen")>0 AND INSTR(a$,"off")>0 PRINT FNok:oxf%=0:ENDPROC 1020 PRINT"Eh?" 1030 ENDPROC 1040 1050 DEFPROCdg 1060 IF cpos%<22 PRINT"Not here.":ENDPROC 1070 ENDPROC 1080 1090 DEFPROCet 1100 IF wf1%=0 PRINT "You're wearing a spacesuit.":ENDPROC 1110 IF objp%(6)=cpos% AND INSTR(a$,"food")>0 THEN objp%(6)=-1:invno%=-1:PRINT"Great! That was delicious.":ENDPROC 1120 IF objp%(6)=0 AND INSTR(a$,"food")>0 THEN objp%(6)=-1:invno%=-1:PRINT"Great! That was delicious.":ENDPROC 1130 PRINT"That sounds silly to me." 1140 ENDPROC 1150 1160 DEFPROCdrnk 1170 IF wf1%=0 PRINT "You're wearing a spacesuit.":ENDPROC 1180 IF objp%(10)=cpos% AND waf%=0 AND INSTR(a$,"water")>0 PRINT ics$:ENDPROC 1190 IF objp%(10)=0 AND waf%=0 AND INSTR(a$,"water")>0 PRINT ics$:ENDPROC 1200 IF objp%(10)=cpos% AND waf%=1 AND INSTR(a$,"water")>0 THEN obj$(10)="An empty bottle":waf%=0:PRINT"That was refreshening.":ENDPROC 1210 IF objp%(10)=0 AND waf%=1 AND INSTR(a$,"water")>0 THEN obj$(10)="An empty bottle":waf%=0:PRINT"That was refreshening.":ENDPROC 1220 PRINT"Eh??" 1230 ENDPROC 1240 1250 DEFPROCgo 1260 IF INSTR(a$,"hell")>0 PRINT"Not bloody likely.":ENDPROC 1270 PRINT"Go where?" 1280 ENDPROC 1290 1300 DEFPROCenter 1310 IF cpos%=1 AND INSTR(a$,"airlock")>0 AND gf3%=TRUE THEN PRINT"It's locked.":ENDPROC 1320 IF cpos%=1 AND INSTR(a$,"airlock")>0 AND gf3%=FALSE PRINTFNok:cpos%=2:PROClk:ENDPROC 1330 IF cpos%=2 AND INSTR(a$,"pod")>0 AND gf2%=TRUE THEN PRINT"There's a non-functional door blocking your movement that way.":ENDPROC 1340 IF cpos%=2 AND INSTR(a$,"pod")>0 AND gf2%=FALSE PRINTFNok:cpos%=9:PROClk:ENDPROC 1350 IF cpos%=9 AND INSTR(a$,"airlock") THEN cpos%=2:PROClk:ENDPROC 1360 IF cpos%=3 AND INSTR(a$,"airlock") THEN cpos%=2:PROClk:ENDPROC 1370 IF cpos%=10 AND INSTR(a$,"lift") THEN cpos%=11:PROClk:ENDPROC 1380 IF cpos%=15 AND INSTR(a$,"lift") THEN cpos%=14:PROClk:ENDPROC 1390 PRINT"What??" 1400 ENDPROC 1410 1420 DEFPROChnt 1430 m%=m%+1 1440 IF cpos%=3 PRINT"You gotta get outta here.":ENDPROC 1450 IF cpos%=10 PRINT"There's an access card somewhere.":ENDPROC 1460 IF cpos%=15 PRINT"The controls are not your ticket out of here.":ENDPROC 1470 IF cpos%=16 AND objp%(5)=cpos% PRINT"This room may be of some help.":ENDPROC 1480 IF cpos%=16 AND objp%(5)=0 PRINT"This room may be of some help.":ENDPROC 1490 IF cpos%=16 PRINT"This room may be of some help...but not yet.":ENDPROC 1500 PRINT FNreply 1510 ENDPROC 1520 1530 DEFPROCld 1540 PRINT"Sorry not available!" 1560 1590 ENDPROC 1600 1610 DEFPROCcb 1620 PRINT"Ahem." 1630 ENDPROC 1640 1650 DEFPROCuse 1660 PRINT"Uh?" 1670 ENDPROC 1680 1690 DEFPROCjmp 1700 PRINT"Whee!!" 1710 ENDPROC 1720 1730 DEF PROCmove 1740 IF cpos%=17 gf3%=TRUE 1750 IF pdir%(cpos%,comno%)=0 THEN PRINTnw$:ENDPROC 1760 IF cpos%=13 AND comno%=4 AND gf1%=TRUE PRINT lock$(1):ENDPROC 1770 IF cpos%=10 AND comno%=1 AND gf1%=TRUE PRINT lock$(1):ENDPROC 1780 IF cpos%=2 AND comno%=3 AND gf2%=TRUE PRINT lock$(2):ENDPROC 1790 IF cpos%=2 AND comno%=1 AND gf3%=FALSE PRINT "You have to close the outer door first.":ENDPROC 1800 IF cpos%=2 AND comno%=2 AND gf3%=TRUE PRINT "The outer airlock door is closed.":ENDPROC 1810 IF cpos%=1 AND comno%=3 AND gf3%=TRUE PRINT "The outer airlock door is closed.":ENDPROC 1820 cpos%=pdir%(cpos%,comno%) 1830 PROClk 1840 ENDPROC 1850 1860 DEF PROCdst 1870 b$=FNcase(com$(comno%)) 1880 a$=FNcase(a$) 1890 IF INSTR(a$,"the")>0 the%=4 ELSE the%=0 1900 IF objp%(2)<>0 PRINT "With what?":ENDPROC 1910 IF objp%(2)=0 AND pt%=0 PRINT"Click.":ENDPROC 1920 IF cpos%=2 AND objp%(2)=0 THEN GOTO 1990 1930 IF cpos%<>2 AND objp%(2)=0 THEN 1940 PRINT"You ";b$;" the ";RIGHT$(a$,-INSTR(a$," ")+LEN(a$)-the%);"." 1950 PRINT"Nothing special happened, but you had a lot of fun." 1960 REM pt%=0 1970 ENDPROC 1980 : 1990 IF INSTR(a$,"pod door")<>0 THEN 2050 2000 PRINT"You ";b$;" the ";RIGHT$(a$,-INSTR(a$," ")+LEN(a$));"." 2010 PRINT"Great fun. Now what are you going to use it for?" 2020 pt%=0 2030 ENDPROC 2040 : 2050 door$(5)="a free passage to the escape pod." 2060 PRINT"You ";b$;" the ";RIGHT$(a$,-INSTR(a$," ")+LEN(a$));"." 2070 PRINT"This leaves you ";door$(5) 2080 score%=score%+2 2090 pt%=0 2100 gf2%=FALSE 2110 : 2120 ENDPROC 2130 2140 DEF PROCpl 2150 IF INSTR(a$,"handle")=0 PRINT"Pull what?":ENDPROC 2160 IF cpos%<>7 PRINT "I see nothing to pull.":ENDPROC 2170 IF cpos%=7 AND hf1%=TRUE PRINT"Where? What??":ENDPROC 2180 IF cpos%=7 AND hf1%=FALSE AND hf2%=1 PRINT"Oh, something rolled out!":hf2%=0:ENDPROC 2190 PRINT"Whee!!" 2200 ENDPROC 2210 2220 DEFPROCpsh 2230 IF objp%(3)=cpos% THEN 2260 2240 IF objp%(objno%)<>cpos% AND objp%(objno%)>numobj% PRINT ics$:ENDPROC 2250 IF objp%(objno%)=cpos% AND INSTR(a$,"but")=0 PRINT "What a strange idea.":ENDPROC 2260 IF cpos%=9 AND cf%=0 PROCfinish:ENDPROC 2270 IF cpos%=9 AND cf%=1 PRINT "Strangely enough, nothing happens.":ENDPROC 2280 PRINT"What a strange idea." 2290 ENDPROC 2300 2310 DEF PROClk 2320 CLS 2330 PROCcd 2340 PRINT "You are "; 2350 PROCcheck(name$(cpos%)) 2360 IF c1%=0 PROCtime 2370 PRINT'"Evident exits are: "; 2380 FOR I%=1 TO 6 2390 IF pdir%(cpos%,I%)<>0 PRINT dir$(I%);" "; 2400 NEXT 2410 PRINT ''"You can see:" 2420 no%=0 2430 IF hf2%=1 obj$(6)=CHR$(11) 2440 FOR I%=1 TO numobj% 2450 IF objp%(I%)<>cpos% THEN 2480 2460 PRINT obj$(I%) 2470 no%=no%+1 2480 NEXT 2490 IF cpos%>=17 AND cpos%<20 OR cpos%=21 THEN PRINT"Lots of stars.":ENDPROC 2500 IF cpos%<>10 AND cpos%<>13 AND cpos%<>2 AND cpos%<>3 AND cpos%<>9 AND cpos%<>1 THEN 2570 2510 IF cpos%=10 PRINT door$(1);" north.":ENDPROC 2520 IF cpos%=13 PRINT door$(1);" south.":ENDPROC 2530 IF cpos%=2 PRINT door$(5):PRINT door$(3);" north":PRINT door$(2);" east.":PRINT"a sign.":ENDPROC 2540 IF cpos%=9 PRINT "a free passage to the airlock.":ENDPROC 2550 IF cpos%=1 PRINT door$(2);" west.":ENDPROC 2560 IF cpos%=3 PRINT door$(3);" south.":ENDPROC 2570 IF no%=0 THEN PRINT "Nothing special." 2580 ENDPROC 2590 2600 DEFPROCfinish 2610 PRINT"You firmly depress the button.":A=INKEY(50) 2620 PRINT".";:A=INKEY(50):PRINT".";:A=INKEY(50):PRINT".":A=INKEY(100) 2630 PRINT"Click.":A=INKEY(150) 2640 PRINT"You feel the force of seven G's as the escape capsule is" 2650 PRINT"jettisoned from the Gullwing." 2660 PRINT"You have escaped the Gullwing in one piece." 2670 PRINT'"Well done." 2680 GOTO 2680 2690 c1%=1 2700 ENDPROC 2710 2720 DEF PROCexa 2730 IF INSTR(a$,"sign")>0 AND cpos%=2 THEN PRINT"Try 'read'.":ENDPROC 2740 IF INSTR(a$,"drive")>0 AND cpos%=16 PRINT"This is where one puts a disc.":ENDPROC 2750 IF INSTR(a$,"door")>0 AND cpos%<>1 AND cpos%<>2 AND cpos%<>3 AND cpos%<>10 AND cpos%<>13 PRINT ics$:ENDPROC 2760 IF INSTR(a$,"door")>0 PRINT"There's nothing special about that door.":ENDPROC 2770 IF objp%(objno%)=cpos% OR objp%(objno%)=0 THEN 2790 2780 REMPRINT FNhave:ENDPROC 2790 IF objno%=1 PRINT"It has a 'T' marked on it.":ENDPROC 2800 IF objno%=2 PRINT"It looks like a Volt-Varsican hi-tech rad-welder.":ENDPROC 2810 IF objno%=3 PRINT"It doesn't seem very special to me.":ENDPROC 2820 IF objno%=4 PRINT"There's a handle on it.":hf1%=FALSE:obj$(6)="some food":ENDPROC 2830 IF objno%=5 PRINT"It looks like a 3.5 inch floppy.":ENDPROC 2840 IF objno%=9 PRINT"Complex";:PROCthink:PRINT"BIG";:PROCthink:PRINT"and it has a disc-drive mounted in it.":ENDPROC 2850 IF objno%>5 AND objno%<9 PRINT"Hmm.":ENDPROC 2860 IF objno%=10 PRINT"It's a container.":ENDPROC 2870 IF objno%=11 PRINT"Nothing special.":ENDPROC 2880 IF objno%=12 PRINT"Damaged.":ENDPROC 2890 PRINT"Please rephrase that." 2900 ENDPROC 2910 2920 DEFPROCrd 2930 IF cpos%=2 AND INSTR(a$,"sign")>0 PRINT"It says 'CAUTION: Do not exit without proper preparations.'":ENDPROC 2940 PRINT "Huh??" 2950 ENDPROC 2960 2970 DEFPROCdr 2980 IF objp%(objno%)<>0 OR objno%=0 THEN PRINT FNhave:ENDPROC 2990 objp%(objno%)=cpos% 3000 PRINT"Ok." 3010 IF objno%=7 wf1%=1:PROCcd 3020 IF objno%=8 s%=TRUE:PROCcd 3030 invno%=-1 3040 ENDPROC 3050 3060 DEFPROCwer 3070 IF LEFT$(a$,2)<>"we" comno%=3:PROCmove:ENDPROC 3080 IF objp%(objno%)<>cpos% AND objp%(objno%)<>0 PRINT ics$:ENDPROC 3090 IF objp%(7)=cpos% OR objp%(7)=0 PRINT"Ok, it takes a little time, but you manage.":wf1%=0:objp%(7)=0:invno%=invno%+1:ENDPROC 3100 IF objp%(objno%)=0 OR objp%(objno%)=cpos% PRINT "Impossible.":ENDPROC 3110 PRINT"Eh??" 3120 ENDPROC 3130 3140 DEF PROCop 3150 IF RIGHT$(a$,4)<>"door" THEN PRINT"That's impossible.":ENDPROC 3160 IF cpos%<>2 AND cpos%<>1 AND cpos%<>3 AND cpos%<>10 AND cpos%<>13 THEN PRINTics$:ENDPROC 3170 IF RIGHT$(a$,-INSTR(a$," ")+LEN(a$))="escape pod door" AND gf2%=TRUE PRINT"It won't budge.":ENDPROC 3180 IF cpos%=1 AND INSTR(a$,"outer")>0 AND gf3%=FALSE PRINT"It's open already.":ENDPROC 3190 IF cpos%=2 AND INSTR(a$,"outer")>0 AND gf3%=FALSE PRINT"It's open already.":ENDPROC 3200 IF cpos%=10 AND gf1%=FALSE PRINT"It's open already.":ENDPROC 3210 IF cpos%=13 AND gf1%=FALSE PRINT"It's open already.":ENDPROC 3220 IF cpos%=1 AND INSTR(a$,"outer")>0 PRINT FNok'"You wait until the air is out of the airlock. The outer door then opens.":gf3%=FALSE:ENDPROC 3230 IF cpos%=2 AND INSTR(a$,"outer")>0 PRINT FNok'"Before the outer door openes, the inner door closes. You can feel the":PRINT"humming as air gets sucked out of the compartment. It then opens to a":PRINT"myriad of stars.":gf3%=FALSE:PROCcd:ENDPROC 3240 IF cpos%=2 AND INSTR(a$,"inner")>0 PRINT "No need.":ENDPROC 3250 IF cpos%=3 AND INSTR(a$,"inner")>0 PRINT "It's open already.":ENDPROC 3260 IF cpos%=10 AND objp%(1)<>0:PRINT "You need something to open it with.":ENDPROC 3270 IF cpos%=13 AND objp%(1)<>0:PRINT "You need something to open it with.":ENDPROC 3280 IF cpos%=10 AND objp%(1)=0:PRINT "The door opens with a swish.":gf1%=FALSE:ENDPROC 3290 IF cpos%=13 AND objp%(1)=0:PRINT "The door opens with a swish.":gf1%=FALSE:ENDPROC 3300 PRINT"I can understand the first part, but I have trouble with the object." 3310 ENDPROC 3320 3330 DEF PROCcl 3340 IF RIGHT$(a$,4)<>"door" THEN PRINT"That's impossible.":ENDPROC 3350 IF cpos%<>2 AND cpos%<>1 AND cpos%<>3 AND cpos%<>10 AND cpos%<>13 THEN PRINTics$:ENDPROC 3360 IF cpos%=10 AND objp%(1)=0 AND gf1%=TRUE PRINT"It's locked already.":ENDPROC 3370 IF cpos%=13 AND objp%(1)=0 AND gf1%=TRUE PRINT"It's locked already.":ENDPROC 3380 IF (cpos%=2 OR cpos%=3) AND INSTR(a$,"inner")>0 PRINT"It closes automatically, so there's no need.":ENDPROC 3390 IF (cpos%=2 OR cpos%=1) AND INSTR(a$,"outer")>0 PRINT FNok'"You close the outer airlock door.":gf3%=TRUE:ENDPROC 3400 IF cpos%=10 AND objp%(1)=0 PRINTFNok'"You close the door.":gf1%=TRUE:ENDPROC 3410 IF cpos%=13 AND objp%(1)=0 PRINTFNok'"You close the door.":gf1%=TRUE:ENDPROC 3420 PRINT"What?" 3430 ENDPROC 3440 3450 DEF PROCinv 3460 PRINT'"You are carrying: "; 3470 IF invno%=0 THEN PRINT n$:ENDPROC 3480 PRINT 3490 FOR I%=1 TO numobj% 3500 IF objp%(I%)=0 PRINT obj$(I%);:IF objp%(7)=0 AND wf1%=0 AND I%=7 PRINT" (which you are wearing)"; 3510 IF objp%(I%)=0 PRINT 3520 NEXT 3530 ENDPROC 3540 3550 DEF PROChlp 3560 PRINT"I am provided with a limited understanding of certain words," 3570 PRINT"actions, objects and places. However, most of my vocabulary" 3580 PRINT"describes the different parts of the world you wander in, and" 3590 PRINT"is used to move you there. Try words like north, south, east," 3600 PRINT"west, up, down, get and drop." 3610 PRINT"The directions can be abbreviated to n,s,e,w,u and d respectively." 3620 ENDPROC 3630 3640 DEF PROCq 3650 INPUT"Do you really want to quit already",b$ 3660 IF LEFT$(b$,1)="y" OR LEFT$(b$,1)="Y" THEN INPUT'"Really End or Restart",b$ ELSE ENDPROC 3670 b$=FNcase(b$) 3680 RESTORE 3690 IF LEFT$(b$,1)="r" THEN 5120 ELSE END 3700 ENDPROC 3710 3720 DEFPROCcheck(A$) 3730 IF INSTR(A$,"/")=0 PRINTA$: ENDPROC 3740 PRINTLEFT$(A$,INSTR(A$,"/")-1) 3750 PRINTRIGHT$(A$,-INSTR(A$,"/")+LEN(A$)) 3760 ENDPROC 3770 3780 DEFPROCthink 3790 A=INKEY(70) 3800 PRINT"."; 3810 A=INKEY(70) 3820 PRINT"."; 3830 A=INKEY(70) 3840 PRINT"."; 3850 A=INKEY(70) 3860 ENDPROC 3870 3880 DEF PROCg 3890 IF RIGHT$(a$,4)=" all" PROCquest:ENDPROC 3900 IF INSTR(a$,"sign")>0 AND cpos%=2 PRINT"It's here to warn people, and should not be removed.":ENDPROC 3910 IF objno%=0 PRINT "What a strange idea.":ENDPROC 3920 IF objp%(objno%)<>cpos% PRINT ics$:ENDPROC 3930 IF objp%(objno%)=0 PRINT "You have it already.":ENDPROC 3940 IF objno%=9 THEN PRINT "It has a mass equal to 3.6 tons, and is also mounted to the floor.":ENDPROC 3950 IF objno%=12 THEN PRINT "They're stuck.":ENDPROC 3960 IF objno%=3 THEN PRINT "Funny.":ENDPROC 3970 IF objno%=4 THEN PRINT FNss:ENDPROC 3980 IF hf2%=1 AND INSTR(a$,"food")>0 PRINT ics$:ENDPROC 3990 IF invno%=invmax% THEN PRINT"You carry too much already.":ENDPROC 4000 objp%(objno%)=0 4010 PRINT FNget 4020 invno%=invno%+1 4030 ENDPROC 4040 4050 DEF PROCquest 4060 PRINT "One at a time, please." 4070 ENDPROC 4080 4090 DEF PROCcd 4100 IF cpos%=1 AND s%=TRUE PRINT '"You forgot something."'ds$(1)'ds$(2):PROCscre:END 4110 IF cpos%=2 AND gf3%=FALSE AND s%=TRUE PRINT '"You forgot something."'ds$(1)'ds$(2):PROCscre:PROCplayagain 4120 IF cpos%>16 AND cpos%<22 AND s%=TRUE PRINT '"You forgot something."'ds$(1)'ds$(2):PROCscre:PROCplayagain 4130 ENDPROC 4140 4150 DEFPROCplayagain 4160 INPUT'"Do you want to play again?"q$ 4170 IF LEFT$(q$,1)="Y" OR LEFT$(q$,1)="y" THEN RUN ELSE END 4180 ENDPROC 4190 4200 DEF FNcomno(b$) 4210 cn%=0 4220 FOR I%=1 TO numcom% 4230 IF b$=LEFT$(com$(I%),LEN(b$)) THEN cn%=I% 4240 NEXT 4250 IF LEFT$(a$,2)="n" THEN cn%=1 4260 IF LEFT$(a$,2)="e" THEN cn%=2 4270 IF LEFT$(a$,2)="w" THEN cn%=3 4280 IF LEFT$(a$,2)="s" THEN cn%=4 4290 IF LEFT$(a$,2)="u" THEN cn%=5 4300 IF LEFT$(a$,2)="d" THEN cn%=6 4310 =cn% 4320 4330 DEF FNobjno(b$) 4340 on%=0 4350 FOR I%=1 TO numobj% 4360 IF b$=LEFT$(object$(I%),LEN(b$)) on%=I% 4370 NEXT 4380 =on% 4390 4400 DEF FNcase(b$) 4410 c$="" 4420 FOR I%=1 TO LEN(b$) 4430 B%=ASC(MID$(b$,I%,1)) 4440 IF B%>64 AND B%<91 THEN B%=B%+32 4450 c$=c$+CHR$(B%) 4460 NEXT 4470 =c$ 4480 4490 DEF FNok 4500 ON RND(3) GOTO 4510,4520,4530 4510 ="Ok." 4520 ="Everything you say." 4530 ="Right." 4540 4550 DEF FNhuh 4560 ON RND(5) GOTO 4570,4580,4590,4600,4610 4570 ="What?" 4580 ="Rephrase that, please." 4590 ="I don't understand that word." 4600 ="Huh??" 4610 ="That word isn't in my vocabulary. Try something else." 4620 4630 DEF FNss 4640 ON RND(3) GOTO 4650,4660,4670 4650 ="You can't be serious." 4660 ="Loonatic." 4670 ="Don't try to be funny. I mean, a 160 pound object??" 4680 4690 DEF FNss1 4700 ="Don't be ridiculous." 4710 4720 DEF FNget 4730 ON RND(2) GOTO 4740,4750 4740 ="I have it now." 4750 ="Got it." 4760 4770 DEF FNreply 4780 ON RND(3) GOTO 4790,4800,4810 4790 ="Think for yourself." 4800 ="Do something useful." 4810 ="Not bloody likely." 4820 4830 DEF FNhave 4840 ON RND(3) GOTO 4850,4860,4870 4850 ="I can't see that here, or on your person." 4860 ="I think there's some misunderstanding here." 4870 ="Where? What?" 4880 4890 DEFPROCsetvar 4900 REM IF M%<>9 THEN *SLOAD .Oldsprt 4910 REM MODE 12 4920 REM VDU 23,0,10,%1100000| 4930 VDU 28,0,30,79,16 4940 VDU 24,0;512;1279;1023; 4950 REM *SCHOOSE TITLESPRITE 4960 PLOT &ED,0,522 5020 CLS 5030 W=0 5040 m%=0 5050 locs%=21 5060 numobj%=12 5070 numcom%=42 5080 DIM name$(locs%),pdir%(locs%,6) 5090 DIM obj$(numobj%),object$(numobj%) 5100 DIM com$(numcom%),objp%(numobj%) 5110 DIM dir$(6),door$(5),lock$(2),ds$(2) 5120 invno%=0 5130 score%=0 5140 invmax%=6 5150 cpos%=3 5160 cf%=1 5170 c1%=0 5180 gf1%=TRUE 5190 gf2%=TRUE 5200 gf3%=TRUE 5210 hf1%=TRUE 5220 s%=TRUE 5230 oxf%=0 5240 hf2%=1 5250 wf1%=1 5260 waf%=1 5270 pt%=1 5280 ds$(1)="You try to breathe, but only vacuum enters your lungs." 5290 ds$(2)="It seems to me that you are dead." 5300 door$(1)="an electric door with a card slot, to the" 5310 door$(2)="the outer airlock door, to the" 5320 door$(3)="the inner airlock door, to the" 5330 door$(5)="a non-fuctional escape pod door, to the west." 5340 lock$(1)="The door is locked." 5350 lock$(2)="The door to the escape pod is barred somehow." 5360 nw$="You can't go that way." 5370 ics$="I can't see that here." 5380 n$="Nothing." 5390 M%=9 5400 ENDPROC 5410 5420 DATA "on the outside of Gullwing. This used to be a lifeboat bay,/though there is no lifeboat here now." 5430 DATA "in the only airlock the Gullwing has." 5440 DATA "standing in the entrance hallway of the Gullwing./To the south you see an airlock, and to the north there is a junction." 5450 DATA "at a junction in the middle of the ship." 5460 DATA "in a small hall east of the junction. The crew's quarters are/to the south, and you can also see an all-to familiar locker to the east." 5470 DATA "in the crew's recreation room. Scarcly decorated as it is, it does not/appeal to you. However, through a porthole, you can see a planet." 5480 DATA "in the galley. This looks like the most cramped place in the whole/ship." 5490 DATA "in an emormous locker. It looks strangely familiar." 5500 DATA "sitting inside an escape pod. You have a great view at the stars/from here." 5510 DATA "in the forward-most part of a long hallway. Further north there is/a door marked 'Toolshop'. To the east there is a lift." 5520 DATA "inside a lift. It looks like it has been used quite a few times." 5530 DATA "in a small, dirty, and foul-smelling chamber which looks like it/has been used by four crew members." 5540 DATA "standing in a toolshop. Like the other places on the Gullwing, it is/small, and contains little." 5550 DATA "standing in a lift which shows you the bridge to the west." 5560 DATA "on the bridge. It looks like hell here. The controls are all bent/or otherwise damaged." 5570 DATA "in the mainframe computer room. A small humming escapes from/the machinery placed around the premises." 5580 DATA "drifting aimlessly in space." 5590 DATA "drifting aimlessly in space." 5600 DATA "drifting aimlessly in space." 5610 DATA "at the external emergency point, which actually is nothing more than/a spot on the outside of the ship where there is a hook." 5620 DATA "drifting aimlessly in space." 5630 DATA 0,17,2,0,0,0, 3,1,9,0,0,0, 4,0,0,2,0,0, 10,5,6,3,0,0, 0,8,4,12,0,0 5640 DATA 0,4,0,7,0,0, 6,0,0,0,0,0, 0,0,5,0,0,0, 0,2,0,0,0,0, 13,11,0,4,0,0 5650 DATA 0,0,10,0,14,0, 5,0,0,0,0,0, 0,0,0,10,0,0, 0,0,15,0,0,11, 16,14,0,0,0,0 5660 DATA 0,0,0,15,0,0, 18,17,1,17,17,17, 18,19,18,18,18,18, 20,19,19,21,19,19 5670 DATA 0,0,0,19,0,0, 21,21,17,21,21,21 5680 DATA an access card,a laser powertorch,a red button,a food dispenser,a diskette,some food,a spacesuit,an oxygen tank,a big mainframe computer,a bottle of fresh water,water,some damaged controls 5690 DATA card,powertorch,button,dispenser,diskette,food,spacesuit,oxygen,computer,bottle,water,controls 5700 DATA north,east,west,south,up,down,get,take,drop,open,close,hit,kill,push,insert,pull,dig,light,turn,eat,drink,swallow,enter,go,inventory,look,help,hint,quit,examine,read,climb,use,jump,load,save,destroy,burn,incinerate,blast,wear,score 5710 DATA 20,13,9,7,6,7,8,12,16,7,-1,15 5720 DATA north,east,west,south,up,down