Newsgroups: rec.arts.int-fiction
Path: news.duke.edu!newsgate.duke.edu!nntp-out.monmouth.com!newspeer.monmouth.com!newsswitch.lcs.mit.edu!world!not-for-mail
From: buzzard@TheWorld.com (Sean T Barrett)
Subject: Re: [TADS3] Organizing NPC knowledge
Sender: news@world.std.com (Mr Usenet Himself)
Message-ID: <GuqsHG.19G@world.std.com>
Date: Thu, 18 Apr 2002 02:34:27 GMT
References: <ubqua4a82mlq4b@corp.supernews.com> <a_iv8.13$ao6.62@news.oracle.com> <ubrs3onuv5fb58@corp.supernews.com> <SBmv8.31$ao6.258@news.oracle.com>
Nntp-Posting-Host: shell01.theworld.com
Organization: The World Public Access UNIX, Brookline, MA
X-Newsreader: trn 4.0-test72 (19 April 1999)
Lines: 27
Xref: news.duke.edu rec.arts.int-fiction:103427

Mike Roberts <mjr-SEENOTE@hotmail.com> wrote:
>"Phil Lewis" <phillewis@remove_this.fuse.net> wrote:
>> > > modify Actor
>> > >     knowledgeTab = static new LookupTable();
>>
>> Can't I just drop the 'static', which was the real problem?
>
>Unfortunately, that won't do what you want either -
>
>modifyActor
>  knowledgeTab = (new LookupTable());
[which creates one every time it's called]

Wasn't there some ugly little hack you can do, along
the lines of (forgive me for forgetting Tads3 syntax):

modify Actor
   knowledgeTab() { return (self.knowledgeTab = new LookupTable()); }

I seem also to recall discussion on the tads3 list about how
to create objects which had instance variables that had other
objects in them, one per object; was there some syntax to allow
defining such objects, not using new, but filling out the
object description or something? I guess that still wouldn't
generalize to non-object types.

SeanB
