From 40c872883c2d2aa728b4cf57ef390e305844f3ee Mon Sep 17 00:00:00 2001 From: YoOriginal Date: Thu, 27 Apr 2017 20:06:51 +0530 Subject: [PATCH] Update subroom.lua --- subroom.lua | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/subroom.lua b/subroom.lua index 53ed5f5..ce4cc2b 100644 --- a/subroom.lua +++ b/subroom.lua @@ -48,6 +48,14 @@ function OnStartup() sLogFile = "nsfw.txt", sSubscribersFile = tConfig.sPath.."texts/".."nsfwSub.txt", }, + ["#[Random]"] = { + tSubscribers = { tModerators = {} }, + tChatHistory = {}, + sBotDescription = "Chatroom for Everything else.", + sBotEmail = "do.not@mail.me", + sLogFile = "random.txt", + sSubscribersFile = tConfig.sPath.."texts/".."randomSub.txt", + }, } dofile( tConfig.sPath..tConfig.sDepPath..tConfig.sPickleFile ) for sBotName, tInfo in pairs( tRooms ) do @@ -193,6 +201,9 @@ function SendToSubscribers( sSelfNick, sRoomName, sIncoming, bNotice ) if sRoomName == "#[NSFW]" and not bNotice then sIncoming = ""..sIncoming:match "%b<>(.*)" end + if sRoomName == "#[Random]" and not bNotice then + sIncoming = ""..sIncoming:match "%b<>(.*)" + end for iIndex, sNick in ipairs( tRooms[sRoomName].tSubscribers ) do if sNick:lower() ~= sSelfNick:lower() then Core.SendToNick( sNick, sRawString:format(sNick, sRoomName, sIncoming) )