Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require'socket'
- a,p,c=$*
- s=TCPSocket.new a,p
- s.puts"USER "*5,"NICK d"
- while l=s.gets
- s.puts case l
- when /^.+ 001/
- "JOIN "+c
- when /-quit ?(.+)/
- "QUIT :"+$1
- when /(P.+?:)-(.+)$/
- $1+$2
- when /PING/
- l[?I]=?O
- l
- end
- end
Add Comment
Please, Sign In to add comment