[Bru-list] Last meeting

Vince M Hudd vince at softrock.co.uk
Fri Jul 1 19:58:50 BST 2011


"qUE (3rdevent.net)" <que at 3rdevent.net> wrote:

> Vince baffled us with talk of use of EVAL as a command interpreter in his
> adventure game

Well, no, not quite.

The command interpreter actually knows only a small number of commands. A
quick glance at the relevant CASE statement in the script interpreter
reveals it to be 21 - and some of those are just ignored at that stage.

However, as well as those 21 commands, every *function* available to BBC
BASIC is available to Trellis, because AFAICR everything that needs to be
evaluated in Trellis *is* evaluated - using BASIC's EVAL.

i.e. variable array indices, conditions, variable assignments.

And because of that, any FNs definied in the interpreter can also be used -
which means the range of functions can be expanded. (In fact one of the main
functions used in the script itself is just a BASIC FN: FNSaid("") to test
for particular keywords in the player's input.)

The result is that a Trellis script *looks* very BASIC-like, and is what
prompted someone (Jon Ripley, if memory serves) to make the comment that I'd
written a BASIC interpreter in BBC BASIC. (At Wakefield, three or four years
ago.) I call it TScript, not BASIC, but I can see his point. :)

-- 
Soft Rock Software:                   http://www.softrock.co.uk
Vince M Hudd:                         http://misc.vinceh.com/about-vinceh/

Cash prize for USB audio:             http://www.riscository.com/?p=261
OI! RISCOSitory - read all about it!  http://www.riscository.com/?p=248




More information about the Bru-list mailing list