:: StoryTitle At the Duchess's Party :: StoryData { "ifid": "BE18C022-A213-466C-8DD1-DCCD5CB1DF48" } :: Story JavaScript [script] Config.passages.nobr = true; // Deal with linebreaks. State.variables.playerKnowledge = {poetry: 0, industry: 0, astronomy: 0}; State.variables.characters = [ { name: "Arabella Armstrong", poetry: 3, industry: 0, astronomy: 0 }, { name: "Blake Brookhaven", poetry: 0, industry: 3, astronomy: 0 }, { name: "Claudio Croix", poetry: 0, industry: 0, astronomy: 3 } ] StoryManager.storylets["Conversation"] = { name: "Conversation", tags: ["circulating"], generate: function() { let storylets = []; for (let i in State.variables.characters) { let character = State.variables.characters[i]; let storylet = { passage: "Conversation", description: "Talk to " + character.name, priority: 0, character: character } storylets.push(storylet); } return storylets; } }; StoryManager.storylets["Buttonholed"] = { name: "Buttonholed", tags: ["circulating"], generate: function() { if (Math.random() < 0.2) { let char = randomChoice(State.variables.characters); return [{ passage: "Being approached", description: "You see " + char.name + " approaching you.", interrupt: true, character: char }] } } }; StoryManager.storylets["Conversation topic"] = { name: "Conversation topic", tags: ["during conversation"], generate: function() { let storylets = []; for (let topic in State.variables.playerKnowledge) { if (State.variables.playerKnowledge[topic] > 0 | State.variables.currentStorylet.character[topic] > 0) storylets.push({ passage: "Conversation topic", description: "Talk about " + topic, priority: 0, topic: topic }) } return storylets; } }; :: Start You stand at the edge of the grand ballroom in the Duchess's palace.
<> <> :: Conversation <> You talk with $talkingTo.name.
<> <> [[Keep circulating | Start]] :: Being approached $currentStorylet.character.name is coming toward you to talk.
You can [[talk to them | Conversation]], or risk snubbing them by [[trying to get away | Start]]. :: Conversation topic <>