Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(28)  |  Call(28)  |  Derive(0)  |  Import(0)
Write a message to Rcon/Console

src/b/3/b3-1.9.2/b3/parsers/iourt42.py   b3(Download)
            return self.kick(client, reason, admin, silent)
        elif isinstance(client, str) and re.match('^[0-9]+$', client):
            self.write(self.getCommand('ban', cid=client, reason=reason))
            return
        elif not client.id:
            # ban by ip, this happens when we !permban @xx a player that is not connected
            self.debug('EFFECTIVE BAN : %s',self.getCommand('banByIp', ip=client.ip, reason=reason))
            self.write(self.getCommand('banByIp', ip=client.ip, reason=reason))
        else:
            # ban by cid
                cmd = self.getCommand('auth-permban', cid=client.cid)
                self.info('sending ban to Frozen Sand : %s' % cmd)
                rv = self.write(cmd)
                if rv:
                    if rv == "Auth services disabled" or rv.startswith("auth: not banlist available."):
                cmd = self.getCommand('ban', cid=client.cid, reason=reason)
                self.info('sending ban to server : %s' % cmd)
                rv = self.write(cmd)
                if rv:
                    self.info(rv)
            return self.kick(client, reason, admin, silent)
        elif isinstance(client, str) and re.match('^[0-9]+$', client):
            self.write(self.getCommand('tempban', cid=client, reason=reason))
            return
        elif admin:

src/b/i/big-brother-bot-HEAD/b3/parsers/iourt42.py   big-brother-bot(Download)
            return self.kick(client, reason, admin, silent)
        elif isinstance(client, str) and re.match('^[0-9]+$', client):
            self.write(self.getCommand('ban', cid=client, reason=reason))
            return
        elif not client.id:
            # ban by ip, this happens when we !permban @xx a player that is not connected
            self.debug('EFFECTIVE BAN : %s',self.getCommand('banByIp', ip=client.ip, reason=reason))
            self.write(self.getCommand('banByIp', ip=client.ip, reason=reason))
        else:
            # ban by cid
                cmd = self.getCommand('auth-permban', cid=client.cid)
                self.info('sending ban to Frozen Sand : %s' % cmd)
                rv = self.write(cmd)
                if rv:
                    if rv == "Auth services disabled" or rv.startswith("auth: not banlist available."):
                cmd = self.getCommand('ban', cid=client.cid, reason=reason)
                self.info('sending ban to server : %s' % cmd)
                rv = self.write(cmd)
                if rv:
                    self.info(rv)
            return self.kick(client, reason, admin, silent)
        elif isinstance(client, str) and re.match('^[0-9]+$', client):
            self.write(self.getCommand('tempban', cid=client, reason=reason))
            return
        elif admin: