GLaDOS/main.py

25 lines
472 B
Python
Executable File

#!/usr/bin/env python3
import sys
import time
from threading import Thread
from bot import Bot
glados = Bot(
('irc.planet-casio.com', 6697),
('127.0.0.1', 5555),
["#general", "#glados"]
)
@glados.irc.on(lambda m: "Hello" in m.text)
def say_hello(msg):
glados.irc.send(msg.to, f"Nice to see you, {msg.author}")
@glados.v5.on(lambda c, m: True)
def announce(channels, message):
for c in channels:
glados.irc.send(c, message)
glados.start()