JustPaste.it
User avatar
@anonymous · May 14, 2024

TS1000 Dragon's Gold...

overlaycamera_apr092024_182018.png

 

From: Chuck Darling

May 14th, 2024

Early Timex Sinclair

BASIC game...

The Computer Language

BASIC was created in 1964 by

screenshot_202405141408222.png

The game: Dragon's Gold

was written for the

Timex-Sinclair Computer

by D.C. Owen  in 1982...

 

From: Chuck

May 14, 2024

Re: Basic ...

 

Back in the mid 60's, John Kemeny wrote a language

Similar to Fortran,

but more basic.

 

It didn't require all the

complex Format statements

used in Fortran.

 

It was the beginning of

"User Friendly" computing.

 

Basic was available on

all the Mainframe platforms

of the later '60s,

And all of the MiniComputer

Platforms.

 

When Altair made the first

personal computer kit,

Bill Gates wrote Basic for it.

 

All the 8-bit computers of

the late '70s and '80s

came with a version of BASIC.

 

When IBM decided to build

"The Peanut"

The original IBM PC,

they enlisted Bill Gates

to write BASIC for it...

 

Why...?

 

Well, there was no software

available for it, or for ANY of 

the early personal computers,

so USERS had to write their

own...

 

And the most widespread

common language was BASIC.

 

Now, each version of BASIC

for each of the "early PC's"

was slightly different...

 

 

Back around 1980...

when Personal Computers

began to appear...

They were all a little different.

 

But they had this in common:

 

They all included a version

of 

 

I looked through about five

"Online Basic Interpreters"

and most of them are junk.

 

The link above actually works,

though I had to convert the

Classic Basic REM statements

into PRINT statements...

 

Timex Sinclair Basic

was quite different from

"Standard Basic"

 

The TS-1000 came with

only 2 kilobytes of RAM memory.

 

The Keyboard was unique.

A membrane (touch-screen-like)

Keyboard, that included all

the TOKENIZED BASIC commands, as single keypresses. 

This made spelling errors impossible, and allowed direct

insertion of pixelated graphic

squares, direct from the Keyboard !

 

The functionality of the Basic

was pretty advanced, allowing

Real and Integer Numbers,

and String operations.

 

Like the twisty spaghetti code

of the original Fortran Adventure

program, TS-1000 Basic allowed

Gosubs, and calculated GOTOs,

as well as peeks and pokes.

 

Machine Language programs

were available in SYNC Magazine, and Timex-Sinclair User.

 

Books of TS-Basic programs

were popular, before the

Commodore-64, and the

IBM-PC took over...

 

This kind of programming

is built this way, because

of the small amount of memory

that was available for those

systems.

 

The program below would

fit and run on a

2K timex-sinclair!

 

 

Try pasting the

Timex Sinclair 1000

Dragon's Gold game into

 

(perhaps you can "debug" it !)

 

 

REM DRAGON'S GOLD

REM The aim of Dragon's

REM Gold is simple: to

REM accumulate as

REM much gold as possible, REM while wandering  

REM through a complex

REM maze of tunnels, caves,

REM and doors, and to avoid

REM the dragon and  

REM mineshafts. 

REM You enter A to move ahead,

REM L to move left, 

REM or R to move right.

REM Entering a space before

REM pressing ENTER will

REM cause the game to stop. REM Dragon's Gold was 

REM written by D. C. Owen.

 

1 REM DRAGONS GOLD

REM BY D COWEN 1982

3 RAND

5 LET G=0

50 SCROLL

51 SCROLL

52 SCROLL

55 SCROLL

55 PRINT TAB 8; "DRAGON'S GOLD"

56 SCROLL

57 SCROLL

58 SCROLL

60 PRINT "YOU HAVE: -"

65 SCROLL

70 PRINT G" BLOCKS OF GOLD"

80 SCROLL

90 SCROLL

100 PRINT "AHEAD OF YOU IS A"

120 GOSUB 1000

125 LET B$=A$

127 SCROLL

130 PRINT "ON THE LEFT IS A"

140 GOSUB 1000

145 SCROLL

150 LET L=A$

155 PRINT "AND ON THE RIGHT IS A:"

160 GOSUB 1000

165 LET R$=A$

170 SCROLL

171 SCROLL

472 PRINT "WHICH WAY DO YOU WANT TO GO?"

173 SCROLL

174 SCROLL

175 PRINT "A - AHEAD"

176 SCROLL

177 PRINT "L- LEFT-

178 SCROLL

179 PRINT "R = RIGHT

180 INPUT KS

185 SCROLL

186 SCROLL

190 IF K$="A" AND BS="D" THEN GOSUB 2000

200 IF K$="R" AND RS="D" THEN GOSUB 2000

210 IF K$="A" AND BS="T" THEN G0SUB 3000

220 IF K$="L" AND L$="T" THEN GOSUB 3000

230 IF K$="R" AND RS="T" THEN G0SUB 3000

240 IF K$="A" AND BS="C" THEN GOSUB 4000

250 IF K$="L" AND LS="C" THEN G0SUB 4000

260 IF K$="R" AND RS="C" THEN G0SUB 4000

270 IF NOT (K$="L" OR K$="R" OR K$="A") THEN GOTO 170

280 GOTO 50

990 REM ***************

REM SUB 1000 RANDOM GOTO

1000 GOTO 1000+INT (RND #3+1) +100

REM ************

1100 PRINT " DOOR"

1110 LET As="D"

1120 RETURN

1200 PRINT

TUNNEL"

1210 LET A$="T"

1220 RETURN

1300 PRINT " CAVE"

1310 LET A$="C"

1320 RETURN

1999 REM *****

2000 REM DOOR *******

2010 GOTO 2000+INT (RND+4+1) +100

2100 PRINT "IT IS LOCKED. MOVE ON"

REM ************

2110 RETURN

2200 LET 0 INT

(RND+9+1) +100

2210 PRINT "IT WILL OPEN. THERE"

2215 SCROLL

2220 PRINT "ARE ";0;" GOLD BLOCKS IN HERE"

2230 LET G=G+0

2240 RETURN

2300 PRINT "THERE IS A LAKE HERE

YOU"

2305 SCROLL

2310 PRINT "CANNOT SEE THE FAR S

IDE."

2315 SCROLL

2320 PRINT "ARE YOU GOING TO TRY

2330 SCROLL

2340 PRINT "AND CROSS IT?"

2345 SCROLL

2350 INPUT CS

2350 SCROLL

2370 IF CODE (C$) <>CODE "Y" THEN RETURN

2380 LET KINT (RND+3)+1

2381 SCROLL

2382 IF K=

THEN PRINT "YOU HAVE

ESCAPED WITH"

2383 SCROLL

2384 IF K=2 THEN PRINT G;" BLOCKS OF GOLD™

2385 IF K2 THEN PRINT "UNFORTU

NATELY, YOU HAVE"

2388 SCROLL

2390 IF K<>2 THEN PRINT TAB 10;"

DROWNED..

2395 STOP

2400 LET KINT (RND+9+1) +50

2405 SCROLL

2410 PRINT "THIS ROOM CONTAINS A

DRAGON"

2415 SCROLL

2420 PRINT "IT DEMANDS ";K;" GOLD BLOCKS"

2425 SCROLL

2430 PRINT " OR IT WILL EAT YOU"

2440 FOR J=1 TO 20

2450 SCROLL

2460 PRINT TAB J; "STAND BY"

2470 NEXT

2475 SCROLL

2480 IF G>K THEN PRINT "YOU HAVE ENOUGH"

2485 SCROLL

2490 IF G<K THEN PRINT

"YOU HAVEN'T GOT"

2495 SCROLL

2500 IF G<K THEN PRINT"ENOUGH SO...BYE BYE"; END

2510 LET G=G-K

2520 RETURN

2999 REM #****** *** **

3000 REM * * TUNNEL

3025 SCROLL

3010 IF RND >0.85 THEN RETURN

3015 SCROLL

3020 PRINT "YOU HAVE ESCAPED"

3040 STOP

3030 PRINT "WTH ";G; " GOLD BL0CKS

3999 REM #****** *****

4000 REM ** CAVE **

4005 SCROLL

4120 RETURN

4010 GOTO 4000+INT (RND #3+1) *100

4100 PRINT"THE CAVE IS EMPTY."

4105 SCROLL

4110 PRINT TAB 8; "MOVE ON"

4215 SCROLL

REM * * '...BUT Y.

4200 LET 0=INT RND#10+1) *100

4210 PRINT "THERE ARE ";0;" GOLD BLOCKS"

4230 LET G=G+9

4240 RETURN

4220 PRINT "HERE TO ADD TO YOUR STORE"

4301 FOR H=1 TO 24

4305 SCROLL

4300 IF RND>0.9 THEN GOTO 4400

4307 NEXT H

4310 PRINT "OH NO"

4315 SCROLL

4320 FOR J=1 TO 15

4330 PRINT TAB 2+J;"

4335 SCROLL

4340 NEXT J

4345 SCROLL

4350 PRINT "IT IS A MINESHAFT...

4355 SCROLL

4360 PRINT "YOU ARE DEAD"

4370 STOP

4400 SCROLL

4405 PRINT "THERE ARE NOISES AHEAD"

4407 SCROLL

4410 PRINT "DO YOU WANT TO INVESTIGATE?"

4420 INPUT K$

4438 IF CODE K$ < > CODE "Y" THEN RETURN

4440 GOTO 4000

 

*****

 

You should realize, of course,

that if the GRID should fail,

The Internet would be gone...

 

And you'll have to write

your own software

on any equipment that

survives..

 

 

Take advantage of the PDF

button, to save a "hard copy"

of this page...

 

[ChuckADV JpiCedar]

 

 

 

 

[ This page built with JPICedar v. j022924a Tues, 5-14-2024 Time : 11:30a]