|
|
@ -73,7 +73,6 @@ def add_commands(d): |
|
|
|
"mode", |
|
|
|
"mode", |
|
|
|
"nick", |
|
|
|
"nick", |
|
|
|
"part", |
|
|
|
"part", |
|
|
|
"kick", |
|
|
|
|
|
|
|
"who")) |
|
|
|
"who")) |
|
|
|
class IRCClient(object): |
|
|
|
class IRCClient(object): |
|
|
|
""" IRC Client class. This handles one connection to a server. |
|
|
|
""" IRC Client class. This handles one connection to a server. |
|
|
@ -234,8 +233,10 @@ class IRCClient(object): |
|
|
|
def notice(self, user, msg): |
|
|
|
def notice(self, user, msg): |
|
|
|
for line in msg.split('\n'): |
|
|
|
for line in msg.split('\n'): |
|
|
|
self.send("NOTICE", user, ":{0}".format(line)) |
|
|
|
self.send("NOTICE", user, ":{0}".format(line)) |
|
|
|
def quit(self, msg): |
|
|
|
def quit(self, chan, msg): |
|
|
|
self.send("QUIT :{0}".format(msg)) |
|
|
|
self.send("QUIT :{0}".format(msg)) |
|
|
|
|
|
|
|
def kick(self, chan, nick, msg): |
|
|
|
|
|
|
|
self.send("KICK", chan, nick, ":"+msg) |
|
|
|
def ns_identify(self, passwd): |
|
|
|
def ns_identify(self, passwd): |
|
|
|
self.msg("NickServ", "IDENTIFY {0} {1}".format(self.nickname, passwd)) |
|
|
|
self.msg("NickServ", "IDENTIFY {0} {1}".format(self.nickname, passwd)) |
|
|
|
def ns_ghost(self): |
|
|
|
def ns_ghost(self): |
|
|
|