public class ChatRaids extends PircBot{
boolean initialize = true;
public ChatRaids() {
this.setName("twitchraidstwitch");
}
public static void main(String[] args) throws Exception {
ChatRaids bot = new ChatRaids();
bot.setVerbose(true);
ChatRaids wBot = new ChatRaids();
wBot.setVerbose(true);
bot.connect("irc.twitch.tv", 6667, "oauth:XXXXXXXXXXX");
wBot.connect("199.9.253.119", 6667, "oauth:XXXXXXXXXXXX");
bot.joinChannel("#twitchraidstwitch");
}
public void capReq(){
sendRawLine("CAP REQ :twitch.tv/membership\r\n");
sendRawLine("CAP REQ :twitch.tv/tags\r\n");
sendRawLine("CAP REQ :twitch.tv/commands\r\n");
}
public void onMessage(String channel, String sender, String login, String hostname, String message) {
if(initialize){
capReq();
initialize=false;
sendMessage("#twitchraidstwitch", "/w Murderouskirk Hi "+host+"! Test msg.");
}
}
edit*
Looks like my commands break when I capReq(); too.
1452080991241 :murderouskirk!murderouskirk@murderouskirk.tmi.twitch.tv PRIVMSG #twitchraidstwitch :!rank
turns into something much longer and it fails to react accordingly.
Seems like I need to totally differentiate the wBot in order to accomplish this somehow… another class maybe?
Would it be more straightforward to just learn how to send a message?
also I can’t reply anymore today and my alt account gets flagged so…
I’m going to do some research. I think I just made a basic java rookie mistake by putting everything in one long class. I think I’m failing to differentiate my objects properly. Hopefully I can figure out how to separate this.
I appreciate the help everyone!