Section - Discovering Tchotchkes
[Warning; Don't ever call a kind of thing "tchotchkes." It's too hard to spell.]
The tchotchke discovered is a thing that varies. The tchotchke discovered is the void. [Just a dummy item.]
First after when a visible insignificant tchotchke is nearish the noun or a visible insignificant tchotchke is nearish the second noun:
if a random chance of 1 in 3 succeeds:
let L be the list of visible insignificant tchotchkes that are nearish the noun;
add the list of visible insignificant tchotchkes that are nearish the second noun to L;
sort L in random order;
now the tchotchke discovered is entry 1 of L;
now the tchotchke discovered is significant;
say the discovery text for the tchotchke discovered;
continue the action.
First before when the noun is an insignificant tchotchke (called the discovery): now the discovery is significant. [If the player's already messing around with something we don't want it to be discovered.]
First before when the second noun is an insignificant tchotchke (called the discovery): now the discovery is significant.
To say the discovery text for (item - a thing):
say "While [the current action] you notice [an item][vicinity text for the item]."
To say the discovery text for (item - Complete Poems of Elizabeth Bishop): say "There's Lily's Elizabeth Bishop book[vicinity text for the Complete Poems of Elizabeth Bishop]."
To say the discovery text for (item - Lily's wallet): say "Lily's wallet is[if the vicinity of Lily's wallet is the void] there[otherwise][vicinity text for Lily's wallet][end if], lying open to display her UWM ID. Her stare is grave, her hair pulled back."
To say the discovery text for (item - koosh): say "There's a koosh right there!"
To say the discovery text for (item - rice cooker): say "You bump up against the rice cooker[vicinity text for the rice cooker]."
To say the discovery text for (item - chopster): say "You almost knock the rubber seal from Chopster down. It's drying[vicinity text for the Chopster] with all the rest of the Chopster pieces."
To say vicinity text for (item - a thing):
if the item is on the vicinity of the item or the vicinity of the item is the floor:
say " on [the vicinity of the item]";
otherwise if the item is in the vicinity of the item:
say " in [the vicinity of the item]";
otherwise if the vicinity of the item is the void:
do nothing;
otherwise:
say " near [the vicinity of the item]"