Tutorial bird may return
By either calling the command, tutorial or by setting: @set character/guest_account = True
This commit is contained in:
parent
5bdb42042b
commit
a954dcfbdf
3 changed files with 14 additions and 2 deletions
|
|
@ -22,7 +22,7 @@ from evennia.contrib.rpg.character_creator.character_creator import ContribCharg
|
|||
from commands.sittables import CmdNoSitStand
|
||||
from commands.everyone import (CmdTake, CmdThink, CmdSay,
|
||||
CmdWhisper, CmdRead, CmdEat, CmdDrink,
|
||||
CmdUse, CmdPush, CmdPull)
|
||||
CmdUse, CmdPush, CmdPull, CmdTutorial)
|
||||
from commands.misc import CmdLight
|
||||
from commands.wizards import CmdGM, CmdSpell, CmdGMTrigger, CmdMakeCocktail
|
||||
|
||||
|
|
@ -41,6 +41,7 @@ class CharacterCmdSet(default_cmds.CharacterCmdSet):
|
|||
Populates the cmdset
|
||||
"""
|
||||
super().at_cmdset_creation()
|
||||
self.add(CmdTutorial)
|
||||
self.add(CmdNoSitStand)
|
||||
self.add(CmdEat)
|
||||
self.add(CmdDrink)
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ from evennia.contrib.rpg.rpsystem import send_emote
|
|||
from evennia.utils import iter_to_str, logger
|
||||
|
||||
from typeclasses.characters import Character
|
||||
from typeclasses.tutorial import TutorBird, TutorialState
|
||||
from utils.word_list import routput, paragraph, choices
|
||||
|
||||
|
||||
|
|
@ -38,6 +39,16 @@ def speech_effect(speech, verb, target, effects):
|
|||
return (speech, speech, verb)
|
||||
|
||||
|
||||
class CmdTutorial(Command):
|
||||
"""
|
||||
Start (or restart) the tutorial.
|
||||
"""
|
||||
key = "tutorial"
|
||||
|
||||
def func(self):
|
||||
TutorBird.do_start_tutorial(self.caller)
|
||||
|
||||
|
||||
class CmdUse(MuxCommand):
|
||||
"""
|
||||
Use an item.
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ class Character(Object, GenderCharacter, ContribRPCharacter):
|
|||
obj.delete()
|
||||
|
||||
def at_post_puppet(self, **kwargs):
|
||||
if self.db.visited:
|
||||
if self.db.visited and not self.db.guest_account:
|
||||
self.msg(f"""\n“Welcome back, {self.key.capitalize()}.”\n""")
|
||||
if self.location.key == "Wyldwood Bar":
|
||||
self.msg("You wake up in a meadow with a strange dream of a bar...")
|
||||
|
|
|
|||
Loading…
Reference in a new issue