Right now I have a "Table of Equippable Hats" and I'm defining the
hats in the game world (off-stage) by invoking "some hats are defined
by the Table of Equippable Hats". I'd like to be able to generate,
say, 20 of each hat and move them to the player as needed.
I have a feeling I cannot do this, though.
Hm, I was pretty sure this is covered in the docs, but I can't seem to
find it. Ch. 15.15 mentions that "... we can define many similar things
(or kinds) using a table," but doesn't give the syntax for kinds. At any
rate, the syntax you're looking for is "some kinds of ... are defined by
the Table ..."
[code]
A hat is a kind of thing. It is always wearable.
Some kinds of hats are defined by the Table of Equippable Hats.
Table of Equippable Hats
hat description
fedora "It looks like a fedora."
cap "It's a typical baseball cap."
Lab is room. Three fedoras and two caps are in the lab.
[/code]
Note that you can still create unique instances as well:
[code]A cap called the Orioles cap is in the lab. The description is
"It's an Orioles cap."[/code]
Just remember not to get yourself into disambiguation trouble with names
of duplicate instances of the kind and unique instances. In other words,
watch out for:
>x cap
Which do you mean, a cap or the Orioles cap?
Skinny Mike
That works? I tried... I'm guessing my syntax was off, and my source
code is becoming huge now. I'll try again...thank you!
Thank you SO much. Perfect. This makes my life tons easier.