summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--alternativ_nick.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/alternativ_nick.py b/alternativ_nick.py
index e7d6a26..61dc43d 100644
--- a/alternativ_nick.py
+++ b/alternativ_nick.py
@@ -70,6 +70,15 @@ nickname_in_use.event = '433'
nickname_in_use.thread = False
+def nick_change(phenny, input):
+ # Monitor the NICK changes to detect, if we change our nick.
+ if input.nick == phenny.nick:
+ _set_nick(phenny, input)
+ print >> sys.stderr, ("Changed nick to: %s" % phenny.nick)
+nick_change.rule = r'(.*)'
+nick_change.event = 'NICK'
+
+
def connected(phenny, input):
# The '001' event is the first message after establishing the connection
# and providing a valid NICK and USER. If we used an alternativ nick, we