Guest User

Untitled

a guest
Jul 16th, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.14 KB | None | 0 0
  1. if (inputLine.ToLower().Contains("privmsg "+CHANNEL.ToLower()))
  2. {
  3. string[] splitArray = inputLine.Split(new char[] { ':' });
  4. string[] splitArray2 = splitArray[1].Split(new char[] { '!' });
  5. string[] splitArray3 = splitArray2[1].Split(new char[] { ' ' });
  6. string compmsg = "";
  7. foreach (string msg in splitArray)
  8. {
  9. if (msg == "" || msg == splitArray[0] || msg == splitArray[1]) { }
  10. else if (compmsg == "") { compmsg = msg; }
  11. else { compmsg += ":" + msg; }
  12. }
  13. string nick = splitArray2[0];
  14. string host = splitArray3[0];
  15. string message = compmsg;
  16. if(nick.ToLower() == "predsrule")
  17. {
  18. writer.WriteLine("PRIVMSG " + CHANNEL + " :" + message);
  19. writer.Flush();
  20. }
  21. }
Add Comment
Please, Sign In to add comment