Triggers now execute commands when preceded with @
This commit is contained in:
parent
daace6e983
commit
a1e852c8a8
2 changed files with 44 additions and 7 deletions
|
|
@ -246,6 +246,9 @@ class CmdGMTrigger(Command):
|
|||
|
||||
for idx, event in enumerate(events):
|
||||
if isinstance(event, str):
|
||||
if event.startswith("@"):
|
||||
self.caller.execute_cmd(event[1:])
|
||||
else:
|
||||
msg = target.gendered_text(routput(event, name))
|
||||
delay(time_delay * idx,
|
||||
self.caller.location.msg_contents,
|
||||
|
|
|
|||
|
|
@ -85,6 +85,38 @@
|
|||
You also notice a glowing orb... and then another, and another. The field, filled with soft light, illuminates another path...
|
||||
# Portal:4 ends here
|
||||
|
||||
|
||||
|
||||
# Let’s do them all with the Raven:
|
||||
|
||||
|
||||
# [[file:../../../projects/mud-rpg.org::*Opening the Portal][Opening the Portal:7]]
|
||||
@set/character Raven/triggers:session0 = {
|
||||
"open": {"desc": "Open the Portal to the Wyldwood Bar",
|
||||
"timer": 1,
|
||||
"events": [
|
||||
"@fly Frog Meadow",
|
||||
"The big, hairy beast trembles with the appearance of the raven, and flees behind the waterfall.",
|
||||
"@teleport beast = Lair",
|
||||
"You notice a glowing orb dancing in front of you... and then another, and another. The field, filled with soft light, illuminates a different path into the forest...",
|
||||
"@teleport follow the glowing orbs = Frog Meadow",
|
||||
"@roomstate portal_open",
|
||||
"@fly Radiant Workshop",
|
||||
]
|
||||
},
|
||||
"close": {"desc": "Close the Portal to the Wyldwood Bar",
|
||||
"timer": 1,
|
||||
"events": [
|
||||
"@fly Frog Meadow",
|
||||
"The glowing orbs that filled the field start to wink out.",
|
||||
"@teleport/tonone follow the glowing orbs",
|
||||
"@roomstate portal_open",
|
||||
"@fly Radiant Workshop",
|
||||
]
|
||||
},
|
||||
}
|
||||
# Opening the Portal:7 ends here
|
||||
|
||||
# Closing the Portal
|
||||
# First, close the portal by moving it to the =None= location:
|
||||
|
||||
|
|
@ -161,16 +193,18 @@ py bt = self.search('Bartender'); bt.db.gender = 'male'; bt.db._sdesc = 'blonde
|
|||
# A haughty elf named Elendil
|
||||
|
||||
# [[file:../../../projects/mud-rpg.org::*Pixie Quartet][Pixie Quartet:1]]
|
||||
@create/drop quartet of pixies;quartet;pixies;pixie: typeclasses.puppets.Puppet
|
||||
@create/drop Pixies;pixie: typeclasses.puppets.Puppet
|
||||
# Pixie Quartet:1 ends here
|
||||
|
||||
|
||||
|
||||
# And give them a better name/description:
|
||||
|
||||
# And all the RP system stuff:
|
||||
|
||||
|
||||
# [[file:../../../projects/mud-rpg.org::*Pixie Quartet][Pixie Quartet:2]]
|
||||
py bt = self.search('pixies'); bt.db.pose_default = 'playing music atop a giant fieldcap mushroom'; bt.db.pose = 'playing music'
|
||||
py bt = self.search('pixies'); bt.db._sdesc = "quartet of pixies"; bt.db.pose_default = 'playing music atop a giant fieldcap mushroom'; bt.db.pose = 'playing music'; bt.db.gender = 'ambiguous';
|
||||
# Pixie Quartet:2 ends here
|
||||
|
||||
# [[file:../../../projects/mud-rpg.org::*Pixie Quartet][Pixie Quartet:3]]
|
||||
|
|
@ -204,7 +238,7 @@ py bt = self.search('pixies'); bt.db.pose_default = 'playing music atop a giant
|
|||
|
||||
|
||||
# [[file:../../../projects/mud-rpg.org::*Awakened Shrub][Awakened Shrub:1]]
|
||||
@create/drop shrub;bush;chalkboard;awakened shrub: typeclasses.puppets.Shrub
|
||||
@create/drop Shrub;bush;chalkboard;awakened shrub: typeclasses.puppets.Shrub
|
||||
# Awakened Shrub:1 ends here
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue