relations.t file | source file

RELATIONS EXTENSION by Eric Eve July 2014

The relations.t extension allows Inform7-style relations to be defined in a TADS 3 game.

Summary of Classes

`Relation VerbRule(ListRelations) VerbRule(RelationDetails)`

Summary of Global Objects

`DerivedRelation ListRelations RelationDetails relationPathfinder relationTable`

Summary of Global Functions

`relate related relationPath unrelate`

Global Functions

`relate (a, rel, b)` | `relations.t[587]`

Make a related to b via the rel relation. The rel parameter can be specified either as an object (in which case its the relevant relation object) or as a single-quoted string (in which cast it's either the name or the reverseName of a relation object.

PART OF THE RELATIONS EXTENSION

`related (a, rel, b?)` | `relations.t[662]`

If two arguments are supplied (e.g. related(a, knows)) returns a list of items related to a via the rel relation. If three arguments are supplied (e.g. related(a, knows, b)) then return true if a is related to b via the knows relation and b otherwise.

PART OF THE RELATIONS EXTENSION

`relationPath (start, rel, target)` | `relations.t[837]`

Find a path from start to target via the rel relation, where rel can be a single relation or a list of relations, and can be specified either via a relation object name or a string name (or reverseName). We provide this as a convenient wrapper for the more verbose method call.

PART OF THE RELATIONS EXTENSION.

`unrelate (a, rel, b)` | `relations.t[623]`

Remove the rel relation between a and b

PART OF THE RELATIONS EXTENSION

Adv3Lite Library Reference Manual
Generated on 08/12/2025 from adv3Lite version 2.2.2