[I7] Understanding a property as one of its properties

This is probably self-explanatory:

[code]The materials are defined by the Table of Materials.

Table of Materials
material material-adjective destroying heat heat-behaviour corrosion resistance
iron “iron” 10 melter 995
wood “wooden” 3 burner 970
adamant “adamantine” 999 melter 1000

Understand the material property as describing a thing.
Understand the material-adjective property as describing a material.[/code]
I want the player to be able to refer to things made of wood by typing “wooden”, and so on, but Inform doesn’t allow the final line of code. Of course, I can just write a series of understand phrases. (Understand “wooden” as wood.) No problem, except that it would be somewhat ugly, because I am now defining the adjective twice. So mostly out of curiosity and perfectionism: is there a way to use my table for understanding?

What happens when you remove the quotes so they’re no longer text strings, but another KOV instead? (It’ll require another “Some… are defined by…” line.) Or if that doesn’t work since “defined by” requires the first column, a 2nd table with the 2nd KOV in the first column, in the same order as the first table.

Also, can you understand “[the material-adjective corresponding to…]” as a thing? I cannot remember.

I would love it if KOVs could be created at the time of assignment! Even something like this would be great:

[code]A material is a kind of value. Unknown stuff is a material.

A thing has a material called the composition.

The composition of the toy sword is wood.[/code]

Something like[code][Setup]
There is a room.
Heat-behavior is a kind of value. The heat-behaviors are melter and burner.
A material is a kind of thing.
Some materials are defined by the Table of Material Properties.

[Table]
Table of Material Properties
material material-adjective (indexed text) destroying heat heat-behaviour corrosion resistance
iron “iron” 10 melter 995
wood “wooden” 3 burner 970
adamant “adamantine” 999 melter 1000

[Subkind]
A material thing is a kind of thing.
Every material thing has a material called the substance.

[Intermediate Relation]
Constitution relates a material thing (called the item) to a material (called the substance) when the substance is the substance of the item.

[Understanding]
Understand “[something related by constitution]” as a material thing. [Understanding by relation for understanding things as things.]
Understand the material-adjective property as describing a material. [Understanding by property for understanding other understandable values as things.]

[Demo]
A shield is a kind of material thing. The substance of a shield is usually iron.
A staff is a kind of material thing. The substance of a staff is usually wood.
A ring is a kind of material thing. The substance of a ring is usually adamant.
Here are a shield, a staff, and a ring.
Test me with “x wooden/x iron/x adamantine”.[/code] perhaps?

2 Likes