Пример #1
0
    def noteout(self, user, msg):
        """ Send a notice to a user. """
        msgOut = format.encodeOut(msg)
        userOut = format.encodeOut(user)
        self.notice(user=userOut, message=msgOut)

        # strip color codes
        log.chatlog.info('[NTE->%s]%s' % (userOut, format.strip(msgOut)))
Пример #2
0
    def pubout(self, channel, msg):
        """ Send a message to a channel. """
        msgOut = format.encodeOut(msg)
        channelOut = format.encodeOut(channel)
        self.say(channel=channelOut, message=msgOut)

        # strip color codes
        log.chatlog.info('[PUB->%s]%s' % (channelOut, format.strip(msgOut)))
Пример #3
0
    def privout(self, user, msg):
        """ Send a message to a user. """
        msgOut = format.encodeOut(msg)
        userOut = format.encodeOut(user)
        self.msg(user=userOut, message=msgOut)

        # strip color codes
        log.chatlog.info('[PRV->%s]%s' % (userOut, format.strip(msgOut)))
Пример #4
0
    def actout(self,channel, msg):
        """ Send an action (/me command) to a channel. """
        msgOut = format.encodeOut(msg)
        channelOut = format.encodeOut(channel)
        self.me(channel=channelOut, action=msgOut)

        # strip color codes
        log.chatlog.info('[ACT->%s]%s' % (channelOut, format.strip(msgOut)))