c# - joining a twitch IRC channel -
my function should join channel doesn't response server. weird thing when join server response. somehow, when try join channel don't receive return.
private void join() { connection.writer.write("join #" + channelname.trim().tolower() + "\r\n"); console.writeline("join #" + channelname.trim().tolower() + "\r\n"); connection.writer.flush(); //debug code while (true) { while (connection.reader.peek() >= 0) { string line = connection.reader.readline(); if (line.contains("ping :")) { connection.writer.write("pong :" + line.substring(line.indexof("ping :") + 6) + "\r\n"); connection.writer.flush(); } console.writeline(line); } } }
edit:
it seems twitch doesn't do
"ping :"
but instead does
"ping "
weirdly changing doesn't seem fixing it. 1 of moments say. "my code working , don't know why."
have @ api. seems so, it's not easy valid login. u have trigger api @ points.
regards, k1ll3r8e