From 06c9c6b531e425a0c7da3ac5ae03eeb18db9b8ce Mon Sep 17 00:00:00 2001 From: Griatch Date: Sun, 18 Jan 2015 12:39:17 +0100 Subject: [PATCH] Added a general-use 'desc' command. Resolves #643. --- evennia/commands/default/general.py | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/evennia/commands/default/general.py b/evennia/commands/default/general.py index 87878bcea..819c3d1ab 100644 --- a/evennia/commands/default/general.py +++ b/evennia/commands/default/general.py @@ -331,6 +331,30 @@ class CmdGive(MuxCommand): target.msg("%s gives you %s." % (caller.key, to_give.key)) +class CmdDesc(MuxCommand): + """ + describe yourself + + Usage: + desc + + Add a description to yourself. This + will be visible to people when they + look at you. + """ + key = "desc" + locks = "cmd:all()" + + def func(self): + "add the description" + + if not self.args: + self.caller.msg("You must add a description.") + return + + self.caller.db.desc = self.args.strip() + self.caller.msg("You set your description.") + class CmdSay(MuxCommand): """ speak as your character