2010-11-11 17:49:07 -05:00
|
|
|
#!/usr/bin/python2
|
|
|
|
"""
|
|
|
|
botsnack.py - .botsnack module
|
|
|
|
author: mutantmonkey <mutantmonkey@gmail.com>
|
|
|
|
"""
|
|
|
|
|
|
|
|
import random
|
|
|
|
|
|
|
|
def botsnack(phenny, input):
|
|
|
|
messages = ["Om nom nom", "Delicious, thanks!"]
|
|
|
|
response = random.choice(messages)
|
|
|
|
|
2010-12-11 15:58:43 -05:00
|
|
|
botsnack.snacks += 1
|
|
|
|
|
|
|
|
if botsnack.snacks % 7 == 0:
|
|
|
|
phenny.say("Too much food!")
|
|
|
|
phenny.do("explodes")
|
|
|
|
else:
|
|
|
|
phenny.say(response)
|
2010-11-11 17:49:07 -05:00
|
|
|
botsnack.commands = ['botsnack']
|
|
|
|
botsnack.priority = 'low'
|
2010-12-11 15:58:43 -05:00
|
|
|
botsnack.snacks = 0
|
2010-11-11 17:49:07 -05:00
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
print __doc__.strip()
|
|
|
|
|