]> jfr.im git - erebus.git/blobdiff - modules/twitch.py
test
[erebus.git] / modules / twitch.py
index fdd7b32ea7e5bcf07dcf3dcc8da296ca49d83929..ba7e81f5cede41ee80ee91fd12a2e28b43803cc8 100644 (file)
@@ -1,10 +1,10 @@
-# Erebus IRC bot - Author: Conny Sjoblom
+# Erebus IRC bot - Author: Erebus Team
 # Twitch URL Checker
 # This file is released into the public domain; see http://unlicense.org/
 
 # module info
 modinfo = {
-       'author': 'Conny Sjoblom',
+       'author': 'Erebus Team',
        'license': 'public domain',
        'compatible': [1], # compatible module API versions
        'depends': [], # other modules required to work properly?
@@ -40,6 +40,6 @@ def privmsg_hook(bot, line):
                        respdata = urllib2.urlopen(url).read()
                        twitch = json.loads(respdata)
                        try:
-                               bot.msg(line.split()[2], 'Twitch: %s (%s)' % (twitch[0]['channel']['status'], twitch[0]['channel']['meta_game']))
+                               bot.msg(line.split()[2], 'Twitch: %s (%s playing %s)' % (twitch[0]['channel']['status'], twitch[0]['channel']['login'], twitch[0]['channel']['meta_game']))
                        except:
                                bot.msg(line.split()[2], 'Twitch: Channel offline.')