[Date Prev][Date Next][Thread Prev][Thread Next][Author Index][Date Index][Thread Index]
Re: [zzdev] Re: Named primitives (was: Re: [zzdev] I cannot compile!)
- To: Tuomas Lukka <lukka@xxxxxxxxxxx>
- Subject: Re: [zzdev] Re: Named primitives (was: Re: [zzdev] I cannot compile!)
- From: Benjamin Fallenstein <b.fallenstein@xxxxxx>
- Date: Sat, 26 Aug 2000 23:55:34 +0200
- Cc: ZZ Development <zzdev@xxxxxxxxxx>
- References: <Pine.HPP.3.96.1000826235421.25435G-100000@xxxxxxxxxxxxxxx>
Tuomas Lukka wrote:
> > P.P.S. Oh yes: Of course scripting engines should subclass ZZCommand so
> > that scripts can be called as usual UI callbacks. If we change the ZOb
> > interface a bit, this could also be used for inter-language calls. -b.
By having a readParams method which takes a number of parameters as well
as a cell. That is, we pass a hashtable whose keys are structparam
identifiers and whose values are values for the structparams. readParams
then first reads the params from the structure (if not null, of course),
and then reads the params from the hashtable (that way, a param in the
hashtable can "override" a param in the structure).
A scripting language can then represent the params in any format it desires.
BTW: With this system, the dir action storing could work as follows:
- calling the dir action without a direction clones it next to the dir
- calling the cursor move action looks next to the dir action cell for
an action to execute (just as it does now), and then calls that action,
overriding the direction structparam.