LOST BUILDS · Unreleased Game Archive

Issue 004: Double Density ·

WORKSHOP 01

BASIC.EXE — Write Here. Run on DOS.

10 PRINT

Most computers of the early 1980s greeted you with a prompt and a blinking cursor waiting for a line number. A lot of people learned to program because there was nothing else on the screen.

BASIC.EXE puts that back. Press F6, pick it from UTILITIES, and you get an editor, a cursor and a dialect line that reads, in full, LOST BASIC — GW-BASIC 3.23 subset (text mode and CGA SCREEN 1). Type a numbered program. Press F5. It runs.

10 CLS
20 INPUT "WHAT IS YOUR NAME"; N$
30 PRINT "HELLO, "; N$; ". THE DISK IS READY."
40 END

That is the whole ceremony.

A small, strict BASIC

LOST BASIC is a subset of one specific interpreter, Microsoft's GW-BASIC 3.23, the one that came with so many IBM compatibles, and it is strict about what it accepts. Programs are numbered, the way they were. There is PRINT and INPUT, GOTO and GOSUB, FOR and NEXT, arrays, strings and INKEY$ for reading the keyboard without stopping, on an 80 × 24 text screen.

And there is a picture. SCREEN 1 is the CGA's 320 × 200 four-color mode, with PSET, LINE and its boxes, CIRCLE, POINT and COLOR. The colors are the ones the hardware gave you, black, cyan, red and white, and the slightly sour look of them is the point.

What is left out is left out on purpose. PAINT, DRAW, GET and PUT, sound and the other screen modes are refused before a program runs, and CHECK PROGRAM explains each refusal with its line number, rather than letting a program half work.

Twelve disks in the drawer

FILE > EXAMPLES... holds twelve programs to start from. Some are lessons; some play. SKYWAY.BAS is an endless pseudo-3D city flight between blocks of buildings under a striped sun, all of it lines and boxes. BREAKOUT.BAS is sixty bricks, a paddle and three lives. DONKEY.BAS is a two-lane road and some donkeys you would rather not meet. Every one is plain numbered BASIC that you can read, change and break.

Write here. Run on DOS.

This is the part that matters most, and it is worth being exact about.

A program in BASIC.EXE is a real .BAS file, in the plain ASCII form a DOS machine expects. Every program in LOST BASIC's test collection, and the first six examples, was saved from BASIC.EXE and run unchanged in genuine GW-BASIC 3.23 on an emulated IBM PC with a CGA card, and its screen was compared with BASIC.EXE's, character by character and pixel by pixel. The DOS runs found thirteen real differences, from the way a circle is rasterized to how a half pixel rounds, and every one was fixed. SKYWAY.BAS was flown there too: it loaded, the arrows moved the craft, and Q landed it.

So BASIC.EXE now says it out loud: Write here. Run on DOS. It says the limits in the same paragraph, and so should we. RND gives different numbers on DOS. The last digit of SIN, EXP and LOG can differ. On an EGA or VGA card SCREEN 1 shows other colors. The newer arcade examples, BREAKOUT and DONKEY among them, were not run on DOS. And none of this was a physical PC. The promise covers LOST BASIC, not every GW-BASIC program ever typed in.

Why it matters

Until now, everything on drive L: was something to look at. BASIC.EXE is the first program in the archive that makes something you can take away and run on a machine decades older than the one you wrote it on. The archive is no longer only a place where old software is kept. It is a place where new old software can be written.

Programs run in a sealed sandbox with no network, and STOP, Ctrl+Break or Esc ends a runaway loop at once.

FIELD TEST. Open SKYWAY.BAS, change the line that sets FRAMEDELAY, and press F5 to see what the pause is for. Then save it to the computer. If you have a DOS machine or an emulator, set FRAMEDELAY to 0 as its REM lines say, type GWBASIC SKYWAY.BAS, and fly the same city on the other side of thirty years.