fixed nonexistent detail message by correcting the order of arguments to _AT_SEARCH_RESULT
fixed room/detail key collisions by excluding caller.location from candidates
This commit is contained in:
parent
aa52b8b281
commit
a39d52dd7e
1 changed files with 5 additions and 2 deletions
|
|
@ -287,7 +287,10 @@ class CmdExtendedLook(default_cmds.CmdLook):
|
||||||
caller = self.caller
|
caller = self.caller
|
||||||
args = self.args
|
args = self.args
|
||||||
if args:
|
if args:
|
||||||
looking_at_obj = caller.search(args, use_nicks=True, quiet=True)
|
looking_at_obj = caller.search(args,
|
||||||
|
candidates=caller.location.contents + caller.contents,
|
||||||
|
use_nicks=True,
|
||||||
|
quiet=True)
|
||||||
if not looking_at_obj:
|
if not looking_at_obj:
|
||||||
# no object found. Check if there is a matching
|
# no object found. Check if there is a matching
|
||||||
# detail at location.
|
# detail at location.
|
||||||
|
|
@ -299,7 +302,7 @@ class CmdExtendedLook(default_cmds.CmdLook):
|
||||||
caller.msg(detail)
|
caller.msg(detail)
|
||||||
return
|
return
|
||||||
# no detail found. Trigger delayed error messages
|
# no detail found. Trigger delayed error messages
|
||||||
_AT_SEARCH_RESULT(caller, args, looking_at_obj, False)
|
_AT_SEARCH_RESULT(looking_at_obj, caller, args, quiet=False)
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
# we need to extract the match manually.
|
# we need to extract the match manually.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue