Switch random choices to not clash with colors

Fix a few bugs while I'm at it.
This commit is contained in:
Howard Abrams 2025-04-16 12:43:53 -07:00
parent 7955d99a76
commit 7e28dc3a7c
10 changed files with 159 additions and 150 deletions

View file

@ -10,7 +10,7 @@ class CmdFly(Command):
Make sure you set the following properties, for instance: Make sure you set the following properties, for instance:
@set self/disappear_msg = "The wizard disappears in a puff of smoke." @set self/disappear_msg = "The wizard disappears in a puff of smoke."
@set self/reappear_msg = "A plume of [white|light blue|gray|] smoke appears... ;; When the smoke clears, a wizard [emerges|materializes]." @set self/reappear_msg = "A plume of {{white ^ light blue ^ gray ^ }} smoke appears... ;; When the smoke clears, a wizard {{emerges ^ materializes}}."
@set self/appear_delay = 3 @set self/appear_delay = 3
The last setting is the number of seconds between message segments The last setting is the number of seconds between message segments

View file

@ -23,8 +23,8 @@ class Consumable(Object):
@set berries/amount = 10 @set berries/amount = 10
# How many berries do you eat at a time: # How many berries do you eat at a time:
@set berries/eat_amount = 3 @set berries/eat_amount = 3
@set berries/eat_msg = "Sweet and slightly tart. [Delicious|Tangy|Mmmm]." @set berries/eat_msg = "Sweet and slightly tart. {{Delicious ^ Tangy ^ Mmmm}}."
@set berries/finish_msg = "Those were [delicious|great]." @set berries/finish_msg = "Those were {{delicious ^ great}}."
""" """
amount = 4 amount = 4
eat_amount = 1 eat_amount = 1
@ -73,7 +73,7 @@ class Producer(Object):
@set bush/make_verb = "pick some" @set bush/make_verb = "pick some"
# This one is optional as it defaults to Consumable: # This one is optional as it defaults to Consumable:
@set bush/make_class = "typeclasses.consumables.Consumable" @set bush/make_class = "typeclasses.consumables.Consumable"
@set bush/make_desc = "Bright red berry with flecks of [purple|violet|orange]." @set bush/make_desc = "Bright red berry with flecks of {{purple ^ violet ^ orange}}."
# How many berries are there when you pick them? # How many berries are there when you pick them?
@set bush/make_amount = 10 @set bush/make_amount = 10
@ -81,12 +81,12 @@ class Producer(Object):
@set bush/make_eat_amount = 3 @set bush/make_eat_amount = 3
# Either a single msg: # Either a single msg:
@set bush/make_eat_msg = "Sweet and slightly tart. [Delicious|Tangy|Mmmm]." @set bush/make_eat_msg = "Sweet and slightly tart. {{Delicious ^ Tangy ^ Mmmm}}."
# Or many: # Or many:
@set bush/make_eat_msgs = [ "Sweet and slightly tart.", "[Delicious|Tangy|Mmmm].", @set bush/make_eat_msgs = {{ "Sweet and slightly tart.", "[Delicious ^ Tangy ^ Mmmm}}.",
"Ooo...that one was sour.", "That was a bit ripe, but still good.", "Ooo...that one was sour.", "That was a bit ripe, but still good.",
"So sweet with a hint of [orange|maple]." ] "So sweet with a hint of {{orange ^ maple}}." ]
@set bush/make_finish_msg = "Those were [delicious|great]." @set bush/make_finish_msg = "Those were {{delicious ^ great}}."
""" """
def at_object_creation(self): def at_object_creation(self):
self.cmdset.add_default(CmdSetMakeConsumable) self.cmdset.add_default(CmdSetMakeConsumable)
@ -121,7 +121,7 @@ class Producer(Object):
# ---------------------------------------------------------------------- # ----------------------------------------------------------------------
TEACUP_DESCS = [ TEACUP_DESCS = [
"A rustic, clay teacup carefully crafted on a wheel. Beautiful [dark red|olive green|navy blue] glaze.", "A rustic, clay teacup carefully crafted on a wheel. Beautiful [dark red ^ olive green ^ navy blue}} glaze.",
"A fine example of Royal Albert teacup, sporting a design of violet azaleas. Perfect for a black tea.", "A fine example of Royal Albert teacup, sporting a design of violet azaleas. Perfect for a black tea.",
"A Wings of Grace style teacup with blue butterflies. Perfect for some Earl Grey.", "A Wings of Grace style teacup with blue butterflies. Perfect for some Earl Grey.",
"A dark brown Yixing clay teacup. Perfect for an Oolong tea.", "A dark brown Yixing clay teacup. Perfect for an Oolong tea.",
@ -211,9 +211,9 @@ class Trolley(Producer):
"aliases": ["wood", "kindling", "logs"], "aliases": ["wood", "kindling", "logs"],
})[0] })[0]
wood.location = caller wood.location = caller
caller.msg(routput("You [get|pick up|grab] " caller.msg(routput("You {{get ^ pick up ^ grab}} "
"[some wood|couple logs|a log|a few pieces of wood] " "{{some wood ^ couple logs ^ a log ^ a few pieces of wood}} "
"[from the woodbox|from the box on the hearth|for the fireplace|].")) "{{from the woodbox ^ from the box on the hearth ^ for the fireplace ^ }}."))
def do_bake(self): def do_bake(self):
""" """
@ -224,22 +224,22 @@ class Trolley(Producer):
self.db.make_name = name self.db.make_name = name
self.db.make_aliases = ["scone", "scones"] self.db.make_aliases = ["scone", "scones"]
self.db.make_desc = routput(f"A [tasty|yummy|delicious]-looking {name}") self.db.make_desc = routput("A {{tasty ^ yummy ^ delicious}}-looking {0}", name)
self.db.make_amount = 3 self.db.make_amount = 3
self.db.make_eat_amount = 1 self.db.make_eat_amount = 1
msgs = [ msgs = [
"[Delicious|Mmmm|So good|Really good].", "{{ Delicious ^ Mmmm ^ So good ^ Really good}}.",
] ]
if todays_scone.get('taste'): if todays_scone.get('taste'):
msgs += [f"You [can|] [really|] [notice|taste] the {todays_scone.get('taste')}."] msgs += [f"You {{can ^ }} {{really ^ }} {{notice ^ taste}} the {todays_scone.get('taste')}."]
if todays_scone.get('tastes'): if todays_scone.get('tastes'):
for taste in todays_scone.get('tastes'): for taste in todays_scone.get('tastes'):
msgs += [f"You [can|] [really|] [notice|taste] the {taste}."] msgs += [f"You {{can ^ }} {{really ^ }} {{notice ^ taste}} the {taste}."]
if todays_scone.get('expression'): if todays_scone.get('expression'):
msgs += [f"[Really|So] {todays_scone.get('expression')}."] msgs += [f"{{Really ^ So}} {todays_scone.get('expression')}."]
self.db.make_eat_msgs = msgs self.db.make_eat_msgs = msgs
self.db.make_finish_msg = "That was [delicious|great|really good]." self.db.make_finish_msg = "That was {{delicious ^ great ^ really good}}."
self.location.msg_contents(routput("[New|Aromatic|Fresh|Freshly baked] scones [magically|suddenly|mystically|enchantingly|] appear [on a plate|on plates|] on the trolley.")) self.location.msg_contents(routput("{{New ^ Aromatic ^ Fresh ^ Freshly baked}} scones {{magically ^ suddenly ^ mystically ^ enchantingly ^ }} appear {{on a plate ^ on plates ^ }} on the trolley."))

View file

@ -2,46 +2,46 @@
from typeclasses.objects import Object from typeclasses.objects import Object
from commands.consumables import CmdSetTeapot, CmdSetTeacup from commands.consumables import CmdSetTeapot, CmdSetTeacup
from utils.word_list import routput from utils.word_list import routput, choices
import random import random
TEA_TYPES = { TEA_TYPES = {
"black": "a rich, bold and [malty|fragrant|almost spicy] black tea", "black": "a rich, bold and {{malty ^ fragrant ^ almost spicy}} black tea",
"green": "a green tea with [grassy|floral|vanilla|vegetal] notes", "green": "a green tea with {{grassy ^ floral ^ vanilla ^ vegetal}} notes",
"oolong": "a complex and [earthy|floral] oolong", "oolong": "a complex and {{earthy ^ floral}} oolong",
"matcha": "a frothy and aromatic matcha of the most vibrant green", "matcha": "a frothy and aromatic matcha of the most vibrant green",
"white": "a subtle tea with notes of [rose|berries|chamomile flowers]", "white": "a subtle tea with notes of {{rose ^ berries ^ chamomile flowers}}",
"pu-erh": "an earthy, almost mushroom flavored, pu-erh tea", "pu-erh": "an earthy, almost mushroom flavored, pu-erh tea",
"puerh": "an earthy, almost mushroom flavored, pu-erh tea", "puerh": "an earthy, almost mushroom flavored, pu-erh tea",
"barley": "a nutty herbal infusion of barley with just a hint of smokiness", "barley": "a nutty herbal infusion of barley with just a hint of smokiness",
"chaga": "an earthy, mushroomy chaga infusion", "chaga": "an earthy, mushroomy chaga infusion",
"hibiscus": "a dark red, tart herbal infusion of roselle flowers", "hibiscus": "a dark red, tart herbal infusion of roselle flowers",
"chai": "a spicy chai tea, tempered with milk and sweetness", "chai": "a spicy chai tea, tempered with milk and sweetness",
"herbal": "an herbal infusion of [chamomile|mint|chicory root|lavender]", "herbal": "an herbal infusion of {{chamomile ^ mint ^ chicory root ^ lavender}}",
"earl": "a flowery Earl Grey tea", "earl": "a flowery Earl Grey tea",
"chamomile": "a relaxing, yet subtle infusion of chamomile flowers that makes you want to go to sleep", "chamomile": "a relaxing, yet subtle infusion of chamomile flowers that makes you want to go to sleep",
"mint": "a blend of peppermint and spearmint to create the ultimate minty herbal infusion", "mint": "a blend of peppermint and spearmint to create the ultimate minty herbal infusion",
"chrysanthemum": "a lovely, floral infusion of chrysanthemum flowers", "chrysanthemum": "a lovely, floral infusion of chrysanthemum flowers",
"dandelion": "a roasted herbal infusion of dandelions that tastes a bit like coffee", "dandelion": "a roasted herbal infusion of dandelions that tastes a bit like coffee",
"rooibos": "an almost [sweet and|] [woody|nutty|vanilla-y] rooibos herbal infusion", "rooibos": "an almost {{sweet and ^ }} {{woody ^ nutty ^ vanilla-y}} rooibos herbal infusion",
# Why limit to teas ... sure, this tea pot could make coffee ... # Why limit to teas ... sure, this tea pot could make coffee ...
} }
FILL_MSGS = [ FILL_MSGS = [
"You fill your [teacup|cup] with {1}.", "You fill your {{teacup ^ cup}} with {1}.",
"You pour [some|] {0} tea into your [teacup|cup].", "You pour {{some ^ }} {0} tea into your {{teacup ^ cup}}.",
] ]
DRINK_MSGS = [ DRINK_MSGS = [
"You take a sip of {0} tea.", "You take a sip of {0} tea.",
"You take a sip of {0} tea [in|from] your [teacup|cup].", "You take a sip of {0} tea {{in ^ from}} your {{teacup ^ cup}}.",
"You [sip|sample|drink] from your [teacup|cup].", "You {{sip ^ sample ^ drink}} from your {{teacup ^ cup}}.",
"You savor {1} in your [teacup|cup].", "You savor {1} in your {{teacup ^ cup}}.",
] ]
EMPTY_MSGS = [ EMPTY_MSGS = [
"Your [teacup|cup] is empty. Perhaps you can |gmake|n some |gtea|n?", "Your {{teacup ^ cup}} is empty. Perhaps you can |gmake|n some |gtea|n?",
"Your cup certainly doesn't runneth over, as it be quite empty.", "Your cup certainly doesn't runneth over, as it be quite empty.",
"Alas, you find your cup devoid of any sort of watery infusion.", "Alas, you find your cup devoid of any sort of watery infusion.",
"You notice your cup is empty.", "You notice your cup is empty.",
@ -63,19 +63,16 @@ class TeaCup(Object):
if amount > 0: if amount > 0:
self.db.amount = self.db.amount - self.sip_amount self.db.amount = self.db.amount - self.sip_amount
drinker.msg(routput(random.choice(DRINK_MSGS).format(tea_type, tea_details))) drinker.msg(choices(DRINK_MSGS, tea_type, tea_details))
else: else:
drinker.msg(routput(random.choice(EMPTY_MSGS).format(tea_type, tea_details))) drinker.msg(choices(EMPTY_MSGS, tea_type, tea_details))
def do_fill(self, drinker, tea_type, tea_details): def do_fill(self, drinker, tea_type, tea_details):
self.db.tea_type = tea_type self.db.tea_type = tea_type
self.db.tea_details = tea_details self.db.tea_details = tea_details
self.db.amount = self.fill_amount self.db.amount = self.fill_amount
drinker.msg(routput(random.choice(FILL_MSGS).format(tea_type, tea_details))) drinker.msg(choices(FILL_MSGS, tea_type, tea_details))
# Spam the room? Maybe not.
# self.location.msg_contents(f"{drinker.name} refills a {self.key}.",
# exclude=drinker)
class Teapot(Object): class Teapot(Object):

View file

@ -151,10 +151,10 @@ class Fish(CarriableNPC):
A visual way to delete the fish. A visual way to delete the fish.
""" """
if fisher.location == fisher.search("mp06"): if fisher.location == fisher.search("mp06"):
fisher.msg(routput("You [toss|heave|throw] the fish back into the [water|pond].")) fisher.msg(routput("You {{toss ^ heave ^ throw}} the fish back into the {{water ^ pond}}."))
fisher.msg(routput("The fish says, \"Bye for now. If you want to talk again, just drop me a line!\"")) fisher.msg(routput("The fish says, \"Bye for now. If you want to talk again, just drop me a line!\""))
else: else:
fisher.msg(routput("You [toss|heave|throw] the fish, and an eagle swoops down and snatches it. I'm sure it will carry the fish back to the pond for you.")) fisher.msg(routput("You {{toss ^ heave ^ throw}} the fish, and an {{ eagle ^ hawk }} swoops {{ down ^ }} and snatches it. I'm sure it will carry the fish back to the pond for you."))
self.delete() self.delete()
def get_name(): def get_name():
@ -166,8 +166,8 @@ class Fish(CarriableNPC):
return routput(random.choice([ return routput(random.choice([
"A walleye with big bulbous eyes that clearly doesn't get no respect.", "A walleye with big bulbous eyes that clearly doesn't get no respect.",
"A bass with amazing neck confidence giving it a most excellent head bob." "A bass with amazing neck confidence giving it a most excellent head bob."
"A rainbow trout missing the [red|yellow|green|blue] from its iridescent stripe.", "A rainbow trout missing the {{red ^ yellow ^ green ^ blue}} from its iridescent stripe.",
"A brown trout colored [red|blue|purple|orange].", "A brown trout colored {{red ^ blue ^ purple ^ orange}}.",
# "A spiny perch", # "A spiny perch",
# "A salmon", # "A salmon",
# "A pike", # "A pike",
@ -205,9 +205,9 @@ class FishingPole(Object):
else: else:
fisher.db.fishing = Fishing.CAST fisher.db.fishing = Fishing.CAST
fisher.msg(routput(random.choice([ fisher.msg(routput(random.choice([
"You cast out far into the [water|pond].", "You cast out far into the {{water ^ pond}}.",
"You cast close to the [dock|shore].", "You cast close to the {{dock ^ shore}}.",
"You cast off to the [right|left] where you [think you|] see a dark pocket.", "You cast off to the {{right ^ left}} where you {{think you ^ }} see a dark pocket.",
]))) ])))
def do_reel(self, fisher): def do_reel(self, fisher):

View file

@ -535,17 +535,16 @@ class BHB(Friendly):
case Reaction.INTERESTED: case Reaction.INTERESTED:
msg = choices(""" msg = choices("""
The beast [runs|hurries] at the stick, then looks at <you>, [wondering|curious as to|pondering] what to do with a stick the flies back to its owner. ;; The beast {{runs ^ hurries}} at the stick, then looks at <you>, {{wondering ^ curious as to ^ pondering}} what to do with a stick the flies back to its owner. ;;
The beast [rushes|runs at] the stick, and then veers off, thundering around the [field|meadow]. The stick returns to your hand. The beast {{rushes ^ runs at}} the stick, and then veers off, thundering around the {{field ^ meadow}}. The stick returns to your hand.
""") """)
self.adjust_character(thrower, 30) self.adjust_character(thrower, 30)
case _: case _:
msg = choices(""" msg = choices("""
The [big hairy|] beast [dashes|runs|jumps|leaps into the air|leaps] and [catches|snags|grabs] the stick in midair, and drops it in front of <you>. ;; The {{big hairy ^ }} beast {{dashes ^ runs ^ jumps ^ leaps into the air ^ leaps}} and {{catches ^ snags ^ grabs}} the stick in midair, and drops it in front of <you>. ;;
The [big hairy|] beast [gallops|trumbles|trots] over to the stick and [dances|prances|hops] around the stick before bringing it back to <you>. ;; The {{big hairy ^ }} beast {{gallops ^ trumbles ^ trots}} over to the stick and {{dances ^ prances ^ hops}} around the stick before bringing it back to <you>. ;;
The [big hairy|] beast [gallops|trumbles|trots] over to the stick and [dances|prances|hops] around the stick before bringing it back to <you>. ;; The {{big hairy ^ }} beast {{gallops ^ trumbles ^ trots}} over to the stick and {{dances ^ prances ^ hops}} around the stick before bringing it back to <you>.""")
""")
self.adjust_character(thrower, 10) self.adjust_character(thrower, 10)
if msg: if msg:
split_party_msg(thrower, msg) split_party_msg(thrower, msg)

View file

@ -223,19 +223,18 @@ class Books(Object):
title = random.choice(list(BOOKS.keys())) title = random.choice(list(BOOKS.keys()))
return ( return (
title, title,
routput("""a [worn|barely read|pristine copy of a|] routput("""a {{worn ^ barely read ^ pristine copy of a ^ }}
[leather-bound|] book, titled, |w{0}|n {{leather-bound ^ vellum-bound ^ }} book, titled, |w{0}|n
""".format(title)), """, title),
routput( routput(
""" """
You [open|open up|crack open] your book, entitled, You {{open ^ open up ^ crack open}} your book, entitled,
|w{0}|n, and read the {1} {2} of {3}. |w{0}|n, and read the {1} {2} of {3}.
""".format( """,
title, title,
random.choice(BOOK_EMOTIONS), random.choice(BOOK_EMOTIONS),
random.choice(BOOK_TYPES), random.choice(BOOK_TYPES),
BOOKS[title] BOOKS[title]
)
) )
) )

View file

@ -7,7 +7,7 @@ from evennia import create_script
from evennia.utils import logger, delay from evennia.utils import logger, delay
from commands.misc import CmdSetPuddle, CmdSetStick, CmdSetKnock from commands.misc import CmdSetPuddle, CmdSetStick, CmdSetKnock
from utils.word_list import routput from utils.word_list import routput, choices
from .scripts import KnockScript from .scripts import KnockScript
from .objects import Object from .objects import Object
@ -20,9 +20,9 @@ class Trinket(Object):
""" """
msgs = [ msgs = [
"You see a crystal ball. When the swirling vortex stops, It reads, '[Why not?|Don't even think about it|Maybe, maybe not|Sure, just don't tell]'.", "You see a crystal ball. When the swirling vortex stops, It reads, '{{Why not? ^ Don't even think about it ^ Maybe, maybe not ^ Sure, just don't tell}}'.",
"You find a deck of Tarot cards, but the card of Death has been replaced by a worker in an office cubical that reads, 'Mostly Death'.", "You find a deck of Tarot cards, but the card of Death has been replaced by a worker in an office cubical that reads, 'Mostly Death'.",
"You see a statue of a [black|red|yellow] dragon in the shape of a question mark. You have to ask yourself, Why?", "You see a statue of a {{black ^ red ^ yellow}} dragon in the shape of a question mark. You have to ask yourself, Why?",
"A Venus fly trap in a shell surrounded by chubby cherubs.", "A Venus fly trap in a shell surrounded by chubby cherubs.",
"You see a statue of a large rat. Did it just blink? Wow, after it ran away you think that was a rat of unusual size.", "You see a statue of a large rat. Did it just blink? Wow, after it ran away you think that was a rat of unusual size.",
"An ancient Colombian grave owl holding a sign that reads, 'Cannibals don't eat clowns? They taste funny.'", "An ancient Colombian grave owl holding a sign that reads, 'Cannibals don't eat clowns? They taste funny.'",
@ -31,7 +31,7 @@ class Trinket(Object):
"A troll doll with an outie belly button. Everyone knows that trolls are not placental mammals, but reproduce through a complex series of... wait, you haven't had this talk with your parents, yet?", "A troll doll with an outie belly button. Everyone knows that trolls are not placental mammals, but reproduce through a complex series of... wait, you haven't had this talk with your parents, yet?",
"A small statue of a flexing giant. When you push its belly, it says, 'Its not my fault I'm the biggest and the strongest. I don't even exercise.'", "A small statue of a flexing giant. When you push its belly, it says, 'Its not my fault I'm the biggest and the strongest. I don't even exercise.'",
"You see a license plate from the State of Utah that reads HEATHEN, and think, what is the significance of hens in heat? Oh, and you also think, what is a license plate doing in a fantasy game about escaping the clamors of last stage capitalism?", "You see a license plate from the State of Utah that reads HEATHEN, and think, what is the significance of hens in heat? Oh, and you also think, what is a license plate doing in a fantasy game about escaping the clamors of last stage capitalism?",
"You find a brilliant [blue|green|iridescent] scarf around a book, but as soon as you remove it, the book tries to bite you. After it chases you around the room, you double back, jump on it, breaking its spine (which is lets out a sad yelp), and wrap the scarf back around it. Maybe you've seen enough stuff on these shelves for a while.", "You find a brilliant {{blue ^ green ^ iridescent}} scarf around a book, but as soon as you remove it, the book tries to bite you. After it chases you around the room, you double back, jump on it, breaking its spine (which is lets out a sad yelp), and wrap the scarf back around it. Maybe you've seen enough stuff on these shelves for a while.",
] ]
def at_object_creation(self): def at_object_creation(self):
@ -69,7 +69,7 @@ class Wood(Object):
self.db.plural = "some logs" self.db.plural = "some logs"
self.db.desc = routput(choice([ self.db.desc = routput(choice([
"Its log, its log, it's big, it's heavy, it's wood.", "Its log, its log, it's big, it's heavy, it's wood.",
"Some [logs|wood] for the fireplace.", "Some {{logs ^ wood}} for the fireplace.",
])) ]))
@ -87,12 +87,12 @@ class Stick(Object):
if thrower.db.thrown_times == 1: if thrower.db.thrown_times == 1:
thrower.msg("The stick flies through the air, and just as you thought, it comes back to you!") thrower.msg("The stick flies through the air, and just as you thought, it comes back to you!")
else: else:
thrower.msg(routput(choice([ thrower.msg(choices([
f"Yer a wizard, {thrower.name.capitalize()}!", "Yer a wizard, {0}!",
"[Did you see that?|] It clipped the leaf on that tree before returning.", "{{Did you see that? ^ }} It clipped the leaf on that tree before returning.",
"This is a [fun|pleasant|nice] [past-time|game].", "This is a {{fun ^ pleasant ^ nice}} {{past-time ^ game}}.",
"Maybe we should get a pet [or beast|beastie] in here who would love to play.", "Maybe we should get a pet {{or beast ^ beastie ^ }} in here who would love to play.",
]))) ], thrower.name.capitalize()))
self.location.msg_contents(f"{thrower.name} throws a stick.", self.location.msg_contents(f"{thrower.name} throws a stick.",
exclude=thrower) exclude=thrower)
else: else:
@ -110,13 +110,13 @@ class Puddle(Object):
"This is great fun. You feel childish.") "This is great fun. You feel childish.")
else: else:
player.msg(routput(choice([ player.msg(routput(choice([
"You don't care [how muddy|who notices], you jump in again!", "You don't care {{how muddy ^ who notices}}, you jump in again!",
"Mud? Whatever. You [splash|jump] in[| again].", "Mud? Whatever. You {{splash ^ jump}} in {{^ again}}.",
"You splash around in the puddle.", "You splash around in the puddle.",
"You jump in the puddle again.", "You jump in the puddle again.",
"This time you dance a little as you kick up your heels.", "This time you dance a little as you kick up your heels.",
]) + " You feel " + choice([ ]) + " You feel " + choice([
"[so much|] better.", "{{so much ^ }} better.",
"carefree.", "carefree.",
"child-like and free.", "child-like and free.",
"irresponsible.", "irresponsible.",
@ -184,7 +184,7 @@ class Knocker(Object):
"Well, I suppose I could give you a |mhint|n.", "Well, I suppose I could give you a |mhint|n.",
] ]
hint_responses = [ hint_responses = [
"A hint does sound fair. [Should I|I should] come up with a |mriddle|n[|, huh]?" "A hint does sound fair. [Should I|I should] come up with a |mriddle|n{{, huh ^ }}?"
] ]
riddle_responses = [ riddle_responses = [
"Aged in barrels, smooth and neat, in a glass by the fire, I'm a treat.", "Aged in barrels, smooth and neat, in a glass by the fire, I'm a treat.",
@ -220,9 +220,9 @@ class Knocker(Object):
# A _sequence_ of responses, from what is this password business, to give me a hint, to give me the riddle ... # A _sequence_ of responses, from what is this password business, to give me a hint, to give me the riddle ...
[question_msg, Knocker_Convo.RIDDLE, [ [question_msg, Knocker_Convo.RIDDLE, [
"Nope. Would [ya|you] like another riddle?", "Nope. Would {{ya ^ you}} like another riddle?",
"You [really|] think that is the answer?", "You {{really ^ }} think that is the answer?",
"Personally, [|I think] that riddle could not [be|have been] more clear." "Personally, {{I think ^}} that riddle could not {{be ^ have been}} more clear."
], None], ], None],
[yes_msg, Knocker_Convo.HINT, riddle_responses, Knocker_Convo.RIDDLE], [yes_msg, Knocker_Convo.HINT, riddle_responses, Knocker_Convo.RIDDLE],
["riddle", Knocker_Convo.ANY, riddle_responses, Knocker_Convo.RIDDLE], ["riddle", Knocker_Convo.ANY, riddle_responses, Knocker_Convo.RIDDLE],
@ -249,8 +249,8 @@ class Knocker(Object):
"I'm hanging on a door? Really? Let's see, can I roll my eyes?", "I'm hanging on a door? Really? Let's see, can I roll my eyes?",
"Just to let you know, the door is locked.", "Just to let you know, the door is locked.",
""" """
I shouldn['t|be quiet, and not] be telling you this, I shouldn't be telling you this,
but I like the cut of your [suit|cloak|jib]. but I like the cut of your {{suit ^ cloak ^ jib}}.
So, you see, if you speak the |mpassword|n, wait, I've said too much. So, you see, if you speak the |mpassword|n, wait, I've said too much.
""" """
], Knocker_Convo.DOOR], ], Knocker_Convo.DOOR],
@ -273,7 +273,7 @@ class Knocker(Object):
], None], ], None],
[r"thanks|thank you", Knocker_Convo.ANY, [ [r"thanks|thank you", Knocker_Convo.ANY, [
"You're [very|] welcome.", "You're {{very ^ }} welcome.",
"Glad to be of service." "Glad to be of service."
], None], ], None],
@ -282,43 +282,43 @@ class Knocker(Object):
"Excellent.", "Excellent.",
], None], ], None],
[no_msg, Knocker_Convo.ANY, [ [no_msg, Knocker_Convo.ANY, [
"Well, it's true. Just ask the [raven|trees|gnome].", "Well, it's true. Just ask the {{raven ^ trees ^ gnome}}.",
], None], ], None],
[question_msg, Knocker_Convo.ANY, [ [question_msg, Knocker_Convo.ANY, [
"What about [me|it|'im]?", "What about {{me ^ it ^ 'im}}?",
"I dunno...", "I dunno...",
], None], ], None],
] ]
after_unlocked_responses = [ after_unlocked_responses = [
""" """
We could [feign|pretend|play make-believe] and We could {{feign ^ pretend ^ play make-believe}} and
[carry on|continue|persist] this [conversation|charade], {{carry on ^ continue ^ persist}} this {{conversation ^ charade}},
but we both know that |wyou|n know the [password|secret|secret word|magic], but we both know that |wyou|n know the {{password ^ secret ^ secret word ^ magic}},
and can go through the |gdoor|n now. and can go through the |gdoor|n now.
""", """,
""" """
[Sure|Why not|Why yes], let's [feign|pretend|play make-believe that] you {{Sure ^ Why not ^ Why yes}}, let's {{feign ^ pretend ^ play make-believe that}} you
don't know the [password|secret|secret word|magic], and don't know the {{password ^ secret ^ secret word ^ magic}}, and
[carry on|continue|persist] this conversation. {{carry on ^ continue ^ persist}} this conversation.
""", """,
] ]
cant_hear_responses = [ cant_hear_responses = [
"[Sorry.|What was that?|Did you say something?] I'm hard of hearing on account of the brass ears.", "{{Sorry. ^ What was that? ^ Did you say something?}} I'm hard of hearing on account of the brass ears.",
"Brass ears. Yeah, not the best at hearing.", "Brass ears. Yeah, not the best at hearing.",
"Yeah, These brass ears don't hear much except for the |m[secret|magic|] password|n.", "Yeah, These brass ears don't hear much except for the |m{{secret ^ magic ^ }} password|n.",
] ]
unknown_responses = [ unknown_responses = [
"Are you talking to me or the goblin [in the bushes|up the tree|behind the rock]?", "Are you talking to me or the goblin {{in the bushes ^ up the tree ^ behind the rock}}?",
"Knock, knock.", "Knock, knock.",
"What do you mean?", "What do you mean?",
"Of course I like [hard candy|squirrels|apples]. Who [doesn't|wouldn't|do you know that doesn't]?", "Of course I like {{hard candy ^ squirrels ^ apples}}. Who {{doesn't ^ wouldn't ^ do you know that doesn't}}?",
"No thank you, I can't eat [apples|kumquats|figs], what with the brass teeth and a lack of guts.", "No thank you, I can't eat {{apples ^ kumquats ^ figs}}, what with the brass teeth and a lack of guts.",
"Tea? While that would be [nice|sweet] of you, I can't really hold a cup.", "Tea? While that would be {{nice ^ sweet}} of you, I can't really hold a cup.",
"I'm fine, thanks. How are you?", "I'm fine, thanks. How are you?",
"I'll say, [we have had|that is] a spell of weather.", "I'll say, {{we have had ^ that is}} a spell of weather.",
] ]
def at_object_creation(self): def at_object_creation(self):
@ -414,9 +414,9 @@ class Knocker(Object):
response = "In a shape of a bald goblin, the brass door knocker in the center of the red door" response = "In a shape of a bald goblin, the brass door knocker in the center of the red door"
if self.has("brass ring"): if self.has("brass ring"):
response += " holds a ring in its mouth. " response += " holds a ring in its mouth. "
response += "[You think it|You are sure it|You could've sworn it|It] [just|] winked at you." response += "{{You think it ^ You are sure it ^ You could've sworn it ^ It}} {{just ^ }} winked at you."
else: else:
response += " [smiles|looks] at you expectantly. " response += " {{smiles ^ looks}} at you expectantly. "
return routput(response) return routput(response)

View file

@ -19,7 +19,7 @@ import random
MSGS = { MSGS = {
"START": [ "START": [
"A small bird flies over to you, and perches on your shoulder. \"Hello,\" it says in your ear. \"Im the Tutorial Bird,\" it chirps, \"and Im here to break the fourth wall, and help you figure out this game. Feel free to |gshoo|n me away, and Ill leave you alone to explore.\"", "A small bird flies over to you, and perches on your shoulder. \"Hello,\" it says in your ear. \"I'm the Tutorial Bird,\" it chirps, \"and I'm here to break the fourth wall, and help you figure out this game. Feel free to |gshoo|n me away, and I'll leave you alone to explore.\"",
"The bird says, \"In this story game, you type commands (verbs) to do things. For instance, type the word |glook|n, and press the |wReturn|n key to look around at your surroundings and to see where you are, what you can do, and where you can go.\"", "The bird says, \"In this story game, you type commands (verbs) to do things. For instance, type the word |glook|n, and press the |wReturn|n key to look around at your surroundings and to see where you are, what you can do, and where you can go.\"",
"The bird perched on your shoulder looks at you expectantly.", "The bird perched on your shoulder looks at you expectantly.",
"\"Go ahead,\" says the bird, \"Type |glook|n. If you are on the web site, you may need to click in the box in the lower part of the screen.\"", "\"Go ahead,\" says the bird, \"Type |glook|n. If you are on the web site, you may need to click in the box in the lower part of the screen.\"",
@ -28,55 +28,55 @@ MSGS = {
"\"If so,\" says the bird, \"type |glook|n to look around at your surroundings.\"", "\"If so,\" says the bird, \"type |glook|n to look around at your surroundings.\"",
], ],
"LOOK": [ "LOOK": [
"\"Thats great,\" says the little blue bird. \"From that, you know you are standing in a grove of trees near a puddle. You can now type |glook puddle|n to examine it.\"", "\"That's great,\" says the little blue bird. \"From that, you know you are standing in a grove of trees near a puddle. You can now type |glook puddle|n to examine it.\"",
"\"You can also |glook trees|n, |glook moss|n, or … well, you get the idea,\" it says.", "\"You can also |glook trees|n, |glook moss|n, or … well, you get the idea,\" it says.",
], ],
"LOOKAT": [ "LOOKAT": [
"\"You seem to be getting the hang of this game,\" chirps the bird. \"When you typed |glook|n before, you noticed exits. These are directions or places you can go. For instance, if you type |gsouth|n (or just |gs|n as a shortcut), you can check out our pond where you can catch obnoxious fish.\"", "\"You seem to be getting the hang of this game,\" chirps the bird. \"When you typed |glook|n before, you noticed exits. These are directions or places you can go. For instance, if you type |gsouth|n (or just |gs|n as a shortcut), you can check out our pond where you can catch obnoxious fish.\"",
"\"The path to the |geast|n is the meadow of the BHB, the Big Hairy Beast,\" the little bird on your shoulder says. \"It's adorable if you can find it. The path to the |gwest|n leads to Dabblers place.\"", "\"The path to the |geast|n is the meadow of the BHB, the Big Hairy Beast,\" the little bird on your shoulder says. \"It's adorable if you can find it. The path to the |gwest|n leads to Dabbler's place.\"",
"\"Yes, I could fly myself,\" warbles the little bird, \"but Im trying to help you get around.\"", "\"Yes, I could fly myself,\" warbles the little bird, \"but I'm trying to help you get around.\"",
"The bird looks at you expectantly.", "The bird looks at you expectantly.",
"\"Shall we explore other places?\" asks the bird on your shoulder.", "\"Shall we explore other places?\" asks the bird on your shoulder.",
"\"I hope Im not rushing you,\" the bird mentions, \"as you can always come back to explore more.\"", "\"I hope I'm not rushing you,\" the bird mentions, \"as you can always come back to explore more.\"",
], ],
"MOVE": [ "MOVE": [
"\"Thanks for lift. This is a nice place,\" says the bird on your shoulder. \"When you come to a new area, the game shows you what you are seeing, so you dont have to type |glook|n … even though you still can.\"", "\"Thanks for lift. This is a nice place,\" says the bird on your shoulder. \"When you come to a new area, the game shows you what you are seeing, so you don't have to type |glook|n … even though you still can.\"",
"\"Another interesting command,\" it chirps, \"is the |gsay|n command, that lets you talk to anyone in the area. Usually, we use this command for talking to other players in the game, but some creatures listen to what you say.\"", "\"Another interesting command,\" it chirps, \"is the |gsay|n command, that lets you talk to anyone in the area. Usually, we use this command for talking to other players in the game, but some creatures listen to what you say.\"",
"\"Go ahead, just typing |gsay Hello.|n\"", "\"Go ahead, just typing |gsay Hello.|n\"",
], ],
"SAY": [ "SAY": [
"\"Hows it going?\" the bird asks, \"Are you enjoying this game so far?\"", "\"How's it going?\" the bird asks, \"Are you enjoying this game so far?\"",
"The bird says, \"This place has been a respite from the outside turbulence.\"", "The bird says, \"This place has been a respite from the outside turbulence.\"",
"\"A shortcut to |gsay|n is to type either a double or single quote, and then your message.\"", "\"A shortcut to |gsay|n is to type either a double or single quote, and then your message.\"",
"\"You can also use |gpose|n to state something about yourself, \" it says. \" For instance, type |gpose smiles.|n\"", "\"You can also use |gpose|n to state something about yourself, \" it says. \" For instance, type |gpose smiles.|n\"",
# POSE: # POSE:
"The bird stands on one leg.", "The bird stands on one leg.",
"\"See,\" says the bird, \"I spose I can pose too.\"", "\"See,\" says the bird, \"I s'pose I can pose too.\"",
"\"A shortcut to that command is typing |g:|n (a colon character).\"", "\"A shortcut to that command is typing |g:|n (a colon character).\"",
"The bird says, \"The game has more commands. Typing |ghelp|n gives you a list of commands. That list changes depending on where you are and what you are carrying. For instance, you could type |gshoo|n for me to fly away, and then that command wouldnt be available again.\"", "The bird says, \"The game has more commands. Typing |ghelp|n gives you a list of commands. That list changes depending on where you are and what you are carrying. For instance, you could type |gshoo|n for me to fly away, and then that command wouldn't be available again.\"",
# ], # ],
# "HELP": [ # "HELP": [
"The bird chirps, \"You can learn more about the individual commands. For instance, type |ghelp say|n and you would see about the shortcuts I told you about. You can also see new commands, like |ghelp get|n.\"", "The bird chirps, \"You can learn more about the individual commands. For instance, type |ghelp say|n and you would see about the shortcuts I told you about. You can also see new commands, like |ghelp get|n.\"",
"\"Type |ghelp start|n for a repeat of much of what weve talked about,\" says the bird.", "\"Type |ghelp start|n for a repeat of much of what we've talked about,\" says the bird.",
"The bird says, \"The |ginv|n shows you what you are carrying. I see you picked up a letter. You can also type |gread letter|n.\"", "The bird says, \"The |ginv|n shows you what you are carrying. I see you picked up a letter. You can also type |gread letter|n.\"",
"\"Since this game hosts many users,\" says the bird, \"you can show them what they see when they look at you, using the |g@setdesc|n command. Check out the help, |ghelp @setdesc|n, or just type: |w@setdesc A pixie with a shock of blue hair and a gold chain.|n\"", "\"Since this game hosts many users,\" says the bird, \"you can show them what they see when they look at you, using the |g@setdesc|n command. Check out the help, |ghelp @setdesc|n, or just type: |w@setdesc A pixie with a shock of blue hair and a gold chain.|n\"",
"\"Im guessing your last question,\" chirps the little bird on your shoulder, \"is the goal of this game.\"", "\"I'm guessing your last question,\" chirps the little bird on your shoulder, \"is the goal of this game.\"",
"\"That is a good question,\" says the bird, \"and Im not sure what to say. This game has no goal, nor point. I guess you could look at it as a philosophical metaphor for existential existence in a post-modern world in the death throes of capitalism, but…\"", "\"That is a good question,\" says the bird, \"and I'm not sure what to say. This game has no goal, nor point. I guess you could look at it as a philosophical metaphor for existential existence in a post-modern world in the death throes of capitalism, but…\"",
"The bird says, \"This is a cozy little game about role playing a storybook character and maybe exploring and looking for eggs… no, thats not right. Something about eggs. Easter eggs? Something like that.\"", "The bird says, \"This is a cozy little game about role playing a storybook character and maybe exploring and looking for eggs… no, that's not right. Something about eggs. Easter eggs? Something like that.\"",
"\"Wander and look around. Find a cozy place to chat with others who have logged in,\" says the bird.", "\"Wander and look around. Find a cozy place to chat with others who have logged in,\" says the bird.",
"\"If youre interested in |wbuilding|n and expanding this world,\" chirps the bird, \"talk to Dabbler... Oh, see if you can find Dabbler, the guy that made most of this. That is a great goal.\"", "\"If you're interested in |wbuilding|n and expanding this world,\" chirps the bird, \"talk to Dabbler... Oh, see if you can find Dabbler, the guy that made most of this. That is a great goal.\"",
"\"What do you say?\" says the bird. \"Think you got the hang of playing this?\"", "\"What do you say?\" says the bird. \"Think you got the hang of playing this?\"",
] ]
} }
MSGS_WAITING = [ MSGS_WAITING = [
"The [little|blue|] bird [on your shoulder|] preens itself.", "The {{little ^ blue ^ }} bird {{on your shoulder ^ }} preens itself.",
"The [little|blue|] bird [on your shoulder|] [looks|stares] at you [expectantly|waiting|patiently].", "The {{little ^ blue ^ }} bird {{on your shoulder ^ }} {{looks ^ stares}} at you {{expectantly ^ waiting ^ patiently}}.",
"The bird looks up at the sky. \"It rains here often,\" it says.", "The bird looks up at the sky. \"It rains here often,\" it says.",
"The bird looks up at the sky. \"Looks like rain is coming,\" it says.", "The bird looks up at the sky. \"Looks like rain is coming,\" it says.",
"\"I like the rain,\" the bird says, \"as it keeps the moss green and the puddles full.\"", "\"I like the rain,\" the bird says, \"as it keeps the moss green and the puddles full.\"",
"\"They say if you dont like the weather,\" tweets the bird, \"just wait.\"", "\"They say if you don't like the weather,\" tweets the bird, \"just wait.\"",
] ]
class TutorialState(Enum): class TutorialState(Enum):
@ -142,7 +142,7 @@ class TutorBird(CarriableNPC):
""" """
A visual way to stop the tutorial A visual way to stop the tutorial
""" """
character.msg("\"Have fun, and Ill leave you here,\" chirps the bird, \"and remember to check out the letter you picked up!\" It flies away.") character.msg("\"Have fun, and I'll leave you here,\" chirps the bird, \"and remember to check out the letter you picked up!\" It flies away.")
self.delete() self.delete()
def get_msg_level(self, character, level): def get_msg_level(self, character, level):

View file

@ -8,13 +8,12 @@ def squish(text):
"Remove series of spaces from the text." "Remove series of spaces from the text."
return re.sub('[ \n\t]+', ' ', text).strip() return re.sub('[ \n\t]+', ' ', text).strip()
def routput(text, *substitutions):
def routput(text, substitution=None):
""" """
Return string with internal word choices replaced randomly. Return string with internal word choices replaced randomly.
For instance, the string: For instance, the string:
'This feels [|very|quite] [nice|cozy|comfortable].' 'This feels {{^ very ^ quite}} {{nice^cozy^comfortable}}.'
Could return any of the following strings: Could return any of the following strings:
@ -24,21 +23,36 @@ def routput(text, substitution=None):
""" """
if text: if text:
acc = [] acc = []
for s in text.split("["): for s in text.split("{{"):
selections, *rest = s.split("]") selections, *rest = s.split("}}")
choice = random.choice(selections.split('|')) choice = random.choice(re.split(r"\s*\^\s*", selections))
acc = acc + [choice] + rest acc = acc + [choice] + rest
return squish(''.join(acc).format(substitution or "")) proposal = squish(''.join(acc).format(*substitutions))
# If a choice is at the end of a sentence, and we could have
# "no choice", as in:
# "He searches {{thoroughly ^ quickly ^}}."
# We don't want a version that looks like:
# "He searches # ."
# with a space before the punctuation:
return re.sub(r"\s+([!?.,])", "\\1", proposal)
def choices(text, substitution=None): def choices(text, *substitutions):
""" """
Returns a section of 'text' based on separating semicolons. Returns a section of 'text' based on separating semicolons.
Note that text can already be separated as a list or tuple.
""" """
if text: if isinstance(text, str):
selections = text.split(';;') selections = re.split(r"\s*;;\s*", text)
return routput(random.choice(selections), substitution) elif isinstance(text, (tuple, list)):
selections = text
if selections:
return routput(random.choice(selections), *substitutions)
def split_party_msg(viewer, msg): def split_party_msg(viewer, msg):

View file

@ -51,7 +51,7 @@ Spectacles perched precariously on the end of his hooked nose, wobble with his h
# [[file:../../../Dropbox/org/projects/mud.org::*Character: Dabble][Character: Dabble:6]] # [[file:../../../Dropbox/org/projects/mud.org::*Character: Dabble][Character: Dabble:6]]
@set self/disappear_msg = "After a raspberry sound, the gnome, Dabbler, disappears in a wisp of smoke." @set self/disappear_msg = "After a raspberry sound, the gnome, Dabbler, disappears in a wisp of smoke."
# #
@set self/reappear_msg = "[White|Light blue|Gray] mist appears...along with the smell of sulphur... ;; When the smoke clears, an old gnome [emerges|materializes|shows up, looking a bit confused]." @set self/reappear_msg = "{{White ^ Light blue ^ Gray}} mist appears...along with the smell of sulphur... ;; When the smoke clears, an old gnome {{emerges ^ materializes ^ shows up, looking a bit confused}}."
# Character: Dabble:6 ends here # Character: Dabble:6 ends here
@ -123,7 +123,7 @@ Spectacles perched precariously on the end of his hooked nose, wobble with his h
# [[file:../../../Dropbox/org/projects/mud.org::*Puddles][Puddles:3]] # [[file:../../../Dropbox/org/projects/mud.org::*Puddles][Puddles:3]]
@lock puddle = get:false() @lock puddle = get:false()
# #
@set puddle/get_err_msg = "As the water slips through your fingers, you realize the apt metaphor of attempting to grasp at your youth. @set puddle/get_err_msg = "As the water slips through your fingers, you realize the apt metaphor of attempting to grasp at your youth."
# Puddles:3 ends here # Puddles:3 ends here
@ -202,7 +202,7 @@ Wait! You notice a foot hold, and then another. You can |gclimb|n this boulder!
# To take advantage of our [[Hidden Things]], we put the right tag on it: # To take advantage of our [[Hidden Things]], we put the right tag on it:
# [[file:../../../Dropbox/org/projects/mud.org::*Boulder][Boulder:7]] # [[file:../../../Dropbox/org/projects/mud.org::*Boulder][Boulder:7]]
@set boulder/hidden_tag = hidden_boulder @set boulder/hidden_tag = "hidden_boulder"
# #
@lock boulder = view:tag(hidden_boulder) @lock boulder = view:tag(hidden_boulder)
# Boulder:7 ends here # Boulder:7 ends here
@ -291,7 +291,7 @@ Wait! You notice a foot hold, and then another. You can |gclimb|n this boulder!
# And a lovely message about why you cant steal moss: # And a lovely message about why you cant steal moss:
# [[file:../../../Dropbox/org/projects/mud.org::*Top of Boulder][Top of Boulder:10]] # [[file:../../../Dropbox/org/projects/mud.org::*Top of Boulder][Top of Boulder:10]]
@set moss/get_err_msg = The moss is a bryophyte, and as such, has attached itself to boulder by rhizoids, which are one cell thick root structures. While this helps with water absorption, you didn't think you were going to get a biology lesson, did you? tl;dr You can't get it. @set moss/get_err_msg = "The moss is a bryophyte, and as such, has attached itself to boulder by rhizoids, which are one cell thick root structures. While this helps with water absorption, you didn't think you were going to get a biology lesson, did you? tl;dr You can't get it."
# Top of Boulder:10 ends here # Top of Boulder:10 ends here
@ -440,7 +440,7 @@ Wait! Is there a large cave entrance hidden behind the water?
# And we make it hidden: # And we make it hidden:
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:3]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:3]]
@set lair/hidden_tag = hidden_cave @set lair/hidden_tag = "hidden_cave"
# #
@lock lair = view:tag(hidden_cave) @lock lair = view:tag(hidden_cave)
# The Lair of the Beast:3 ends here # The Lair of the Beast:3 ends here
@ -530,7 +530,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:13]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:13]]
@set beast/hidden_tag = hidden_beast @set beast/hidden_tag = "hidden_beast"
# #
@lock beast = view:tag(hidden_beast) @lock beast = view:tag(hidden_beast)
# The Lair of the Beast:13 ends here # The Lair of the Beast:13 ends here
@ -614,7 +614,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:22]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:22]]
@set beast/scared_msg = "It seems [skiddish|afraid|skiddish and afraid] as it tries to hide behind a tall clump of grass. Yeah, it doesn't do a good job of hiding." @set beast/scared_msg = "It seems {{skiddish ^ afraid ^ skiddish and afraid}} as it tries to hide behind a tall clump of grass. Yeah, it doesn't do a good job of hiding."
# The Lair of the Beast:22 ends here # The Lair of the Beast:22 ends here
@ -632,7 +632,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:24]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:24]]
@set beast/interested_msg = "It seems [curious|interested] in what you are doing [here|]. ;; Its [|large,|big,] yellow eyes watch your every move." @set beast/interested_msg = "It seems {{curious ^ interested}} in what you are doing {{here ^ }}. ;; Its {{ ^ large, ^ big,}} yellow eyes watch your every move."
# The Lair of the Beast:24 ends here # The Lair of the Beast:24 ends here
@ -641,7 +641,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:25]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:25]]
@set beast/friendly_msg = "It sits next to you, as its big, friendly eyes gaze as you. ;; It [leaps over|runs up|bounces up|] to you, wagging its tail-less behind. ;; It lays down next to you." @set beast/friendly_msg = "It sits next to you, as its big, friendly eyes gaze as you. ;; It {{leaps over ^ runs up ^ bounces up ^ }} to you, wagging its tail-less behind. ;; It lays down next to you."
# The Lair of the Beast:25 ends here # The Lair of the Beast:25 ends here
@ -650,7 +650,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:26]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:26]]
@set beast/sleeping_actions = "The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] lets loose a [big,|huge,|large,|tremendous,|] snore. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] growls in its sleep. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] twitches its [leg|legs|paw|nose]. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [shifts|rolls] on its [big,|huge,|large,|tremendous,|] mattress." @set beast/sleeping_actions = "The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} lets loose a {{big, ^ huge, ^ large, ^ tremendous, ^ }} snore. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} growls in its sleep. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} twitches its {{leg ^ legs ^ paw ^ nose}}. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{shifts ^ rolls}} on its {{big, ^ huge, ^ large, ^ tremendous, ^ }} mattress."
# The Lair of the Beast:26 ends here # The Lair of the Beast:26 ends here
@ -671,7 +671,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:28]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:28]]
@set beast/concerned_actions = "The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [is|seems] concerned by your presence in the [meadow|field]. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] seems concerned. Maybe it's hungry.. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] seems concerned and keeps its distance.." @set beast/concerned_actions = "The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{is ^ seems}} concerned by your presence in the {{meadow ^ field}}. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} seems concerned. Maybe it's hungry.. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} seems concerned and keeps its distance.."
# The Lair of the Beast:28 ends here # The Lair of the Beast:28 ends here
@ -680,7 +680,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:29]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:29]]
@set beast/interested_actions = "The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] seems [curious|interested] in what you are doing [here|]. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] seems curious about you. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] stands on its hind legs. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [stares at|watches|follows] you with its [large,|big,|] yellow eyes." @set beast/interested_actions = "The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} seems {{curious ^ interested}} in what you are doing {{here ^ }}. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} seems curious about you. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} stands on its hind legs. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{stares at ^ watches ^ follows}} you with its {{large, ^ big, ^ }} yellow eyes."
# The Lair of the Beast:29 ends here # The Lair of the Beast:29 ends here
@ -689,7 +689,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:30]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:30]]
@set beast/friendly_actions = "The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] wagging its backend[,| as it seems] happy to see <you>. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] hoping to play with <you>. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] flops over in front of <you> wriggling [its back|] on the ground. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] next to you. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] chases butterflies around the [field|meadow|grass|flowers]." @set beast/friendly_actions = "The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} wagging its backend{{, ^ as it seems}} happy to see <you>. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} hoping to play with <you>. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} flops over in front of <you> wriggling {{its back ^ }} on the ground. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} next to you. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} chases butterflies around the {{field ^ meadow ^ grass ^ flowers}}."
# The Lair of the Beast:30 ends here # The Lair of the Beast:30 ends here
@ -698,7 +698,7 @@ lair
# [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:31]] # [[file:../../../Dropbox/org/projects/mud.org::*The Lair of the Beast][The Lair of the Beast:31]]
@set beast/ecstatic_actions = "The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] to give <you> a sloppy [kiss|lick]. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] wagging its backend as it seems [|very] excited to see <you>. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] hoping to play with <you>. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] flops over in front of <you> happily wriggling on the ground. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] excitedly [thunders|stomps|tramps|clomps|rumbles|rolls] [across the field|across the meadow|over] next to you. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] [happily|joyfully] leaps into air. ;; The [big,|huge,|large,|tremendous,|] [hairy|slobbery|horned|clawed|] [brute|beast|monster] chases butterflies around the [field|meadow|grass|flowers]." @set beast/ecstatic_actions = "The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} to give <you> a sloppy {{kiss ^ lick}}. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} wagging its backend as it seems {{very ^ }} excited to see <you>. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} hoping to play with <you>. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} flops over in front of <you> happily wriggling on the ground. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} excitedly {{thunders ^ stomps ^ tramps ^ clomps ^ rumbles ^ rolls}} {{across the field ^ across the meadow ^ over}} next to you. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} {{happily ^ joyfully}} leaps into air. ;; The {{big, ^ huge, ^ large, ^ tremendous, ^ }} {{hairy ^ slobbery ^ horned ^ clawed ^ }} {{brute ^ beast ^ monster}} chases butterflies around the {{field ^ meadow ^ grass ^ flowers}}."
# The Lair of the Beast:31 ends here # The Lair of the Beast:31 ends here
@ -1000,7 +1000,7 @@ west
# And the bush needs to know the /description/ of the Consumable, so that it can attach that: # And the bush needs to know the /description/ of the Consumable, so that it can attach that:
# [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:7]] # [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:7]]
@set bush/make_desc = "Bright red berry with flecks of [purple|violet|orange]." @set bush/make_desc = "Bright red berry with flecks of {{purple ^ violet ^ orange}}."
# Berry Bush:7 ends here # Berry Bush:7 ends here
@ -1023,7 +1023,7 @@ west
# We can either have a single /eat/ message: # We can either have a single /eat/ message:
# [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:10]] # [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:10]]
@set bush/make_eat_msg = "Sweet and slightly tart. [Delicious|Tangy|Mmmm]." @set bush/make_eat_msg = "Sweet and slightly tart. {{Delicious ^ Tangy ^ Mmmm}}."
# Berry Bush:10 ends here # Berry Bush:10 ends here
@ -1031,7 +1031,7 @@ west
# Or many messages that can be randomly selected: # Or many messages that can be randomly selected:
# [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:11]] # [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:11]]
@set bush/make_eat_msgs = [ "Sweet and slightly tart.", "[Delicious|Tangy|Mmmm].", "Ooo...that one was sour.", "That was a bit ripe, but still good.", "So sweet with a hint of [orange|maple]." ] @set bush/make_eat_msgs = [ "Sweet and slightly tart.", "{{Delicious ^ Tangy ^ Mmmm}}.", "Ooo...that one was sour.", "That was a bit ripe, but still good.", "So sweet with a hint of {{orange ^ maple}}." ]
# Berry Bush:11 ends here # Berry Bush:11 ends here
@ -1039,7 +1039,7 @@ west
# Let the user know when they consumed them all. # Let the user know when they consumed them all.
# [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:12]] # [[file:../../../Dropbox/org/projects/mud.org::*Berry Bush][Berry Bush:12]]
@set bush/make_finish_msg = "Those were [delicious|great]." @set bush/make_finish_msg = "Those were {{delicious ^ great}}."
# Berry Bush:12 ends here # Berry Bush:12 ends here
@ -1097,7 +1097,7 @@ west
# Although we can interact with it, lets not make it obvious that it is an object: # Although we can interact with it, lets not make it obvious that it is an object:
# [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:7]] # [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:7]]
@set ring/hidden_tag = hidden_ring @set ring/hidden_tag = "hidden_ring"
# #
@lock ring = view:tag(hidden_ring) @lock ring = view:tag(hidden_ring)
# Knocker:7 ends here # Knocker:7 ends here
@ -1119,7 +1119,7 @@ west
# [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:9]] # [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:9]]
@lock ring = tethered:id(#27) @lock ring = tethered:id(#27)
# #
@set ring/tethered_msg = You put the ring back in the knocker's mouth. "Mmmuufffmm," says the door knocker. @set ring/tethered_msg = "You put the ring back in the knocker's mouth. \"Mmmuufffmm,\" says the door knocker."
# Knocker:9 ends here # Knocker:9 ends here
@ -1144,7 +1144,7 @@ west
# [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:12]] # [[file:../../../Dropbox/org/projects/mud.org::*Knocker][Knocker:12]]
@set knocker/room_to_msg = mp03 @set knocker/room_to_msg = "mp03"
# Knocker:12 ends here # Knocker:12 ends here
@ -1519,7 +1519,7 @@ py here.search("trolley").do_bake()
# #
@set chairs/singular = "an overstuffed chair" @set chairs/singular = "an overstuffed chair"
# #
@set chairs/extra = "This feels [|very|quite] [nice|cozy|comfortable].|n" @set chairs/extra = "This feels {{ ^ very ^ quite}} {{nice ^ cozy ^ comfortable}}.|n"
# Chairs:5 ends here # Chairs:5 ends here