PEP8 cleanup of the entire codebase. Unchanged are many cases of too-long lines, partly because of the rewrite they would require but also because splitting many lines up would make the code harder to read. Also the third-party libraries (idmapper, prettytable etc) were not cleaned.
This commit is contained in:
parent
30b7d2a405
commit
1ae17bcbe4
154 changed files with 5613 additions and 4054 deletions
|
|
@ -13,6 +13,7 @@ __all__ = ("CmdHome", "CmdLook", "CmdNick",
|
|||
|
||||
AT_SEARCH_RESULT = utils.variable_from_module(*settings.SEARCH_AT_RESULT.rsplit('.', 1))
|
||||
|
||||
|
||||
class CmdHome(MuxCommand):
|
||||
"""
|
||||
home
|
||||
|
|
@ -38,6 +39,7 @@ class CmdHome(MuxCommand):
|
|||
caller.move_to(home)
|
||||
caller.msg("There's no place like home ...")
|
||||
|
||||
|
||||
class CmdLook(MuxCommand):
|
||||
"""
|
||||
look
|
||||
|
|
@ -126,7 +128,9 @@ class CmdNick(MuxCommand):
|
|||
nicks = caller.nicks.get(category="channel")
|
||||
|
||||
if 'list' in switches:
|
||||
table = prettytable.PrettyTable(["{wNickType", "{wNickname", "{wTranslates-to"])
|
||||
table = prettytable.PrettyTable(["{wNickType",
|
||||
"{wNickname",
|
||||
"{wTranslates-to"])
|
||||
for nick in nicks:
|
||||
table.add_row([nick.db_category, nick.db_key, nick.db_data])
|
||||
string = "{wDefined Nicks:{n\n%s" % table
|
||||
|
|
@ -170,6 +174,7 @@ class CmdNick(MuxCommand):
|
|||
caller.nicks.add(nick, real, category=switch)
|
||||
caller.msg(string)
|
||||
|
||||
|
||||
class CmdInventory(MuxCommand):
|
||||
"""
|
||||
inventory
|
||||
|
|
@ -198,6 +203,7 @@ class CmdInventory(MuxCommand):
|
|||
string = "{wYou are carrying:\n%s" % table
|
||||
self.caller.msg(string)
|
||||
|
||||
|
||||
class CmdGet(MuxCommand):
|
||||
"""
|
||||
get
|
||||
|
|
@ -327,7 +333,6 @@ class CmdGive(MuxCommand):
|
|||
target.msg("%s gives you %s." % (caller.key, to_give.key))
|
||||
|
||||
|
||||
|
||||
class CmdSay(MuxCommand):
|
||||
"""
|
||||
say
|
||||
|
|
@ -365,6 +370,7 @@ class CmdSay(MuxCommand):
|
|||
caller.location.msg_contents(emit_string,
|
||||
exclude=caller)
|
||||
|
||||
|
||||
class CmdPose(MuxCommand):
|
||||
"""
|
||||
pose - strike a pose
|
||||
|
|
@ -407,6 +413,7 @@ class CmdPose(MuxCommand):
|
|||
msg = "%s%s" % (self.caller.name, self.args)
|
||||
self.caller.location.msg_contents(msg)
|
||||
|
||||
|
||||
class CmdAccess(MuxCommand):
|
||||
"""
|
||||
access - show access groups
|
||||
|
|
@ -440,5 +447,4 @@ class CmdAccess(MuxCommand):
|
|||
string += "\nCharacter {c%s{n: %s" % (caller.key, cperms)
|
||||
if hasattr(caller, 'player'):
|
||||
string += "\nPlayer {c%s{n: %s" % (caller.player.key, pperms)
|
||||
caller.msg(string)
|
||||
|
||||
caller.msg(string)
|
||||
Loading…
Add table
Add a link
Reference in a new issue