This commit is contained in:
.[d]. 2021-03-07 00:57:55 -06:00
parent 40326a6d74
commit 20e6a13d80

View File

@ -45,6 +45,71 @@ class Plugin(object):
symbol = random.choice(list(open(symbol_db)))
return symbol
def __bok(self):
MSG=""
for i in range(random.randint(1,25)):
for _ in "bok":
for __ in range(random.randint(1,10)):
___ = random.randint(1,2)
if ___ == 1:
MSG+="b"
else:
MSG+="B"
for __ in range(random.randint(1,10)):
___ = random.randint(1,2)
if ___ == 1:
MSG+="o"
else:
MSG+="O"
for __ in range(random.randint(1,10)):
___ = random.randint(1,2)
if ___ == 1:
MSG+="k"
else:
MSG+="K"
__ = random.randint(1,2)
if __ == 1:
MSG+=""
else:
MSG+=" "
__ = random.randint(1,2)
for __ in "bu":
___ = random.randint(1,2)
if ___ == 1:
MSG+=__.upper()*random.randint(1,7)
else:
MSG+=__.lower()*random.randint(1,7)
if __ == 1:
MSG+=""
else:
MSG+=" "
__ = random.randint(1,2)
if __ == 1:
MSG+="bok"*randint(0,3)
else:
MSG+="BOK"*randint(0,3)
__ = random.randint(1,2)
if __ == 1:
MSG+=""
else:
MSG+=" "
for __ in "gock":
___ = random.randint(1,2)
if ___ == 1:
MSG+=__.upper()*random.randint(1,7)
else:
MSG+=__.lower()*random.randint(1,7)
__ = random.randint(1,2)
if __ == 1:
MSG+=""
else:
MSG+=" "
__ = random.randint(1,2)
if __ == 1:
MSG+="gok"*randint(0,3)
else:
MSG+="GOK"*randint(0,3)
def krylon(self):
if self.init == 0:
KRYLON_FILE.reverse()
@ -69,12 +134,24 @@ class Plugin(object):
if BOT.config['botnet'][_].nick == BOT.nick:
BID= _
MSG='{}: {} {} < {}'.format(NICK,SYMBOL,GREET,BID)
CHN='#sh0rtbus'
CHN=self.channel
MSG = self._Plugin__emoj(MSG)
BOT.privmsg(CHN,MSG)
if len(ONLINE_BOTS) == len(self.context.config.botnet):
self.krylon()
@irc3.event(irc3.rfc.PRIVMSG)
def on_privmsg(self, mask=None, data=None, **kw):
BOT=self.context
if "bok" in data.lower():
WHO = mask.nick
SYM = self._Plugin__symbol()
BOK = self._Plugin__bok()
CHN = self.channel
MSG='{}: {} {}'.format(WHO,SYM,BOK)
MSG = self._Plugin__emoj(MSG)
BOT.privmsg(CHN,MSG)
@irc3.event(irc3.rfc.CONNECTED)
def connected(self, **kw):
for _ in [x for x in self.context.config.botnet]: