Alabaster — 15 of 123

John Cater, Rob Dubbin, Eric Eve, Elizabeth Heller, Jayzee, Kazuki Mishima, Sarah Morayati, Mark Musante, Emily Short, Adam Thornton, and Ziv Wities

Release 1

Chapter 6 - Removable aspect of building dot - Not for release

[A quip can be dotted or undotted. A quip is usually undotted.

Fact-revelation relates various quips to various facts. The verb to fact-reveal (it fact-reveals, they fact-reveal, it fact-revealed, it is fact-revealed) implies the fact-revelation relation.

Establishing relations is an activity.

Rule for establishing relations:

now generic-quip does not fact-reveal anything;

now generic-quip does not quip-trigger anything;

repeat with item running through quips:

change current quip to item;

say "[comment of item][response of item][paragraph break]";

now the player does not know anything. [This is because some quips use if clauses to present facts if the player missed seeing them elsewhere; we want to find all of these connections.]

Rule for printing the name of a fact (called target) while establishing relations:

now the current quip fact-reveals the target.

Carry out building dot:

carry out the establishing relations activity;

say "digraph Conversation {[line break]";

now every quip is undotted;

pre-color nodes;

pre-color facts;

repeat with item running through shallowly-buried quips:

dot-tree item;

say "}".

A quip has some indexed text called the node-name.

To pre-color nodes:

repeat with node running through quips:

let N be indexed text;

let N be "[node]";

let word count be the number of punctuated words in N;

let line number be the word count divided by 3;

if line number is greater than 1:

let source be indexed text;

let source be "[N]";

let N be "";

let running total be 0;

let current line be 0;

while running total is not greater than word count:

repeat with index running from 1 to 3:

increase running total by 1;

if running total is not greater than word count:

let N be "[N][punctuated word number running total in source]";

if index is not 3:

let N be "[N] ";

if running total is less than word count:

let N be "[N]\n";

change node-name of the node to "[N]";

say "'[node-name of node]' ";

if node is NPC-directed and node is restrictive:

say "[bracket]color = 'deeppink' fillcolor = 'deeppink' shape = 'box'[close bracket]";

otherwise if node is NPC-directed:

say "[bracket]color = 'gray' fillcolor = 'gray' shape = 'box'[close bracket]";

otherwise if node is restrictive:

say "[bracket][if the node is not directly-followed by anything]color = 'crimson' fillcolor = 'crimson'[otherwise]color = 'deeppink' fillcolor = 'deeppink'[end if][close bracket]";

otherwise if node is binary-answering and the node directly-follows a restrictive quip:

say "[bracket]color = 'gray50' fillcolor = 'gray50'[close bracket]";

otherwise if node is unlisted:

say "[bracket]color = 'ghostwhite' fillcolor = 'ghostwhite'[close bracket]";

otherwise:

say "[bracket]color = 'gray' fillcolor = 'gray'[close bracket]";

say "; [line break]";

To pre-color facts:

repeat with relevant fact running through facts:

say "'[relevant fact]' [bracket]color = 'palegreen' fillcolor = 'palegreen' shape = 'diamond'[close bracket]; [line break]";

To pre-color subjects:

repeat with relevant subject running through things which are mentioned by a quip:

if the relevant subject is a subject:

say "'[relevant subject]' [bracket]color = 'palegoldenrod' fillcolor = 'palegoldenrod' shape = 'circle'[close bracket]; [line break]";

otherwise:

say "'[relevant subject]' [bracket]color = 'orangered' fillcolor = 'orangered' shape = 'circle'[close bracket]; [line break]"; [1]

To dot-tree (node - a quip):

if node assumes something:

repeat with relevant fact running through facts which are assumed by node:

say "'[relevant fact]' -> '[node-name of node]'; [line break]";

if node fact-reveals something:

repeat with relevant fact running through facts which are fact-revealed by node:

say "'[node-name of node]' -> '[relevant fact]' [bracket]color = 'palegreen'[close bracket]; [line break]";

if node quip-triggers something:

repeat with relevant quip running through quips which are quip-triggered by node:

say "'[node-name of node]' -> '[node-name of relevant quip]' [bracket][if the relevant quip is postponed obligatory or the relevant quip is immediate obligatory]color = 'deeppink'[otherwise]color = 'gray'[end if][close bracket]; [line break]";

repeat with offspring running through undotted quips which indirectly-follow node:

say "'[node-name of node]' -> '[node-name of offspring]' [if offspring directly-follows node][bracket]color = 'deeppink'[close bracket][end if]; [line break]";

if every quip which is indirectly-followed by offspring is dotted:

now offspring is dotted; [2]

dot-tree offspring;

Carry out building subject dot:

say "digraph Subjects {[line break]";

now every quip is undotted;

pre-color nodes;

pre-color subjects;

repeat with node running through quips:

if node mentions something:

repeat with relevant subject running through things which are mentioned by the node:

say "'[node-name of node]' -> '[relevant subject]'; [line break]";

say "}".]

Notes

[1]. These will be physical objects in the game world; they may be equally numerous but will probably tie into fewer quips.

[2]. This is necesssary because it is actually possible (though uncommon) for a quip to follow more than one other quip.