mirror of
https://github.com/evennia/evennia.git
synced 2026-03-16 21:06:30 +01:00
Resolve conflicts against master.
This commit is contained in:
parent
91ffde5eaf
commit
831b1567ae
3 changed files with 6 additions and 8 deletions
|
|
@ -8,8 +8,6 @@ from __future__ import print_function
|
|||
from django.conf import settings
|
||||
from evennia.players.players import DefaultPlayer
|
||||
from evennia.scripts.scripts import DefaultScript
|
||||
from evennia.commands.command import Command
|
||||
from evennia.commands.cmdset import CmdSet
|
||||
from evennia.utils import search
|
||||
|
||||
_IDLE_TIMEOUT = settings.IDLE_TIMEOUT
|
||||
|
|
@ -218,7 +216,7 @@ class IRCBot(Bot):
|
|||
if not from_obj or from_obj != [self.id]:
|
||||
super(IRCBot, self).msg(text=text, options={"bot_data_out": True})
|
||||
|
||||
def execute_cmd(self, text=None, session=None):
|
||||
def execute_cmd(self, text=None, session=None, **kwargs):
|
||||
"""
|
||||
Take incoming data and send it to connected channel. This is
|
||||
triggered by the CmdListen command in the BotCmdSet.
|
||||
|
|
@ -278,7 +276,7 @@ class RSSBot(Bot):
|
|||
"rate": self.db.rss_rate}
|
||||
_SESSIONS.start_bot_session("evennia.server.portal.rss.RSSBotFactory", configdict)
|
||||
|
||||
def execute_cmd(self, text=None, session=None):
|
||||
def execute_cmd(self, text=None, session=None, **kwargs):
|
||||
"""
|
||||
Echo RSS input to connected channel
|
||||
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ def bot_data_in(session, *args, **kwargs):
|
|||
return
|
||||
kwargs.pop("options", None)
|
||||
# Trigger the execute_cmd method of the corresponding bot.
|
||||
session.player.execute_cmd(text=txt, session=session)
|
||||
session.player.execute_cmd(session=session, text=txt, **kwargs)
|
||||
session.update_session_counters()
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ class IRCBot(irc.IRCClient, Session):
|
|||
if not msg.startswith('***'):
|
||||
user = user.split('!', 1)[0]
|
||||
user = ansi.raw(user)
|
||||
self.data_in("%s@%s: %s" % (user, channel, msg))
|
||||
self.data_in(text=msg, type="msg", user=user, channel=channel)
|
||||
|
||||
def action(self, user, channel, msg):
|
||||
"""
|
||||
|
|
@ -192,7 +192,7 @@ class IRCBot(irc.IRCClient, Session):
|
|||
"""
|
||||
if not msg.startswith('**'):
|
||||
user = user.split('!', 1)[0]
|
||||
self.data_in("%s@%s %s" % (user, channel, msg))
|
||||
self.data_in(text=msg, type="action", user=user, channel=channel)
|
||||
|
||||
def data_in(self, text=None, **kwargs):
|
||||
"""
|
||||
|
|
@ -204,7 +204,7 @@ class IRCBot(irc.IRCClient, Session):
|
|||
|
||||
"""
|
||||
|
||||
self.sessionhandler.data_in(self, bot_data_in=text, **kwargs)
|
||||
self.sessionhandler.data_in(self, bot_data_in=text)
|
||||
|
||||
def send_text(self, *args, **kwargs):
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue