Updated all Player-level commands to properly relay messages using self.msg rather than caller.msg (the former will properly relay to the right sessid without needing any extra arguments).

This commit is contained in:
Griatch 2013-04-12 14:27:36 +02:00
parent b58a464409
commit 0fddf433dc
9 changed files with 137 additions and 154 deletions

View file

@ -172,7 +172,7 @@ def cmdhandler(caller, raw_string, testing=False, sessid=None):
raw_string - the command string given on the command line
testing - if we should actually execute the command or not.
if True, the command instance will be returned instead.
sessid - the session id calling this handler, if any
Note that this function returns a deferred!
"""
try: # catch bugs in cmdhandler itself
@ -240,6 +240,7 @@ def cmdhandler(caller, raw_string, testing=False, sessid=None):
if syscmd:
# replace system command with custom version
cmd = syscmd
cmd.sessid = sessid
sysarg = "%s:%s" % (cmdname, args)
raise ExecSystemCommand(cmd, sysarg)