Indent fixes to address #1258
PEP 8 whitespace and docstring edits, also
This commit is contained in:
parent
62bd9fb4ab
commit
63c7ea3ab7
1 changed files with 17 additions and 14 deletions
|
|
@ -81,8 +81,10 @@ class BotStarter(DefaultScript):
|
|||
"""
|
||||
self.db.started = False
|
||||
|
||||
#
|
||||
# Bot base class
|
||||
|
||||
|
||||
class Bot(DefaultPlayer):
|
||||
"""
|
||||
A Bot will start itself when the server starts (it will generally
|
||||
|
|
@ -337,7 +339,6 @@ class IRCBot(Bot):
|
|||
if kwargs["type"] == "action":
|
||||
# An action (irc pose)
|
||||
text = "%s@%s %s" % (kwargs["user"], kwargs["channel"], txt)
|
||||
|
||||
else:
|
||||
# msg - A normal channel message
|
||||
text = "%s@%s: %s" % (kwargs["user"], kwargs["channel"], txt)
|
||||
|
|
@ -348,8 +349,10 @@ class IRCBot(Bot):
|
|||
if self.ndb.ev_channel:
|
||||
self.ndb.ev_channel.msg(text, senders=self.id)
|
||||
|
||||
#
|
||||
# RSS
|
||||
|
||||
|
||||
class RSSBot(Bot):
|
||||
"""
|
||||
An RSS relayer. The RSS protocol itself runs a ticker to update
|
||||
|
|
@ -363,7 +366,7 @@ class RSSBot(Bot):
|
|||
Args:
|
||||
ev_channel (str): Key of the Evennia channel to connect to.
|
||||
rss_url (str): Full URL to the RSS feed to subscribe to.
|
||||
rss_update_rate (int): How often for the feedreader to update.
|
||||
rss_rate (int): How often for the feedreader to update.
|
||||
|
||||
Raises:
|
||||
RuntimeError: If `ev_channel` does not exist.
|
||||
|
|
@ -404,7 +407,7 @@ class RSSBot(Bot):
|
|||
Args:
|
||||
session (Session, optional): Session responsible for this
|
||||
command.
|
||||
text (str, optional): Command string.
|
||||
txt (str, optional): Command string.
|
||||
kwargs (dict, optional): Additional Information passed from bot.
|
||||
Not used by the RSSbot by default.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue