I am currently having some difficulties with creating kinds in Inform 7 with optional parts. Specifically, consider the following situation:
A chair is a kind of enterable supporter.
A desk is a kind of supporter. A chair (called its seat) is usually a part of every desk.
TESTROOM is a room.
In TESTROOM is a desk called SEATDESK.
In TESTROOM is a desk which has no seat.
----------------------------------------
[when running]
>showme
TESTROOM - room
yourself - person
SEATDESK - desk
SEATDESK's seat (part of SEATDESK) - chair
desk which has no seat
Inform considers “desk which has no seat” as the name of a thing, rather than describing the composition of a desk.
I also tried this:
A chair is a kind of enterable supporter.
A desk is a kind of supporter. A chair (called its seat) is usually a part of every desk.
TESTROOM is a room.
In TESTROOM is a desk called SEATDESK.
In TESTROOM is a desk called STANDINGDESK. No seat is a part of STANDINGDESK.
----------------------------------------
[when running]
>showme
TESTROOM - room
yourself - person
SEATDESK - desk
SEATDESK's seat (part of SEATDESK) - chair
STANDINGDESK - desk
STANDINGDESK's seat (part of STANDINGDESK) - chair
No seat (part of STANDINGDESK)
This creates a desk with a seat anyway, and then also interprets “No seat” as the name of an additional thing.
I also tried defining an adjective to create them:
A chair is a kind of enterable supporter.
A desk is a kind of supporter.
Definition: a desk is seatful rather than seatless:
if a chair is a part of the desk, decide yes;
decide no.
A desk is usually seatful.
TESTROOM is a room.
In TESTROOM is a desk called SEATDESK.
In TESTROOM is a seatless desk called STANDINGDESK.
----------------------------------------
[compilation error]
>--> In the sentence 'a desk is seatful rather than seatless', you ask me to
arrange for something to be 'seatful' at the start of play. There are some
adjectives ('open' or 'dark', for instance) which I can fix, but others are just
too vague. For example, saying 'Peter is visible.' isn't allowed, because it
doesn't tell me where Peter is. Like 'visible', being 'seatful' is something I can
test during play at any time, but not something I can arrange at the start.
Can anyone guide me on how I can create a kind with an optional part, and then create an instance of that kind without the part? Thank you so much ![]()
EDIT: I also just tried this, unsuccessfully:
A chair is a kind of enterable supporter.
A desk is a kind of supporter. A chair (called its seat) is usually a part of every desk.
TESTROOM is a room.
In TESTROOM is a desk called SEATDESK.
In TESTROOM is a desk called STANDINGDESK. STANDINGDESK's seat is nothing.
----------------------------------------
[compilation error]
>--> The sentence 'STANDINGDESK's seat is nothing' appears to say two
things are the same - I am reading 'STANDINGDESK's seat' and 'nothing
as two different things, and therefore it makes no sense to say that one
is the other: it would be like saying that 'Adams is Jefferson'. It would
be all right if the second thing were the name of a kind, perhaps with
properties: for instance 'Virginia is a lighted room' says that something
called Virginia exists and that it is a 'room', which is a kind I know
about, combined with a property called 'lighted' which I also know about.
