Stop #dbref searches for unprivileged. Other minor fixes. Resolves #1251.

This commit is contained in:
Griatch 2017-10-01 16:51:41 +02:00
parent 3938dd45f7
commit d2e8badf18
4 changed files with 25 additions and 16 deletions

View file

@ -824,7 +824,7 @@ class CmdQuell(COMMAND_DEFAULT_CLASS):
"""Perform the command"""
account = self.account
permstr = account.is_superuser and " (superuser)" or "(%s)" % (", ".join(account.permissions.all()))
if self.cmdstring == '@unquell':
if self.cmdstring in ('unquell', '@unquell'):
if not account.attributes.get('_quell'):
self.msg("Already using normal Account permissions %s." % permstr)
else:

View file

@ -67,7 +67,7 @@ class CmdLook(COMMAND_DEFAULT_CLASS):
caller.msg("You have no location to look at!")
return
else:
target = caller.search(self.args, use_dbref=caller.check_permstring("Builders"))
target = caller.search(self.args)
if not target:
return
self.msg(caller.at_look(target))
@ -266,7 +266,7 @@ class CmdGet(COMMAND_DEFAULT_CLASS):
else:
caller.msg("You can't get that.")
return
# calling at_before_get hook method
if not obj.at_before_get(caller):
return
@ -311,7 +311,7 @@ class CmdDrop(COMMAND_DEFAULT_CLASS):
multimatch_string="You carry more than one %s:" % self.args)
if not obj:
return
# Call the object script's at_before_drop() method.
if not obj.at_before_drop(caller):
return
@ -358,11 +358,11 @@ class CmdGive(COMMAND_DEFAULT_CLASS):
if not to_give.location == caller:
caller.msg("You are not holding %s." % to_give.key)
return
# calling at_before_give hook method
if not to_give.at_before_give(caller, target):
return
# give object
caller.msg("You give %s to %s." % (to_give.key, target.key))
to_give.move_to(target, quiet=True)