'Telnet method called when non-telnet-command data is coming in
over the telnet connection. We pass it on to the game engine
directly.
Args:
data (str): Incoming data.'

def applicationDataReceived(self, data):

    if (not data):
        data = [data]
    elif (data.strip() == NULL):
        data = [_IDLE_COMMAND]
    else:
        data = _RE_LINEBREAK.split(data)
        if (self.line_buffer and (len(data) > 1)):
            data[0] = (self.line_buffer + data[0])
            self.line_buffer = ''
        self.line_buffer += data.pop()
    for dat in data:
        self.data_in(text=(dat + '\n'))
