Re: ALAN - '$INCLUDE'


Sun, 27 Aug 1995 22:06:54 EDT

dgcarlyl@freenet.vancouver.bc.ca (Dennis Carlyle) says:
>... so then Mark "Mark" Sachs said ...
>>> Could someone explain to me how the $INCLUDE directive is supposed
>>> to work in ALAN?
>> Real simple. Let me just crack open the source code for the endlessly
>> delayed, half-mythical "A Day in the Life..."

> Which is? Would this be a text adv. in ALAN?

Indeed! Long-delayed, unfortunately, as I haven't had time to do the
last ten percent or so. Not to mention debugging. I shouldn't have
promised in XYZZY NEWS that it'd be out by summer...

> Thanks for the reply re: $include. More on that later, but first ...
> thanks also for the 'etudes' available in the archive. Any examples are
> of help when you're new to both the language, and IF coding in general.
> Nice to see FLOYD FROM PLANETFALL again too. (capitalized for the person
> asking about the same thing in Inform.)

Hey, you're welcome! It just seemed that there ought to be _something_
up there. Coding Floyd up was great fun, too. I wish I had something to
use him in; it seems a shame that he'll just wander between the Robot
Room, the Waiting Room and the Seenik Overluuk forever...

[me, on $include:]
>> i.e. you can't define a whole batch of objects and then $include a file
>> full of synonym definitions,

> But you could (define + synonym + syntax) different verbs in different
> files, as long as all the necessary definitions for a particular verb are
> in the same file, right?

Hmm, can you? I was under the impression that order was highly important
to the ALAN compiler. Say, I'll just check right now...

You're right! While synonym definitions, verb definitions, syntax... et
cetera order can't be shuffled within a single file, or at least can only
be shuffled to a very limited extent, each file in a group of $included
stuff can have all those elements.

Actually, though, I wouldn't be surprised if there's the odd hairy exception,
so for now I'll stick with the method I'm using. (If anyone's curious,
that is to have all verb/syntax definitions in one file, then all "abstract"
elements such as functions and inventories in another, then several files
each with the object and location definitions for a chunk of the game,
and finally a file for the start section. It keeps things nicely organized
and makes it easier to ensure you don't have duplicate definitions anywhere.)

--
                    I've gone to build the Supercollider.
 <*> mbs110@psuvm.psu.edu: Mark Sachs, Itinerant Graphicist and Webmaster <*>
   Visit the Penn State Data Center Home Page! http://www.hbg.psu.edu/psdc/