diff --git a/botconfig.py.example b/botconfig.py.example index 79c1794..7f857df 100644 --- a/botconfig.py.example +++ b/botconfig.py.example @@ -3,6 +3,8 @@ CHANNEL = "#mywolfgame" HOST = "irc.freenode.net" PORT = 6667 USERNAME = "" # for authentication, can be left blank if same as NICK +OPERUSER = "OPPER user" +OPERPASS = "OPER password" NICK = "mywolfbot" CMD_CHAR = "!" CHANGING_HOST_QUIT_MESSAGE = "Changing host" diff --git a/modules/common.py b/modules/common.py index fdc825f..ed211f4 100644 --- a/modules/common.py +++ b/modules/common.py @@ -97,6 +97,8 @@ hook = decorators.generate(HOOKS, raw_nick=True, permissions=False) def connect_callback(cli): def prepare_stuff(*args): + cli.send("OPER", botconfig.OPERUSER, botconfig.OPERPASS) + cli.join(botconfig.CHANNEL) cli.msg("ChanServ", "op "+botconfig.CHANNEL)