User Tools

Site Tools


en:kingdom_of_craal

KINGDOM OF CRAAL

Info

Author Mike Noels
Computer Amstrad PCW 8256 / 8512 / 9512
Year 1987
Gender Conversational
Controls Keyboard
Languages English
State Preserved

Screenshots

Description

Far away, beyond the Ice Mountains, lies the weird and wonderful Kingdom of Craal with its magnificent palace and enchanted forest.

It is a peaceful land, ruled for many happy years by King Meek, respected by most of his subjects.

However, there was one character who was not part of this overwhelming admiration: Vadham, the evil wizard.

Many years ago, he was banished to the castle dungeons for trying to steal the king's gold-plated dagger.

In his spare time when he wasn't mixing spells or playing with potions, he turned the dungeon into a labyrinth of despair, where only the brave had the courage to enter.

You were born in Craal the handsome son of a cobbler and many years ago decided to seek your fortune in distant lands.

You have returned many times over the years to visit your elderly parents and sometimes spend happy time in the company of the king's daughter, Andrea.

Unfortunately, on this last visit you found the king dead and the palace in an uproar.

The wizard had seized a heaven-sent opportunity, and when the king opened the dungeon door to let Moggie out of the castle, he seized his magnificent golden crown and disappeared into his hiding place in the depths.

You, with your typical youthful attitude, were only interested in your future wife, Andrea. The palace guards, footmen, courtesans, and even Ethel the cleaner, however, were not impressed with her services in retrieving the crown.

You were thrown headlong down the dungeon steps with the warning that if you return empty handed you will lose all your cherished possessions.

In this serious adventure you have at your disposal six commands of a single letter. These are n,s,e,w,l and i — for the four compass directions, look and inventory respectively.

The program will also accept other standard quest commands, such as grab, drop, hit, and say. These words are clever, meaning that if you have a key and you want it in a lock, all you need to say is 'let go of the key'. It will automatically enter the lock.

Now it doesn't make much sense for you to write an adventure and find, as you do, all the solutions within the list. So to hide the hints I have written the important messages in code and they are all in the data declarations at the end of the program.

There's nothing clever about what I've done, and I'm sure you'll soon find that all the printed text has been shifted by three letters. The subroutine starting at line 530 decodes it all and converts it to sensible English with the finished product.

It is imperative that you take great care when entering these lines of data if you want to enjoy the result of your efforts.

Listing

  • Listing - KC.BAS
10 REM           By Mike Noels
20 REM (c) Computing With The Amstrad
30 REM PCW
40 DEFINT a-z:PRINT CHR$(27);"E";CHR$(27)"H":GOTO 180 
50 DIM d(10,4)
60 h$=SPACE$(25):c$=h$:o$=h$:h$="":c$="":o$=""
70 hh$=SPACE$(255):oo$=h$:hh$="":oo$=""
80 FOR i=1 TO 10: FOR j=1 TO 4
90 READ d(i,j)
100 NEXT:NEXT
110 n=12:t=7:m=51
120 DIM j$(n):DIM o(n):DIM m$(m)
130 FOR i=1 TO n:READ hh$:READ cc$:GOSUB 530:j$(i)=oo$:hh$=cc$:GOSUB 530:o(i)=VAL(oo$):NEXT
140 FOR i=1 TO m:READ m$(i):NEXT
150 h$="":c$="":o$=""
160 b=-1:d=-1:e=-1:s=0:l=0:a=-1:g=0:ff=-1
170 r=2:x=3:GOTO 250
180 PRINT"On a visit to the palace of Craal, you find the place in uproar. The king is dead and his"
190 PRINT"crown stolen by a wicked wizard who's fled to his den in the palace dungeons. By paying"
200 PRINT"rather too much attention to the ex-king's daughter, you find yourself volunteered to"
210 PRINT"recover it.":PRINT
220 PRINT "You are thrown into the dungeons and told not to come back without the crown."
230 PRINT:PRINT "Here begins the adventure....":PRINT
240 GOTO 50
250 WHILE NOT g
260 IF r<>x THEN GOSUB 610
270 x=r:c=0:WHILE c=0:GOSUB 380:WEND
280 ON c GOSUB 810,850,880,930,1090,610,1000,960,1030,1180
290 WEND
300 PRINT
310 IF o(8)=1 THEN GOTO 330 ELSE m=31:GOSUB 2160
320 m=32:GOSUB 2160:PRINT:GOTO 350
330 m=29:GOSUB 2160:PRINT
340 m=30:GOSUB 2160:END
350 PRINT:m=51:GOSUB 2160
360 a$="":WHILE a$="":a$=INKEY$:WEND
370 a$=UPPER$(a$):IF a$="N" THEN END ELSE RUN
380 PRINT:PRINT"What now?"
390 c$="":WHILE c$="":INPUT "===>",c$:WEND:c$=LOWER$(c$)
400 IF LEN(c$)<>1 THEN 420
410 c=INSTR("nsewil",c$): IF c<>0 THEN RETURN ELSE PRINT"I don't recognise this single letter command - only n,s,e,w,i,l.":RETURN
420 sx=INSTR(c$," "): IF sx=0 THEN PRINT "I don't understand - put a space between command and object, please.":c=0:RETURN
430 verb$=LEFT$(c$,SX-1):o$=" "+MID$(c$,SX+1):WHILE LEFT$(o$,1)=" ":o$=RIGHT$(o$,LEN(o$)-1):WEND
440 c=INSTR("droptakesayhit",verb$)
450 IF c<>1 AND c<>5 AND c<>9 AND c<>12 THEN PRINT"I don't understand your command.":c=0:RETURN
460 IF c=1 THEN c=7 ELSE IF c=5 THEN c=8 ELSE IF c=12 THEN c=10 ELSE IF c=9 THEN RETURN 
470 z=0:i=1:m=0:WHILE m<>1 AND i<>n+1 
480 IF LEFT$(o$,4)=LEFT$(j$(i),4) THEN m=1
490 i=i+1
500 WEND
510 IF m=1 THEN z=i-1 ELSE PRINT"I don't understand the object you mean.":c=0:RETURN
520 RETURN
530 oo$=""
540 FOR jj=1 TO LEN(hh$)
550 rr=ASC(MID$(hh$,jj,1))-3
560 IF rr=38 OR rr=41 OR rr=34 THEN rr=rr+3
570 oo$=oo$+CHR$(rr) 
580 NEXT
590 RETURN
600 END
610 in=-1:m=r-1:GOSUB 2110
620 PRINT:PRINT:PRINT"You can see around you :-"
630 f=0
640 FOR i=1 TO n
650 IF o(i)<>r THEN 670 ELSE f=-1
660 GOSUB 1400 
670 NEXT
680 IF NOT f THEN PRINT"Nothing of interest."
690 PRINT
700 RETURN
710 DATA 0,0,0,0 
720 DATA 3,9,0,0 
730 DATA 0,2,4,0 
740 DATA 0,0,5,3
750 DATA 0,0,0,4
760 DATA 0,7,0,0
770 DATA 6,0,0,8
780 DATA 0,0,7,9
790 DATA 2,0,8,0
800 DATA 0,0,0,0
810 IF d(r,1)=0 THEN PRINT" Not allowed":PRINT:RETURN
820 IF r=7 AND a THEN m=33:GOSUB 2160:PRINT:RETURN
830 r=d(r,1)
840 RETURN
850 IF d(r,2)=0 THEN PRINT" Not allowed":PRINT:RETURN
860 r=d(r,2)
870 RETURN
880 IF d(r,3)=0 THEN PRINT" Not allowed":PRINT:RETURN
890 IF d(r,3)=8 AND ff THEN m=34:GOSUB 2160:ff=0
900 IF d(r,3)=7 AND o(7)=0 THEN o(7)=8:m=35:GOSUB 2160:PRINT
910 r=d(r,3)
920 RETURN
930 IF d(r,4)=0 THEN PRINT" Not allowed":PRINT:RETURN
940 r=d(r,4)
950 RETURN
960 IF o(z)=1 THEN PRINT"You already have it":RETURN
970 IF o(z)<>r THEN PRINT"It's not here":RETURN
980 IF z<t THEN PRINT"You can't take that" ELSE o(z)=1
990 RETURN
1000 IF o(z)=1 THEN o(z)=R ELSE PRINT "You don't have it":RETURN
1010 ON (r-1) GOSUB 1250,1270,1260,1310,1260,1260,1330,1260,1260
1020 RETURN
1030 h$="":FOR i=LEN(o$) TO 1 STEP -1 
1040 h$=h$+MID$(o$,i,1)
1050 NEXT
1060 IF o$=h$ THEN g=-1:m=50:GOSUB 2160:RETURN
1070 PRINT"Okay,"+CHR$(34)+o$+CHR$(34) 
1080 RETURN
1090 PRINT"Your inventory contains:-" 
1100 f=0
1110 FOR i=t TO n
1120 IF o(i)<>1 THEN 1140 ELSE f=-1 
1130 GOSUB 1400
1140 NEXT
1150 IF NOT f THEN PRINT"Nothing at all."
1160 PRINT
1170 RETURN
1180 IF o(z)<>r THEN PRINT"It wasn't here to hit":RETURN
1190 IF o(11)<>1 THEN m=36:GOTO 2160 
1200 IF z<>6 AND z<>3 THEN PRINT"This has no effect whatsoever."
1210 IF z=6 AND a THEN a=0:m=37:GOSUB 2160:PRINT:o(6)=0:RETURN
1220 IF z=3 AND s=0 THEN m=38:GOSUB 2160:s=-1:o(8)=2:RETURN
1230 IF z=3 AND s=-1 THEN m=39:GOTO 2160 
1240 RETURN
1250 IF z=8 AND e THEN m=40:GOSUB 2160:o(z)=0:e=NOT e:o(11)=1
1260 RETURN
1270 IF z=7 AND NOT b AND l THEN m=41:GOSUB 2160:PRINT:l=0
1280 IF z=9 THEN m=42:GOSUB 2160:o(z)=0:o(12)=3
1290 IF z=10 THEN d=0
1300 RETURN
1310 IF o(7)=5 AND o(12)=5 THEN m=43:GOSUB 2160:b=0:o(12)=0:o(7)=1
1320 RETURN
1330 IF z<>10 THEN 1370
1340 IF d THEN m=44:GOSUB 2160:GOTO 350 
1350 IF (NOT l) OR (o(7)<>8 AND o(7)<>1) THEN m=45:GOSUB 2160:GOTO 350
1360 IF o(2)=0 THEN m=46:GOSUB 2160:o(1)=0:o(2)=8:o(8)=8
1370 IF z=7 AND NOT b THEN l=-1:m=47:GOSUB 2160:PRINT
1380 IF z=9 OR z=12 THEN m=48:GOSUB 2160:PRINT:m=49:GOSU6 2160:GOTO 350
1390 RETURN
1400 IF i=1 THEN m=10:GOSUB 2110
1410 IF i=2 THEN m=11:GOSUB 2110
1420 IF i=3 AND NOT s THEN m=12:GOSUB 2110
1430 IF i=3 AND s THEN m=14:GOSUB 2110 
1440 IF i=4 THEN m=15:GOSUB 2110:m=16:GOSUB 2160:m=17:GOSUB 2160
1450 IF i=5 THEN m=18:GOSUB 2110
1460 IF i=6 THEN m=19:GOSUB 2110
1470 IF i=7 AND NOT b AND NOT l THEN m=21:GOSUB 2110
1480 IF i=7 AND NOT b AND l THEN m=22:GOSUB 2110
1490 IF i=7 AND b THEN m=23:GOSUB 2110 
1500 IF i=8 THEN m=20:GOSUB 2110
1510 IF i=9 THEN m=24:GOSUB 2110
1520 IF i=10 AND d THEN m=25:GOSUB 2110 
1530 IF i=10 AND NOT d THEN m=28:GOSUB 2110
1540 IF i=11 AND NOT a THEN m=26:GOSUB 2110
1550 IF i=11 AND a THEN crip$="a "+j$(i):PRINT crip$
1560 IF i=12 THEN m=27:GOSUB 2110
1570 PRINT
1580 RETURN
1590 DATA iluh,;,sloh#ri#dvkhv,3,yhqglqj#pdfklqh,5,pluuru,9,wuroo,8,gzdui,":",odps,3,frlq,3,sdufkphqw,7,fxuwdlq,<,vzrug,3,yrxfkhu,3
1600 DATA "d#udwkhu#vsduvh,#xqiulhqgo#urrp#zlwk#wkh#dssduhqwo#lqh{solfdeoh#vljq#########*Duprxu*#rq#wkh#zdoo1"
1610 DATA "d#ydvw#fdyhuq#zlwk#d#odujh#srro#ri#zdwhu1#D#sdwk#ohdgv#dorqj#lwv#hgjh1"
1620 DATA "dq#h{wuhpho#wljkw,#Hdvw#0#Zhvw#wxqqho1"
1630 DATA "d#vkrs1#Ryhu#wkh#frxqwhu#lv#dvljq=#Hehqhh}hu*v#Hqwhusulvhv1"
1640 DATA "d#vpdoo#fkdpehu,#lwv#zdoov#lulghvfhqw#zlwk#vsdunolqj#fuvwdov,#vdyh#rqh1"
1650 DATA "d#udwkhu#jorrp#fdyh,#uhplqlvfhqw#ri#rog#plqh#zrunlqjv1"
1660 DATA "zkdw#orrnv#olnh#d#khuplw*v#fhoo1"
1670 DATA "dq#rog#gluw#fkdpehu#wkdw#orrnv#wr#kdyh#ehhq#sloodjhg#orqj#djr1"
1680 DATA "wkh#zl}dug*v#fkdpehu1#Dv#qr#rqh#kdv#hyhu#vxuylyhg#wklv#h{shulhqfh,#wkhuh#lv#qr##h{wdqw#ghvfulswlrq1111"
1690 DATA "exuqlqj#eulooldqwo#lq#d#fruqhu1"
1700 DATA "qrz#txlwh#frro1"
1710 DATA "zlwk#d#qrwlfh#*qr#krw#prqh#ru#frxqwhuihlw#frlqv*1"
1720 DATA "zlwk#d#qrwlfh#*hpsw*#rq#lw1" 
1730 DATA "lq#elwv#rq#wkh#iorru1"
1740 DATA "hqjudyhg="
1750 DATA "*Vd#pluuru#zrug#wr#zl}dug#phhw,"
1760 DATA "Eh#vxuh#rx#kdyh#wkh#jrog#wr#juhhw1*"
1770 DATA "zlwk#d#exvlqhvv#olnh#dlu1"
1780 DATA "zhdulqj#gdun#jodvvhv1"
1790 DATA "zruwk#lwv#zhljkw#lq#jrog1" 
1800 DATA "qrw#hw#olw1"
1810 DATA "exuqlqj#euljkwo1"
1820 DATA "lq#d#udwkhu#edwwhuhg#frqglwlrq1"
1830 DATA "gu#dv#d#erqh#dqg#frpsohwho#eodqn1"
1840 DATA "lq#txlwh#jrrg#frqglwlrq#0#dqg#qrw#dw#doo#gdps1"
1850 DATA "fryhuhg#lq#eorrg1"
1860 DATA "uhdglqj=#H{fkdqjh#wklv#yrxfkhu#wrjhwkhu#zlwk#dq#rog#odps#dqg#rx*oo#jhw#d#qhz###odps#iuhh$"
1870 DATA ",#zulqjlqj#zhw1"
1880 DATA "Wkh#zl}dug*v#hhv#oljkw#xs1#Kh#wdnhv#rxu#frlq#wr#ex#klpvhoi#d#gulqn#dqg#################glvdsshduv1"
1890 DATA "\rx#sxw#rq#wkh#furzq#kh*v#ohiw#ehklqg#dqg#ilqg#rxuvhoi#edfn#lq#wkh#sdodfh,#Nlqj#ri#Fuddo,dqg#kdss#hyhu#diwhu1"
1900 DATA "Rk#ghdu,#rx*yh#jrw#qr#prqh#0#dqg#wkh#zl}dug#zdv#krslqj#rx*g#ex#klp#d#slqw#ru#wzr1"
1910 DATA "Qdwxudoo#kh#nloov#rx1"
1920 DATA "Wkh#gzdui#uhixvhv#wr#ohw#rx#sdvw1"
1930 DATA "D#zrug#wr#wkh#zlvh=#\rx*uh#jrlqj#wr#wkh#rqo#urrp#lq#wkh#sodfh#zlwkrxw#lwv#rzq#qdwxudo####skrvskruhvfhqfh1" 
1940 DATA "Dq#ludwh#gzdui,#lqixuldwhg#e#wkh#oljkw#rx*yh#ohw#lq,#wkurzv#klv#xqolw#odps#dw#rx1#Lw###odqgv,#lq#wkh#urrp#rx*yh#mxvw#ohiw,#vkdwwhuhg1"
1950 DATA "\rx#kdyhq*w#jrw#dqwklqj#ghfhqw#wr#klw#zlwk1#Jhw#d#vzrug1"
1960 DATA "Wkh#gzdui#idoov#ghdg,#wkhq#glvdsshduv#lq#iurqw#ri#rxu#hhv1"
1970 DATA "Wkh#yhqglqj#pdfklqh#vkdwwhuv1#D#frlq#gursv#rxw1"
1980 DATA "Judwxlwrxv#ylrohqfh#grhvq*w#khos#dqrqh1"
1990 DATA "Wkh#frlq#idoov#lqwr#wkh#vorw#lq#wkh#yhqglqj#pdfklqh1#\rx#duh#jlyhq#d#vzrug1#Wkdw*v#zk####lw*v#fdoohg#wkh#Duprxu$"
2000 DATA "Xqiruwxqdwho,#rxu#odps#jrhv#rxw1"
2010 DATA "Lqwhuhvwlqj$#Vrphwklqj*v#kdsshqlqj#wr#wkh#sdufkphqw1#Wdnh#d#orrn1111" 
2020 DATA "\rx*yh#jrw#d#qhz#odps$"
2030 DATA "Wkh#fxuwdlq#ioduhv#xs1#\rx#glh#lq#wkh#eod}h1"
2040 DATA "Wdnlqj#dgydqwdjh#ri#wkh#vxgghq#soxqjh#lqwr#gdunqhvv,#wkh#gzdui#iurp#ch{w#grru#frphv#lq#dqgsrolvkhv#rx#rii1" 
2050 DATA "Wkh#iluh#jrhv#rxw1#\rx#vhh#d#frlq#lq#lwv#dvkhv1"
2060 DATA "\rxu#odps#oljkwv1"
2070 DATA "Lw#exuvwv#lqwr#iodph$"
2080 DATA "\rx#vxgghqo#uhdolvh#wkdw#lw#zdv#ylwdo#wr#wkh#jdph1#Ryhufrph#zlwk#julhi,#rx#nloo#########rxuvhoi1"
2090 DATA "Wkh#pluuru#glvvroyhv#dqg#rx#ilqg#rxuvhoi#sxoohg#wkurxjk#wkh#jds#lw*v#ohiw#lqwr#wkh######zl}dug*v#urrp1" 
2100 DATA "Zkdw#d#vkdph#0#dqg#rx#zhuh#grlqj#vr#zhoo#wrr1#Gr#rx#zdqw#dqrwkhu#jrB#+|2Q)"
2110 hh$=m$(m):GOSUB 530
2120 crip$="You are in "+oo$:IF in THEN PRINT:PRINT crip$;
2130 IF NOT in THEN crip$="a "+j$(i)+" "+oo$:PRINT crip$
2140 in=0
2150 RETURN
2160 hh$=m$(m):GOSUB 530:PRINT:PRINT oo$ 
2170 RETURN
 in THEN crip$="a "+j$(i)+" "+oo$:PRINT crip$
2140 in=0
2150 RETURN
2160 hh$=m$(m):GOSUB 530:PRINT:PRINT oo$ 

Controls

       N = NORTH
       S = SOUTH
       E = EAST
       W = WEST
       L = OBSERVE
       I = INVENTORY
       TAKE, JUMP, HIT, SAY...

Loading the program

 1.- Insert the CP/M disc on side 2
 2.- Write BASIC and wait for it to load
 3.- Remove the CP/M disk and insert the disk containing the Kingdom of Craal game
 4.- Type run "KC" and press the "ENTER" key

Extras

  • Listing of the program in a large-circulation magazine of the time

kingdom_of_craal_01.jpg kingdom_of_craal_02.jpg

Download

en/kingdom_of_craal.txt · Last modified: 2022/06/29 01:19 by jevicac