mirror of
https://github.com/MuRuLOSE/limoka.git
synced 2026-06-18 23:24:18 +02:00
Commited backup
This commit is contained in:
92
AlpacaGang/ftg-modules/spam.py
Normal file
92
AlpacaGang/ftg-modules/spam.py
Normal file
@@ -0,0 +1,92 @@
|
||||
# Copyright (C) 2019 The Raphielscape Company LLC.
|
||||
#
|
||||
# Licensed under the Raphielscape Public License, Version 1.c (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
|
||||
import asyncio
|
||||
from asyncio import wait, sleep
|
||||
|
||||
from userbot import BOTLOG, BOTLOG_CHATID, CMD_HELP
|
||||
from userbot.events import register
|
||||
|
||||
|
||||
@register(outgoing=True, pattern="^.cspam (.*)")
|
||||
async def tmeme(e):
|
||||
cspam = str(e.pattern_match.group(1))
|
||||
message = cspam.replace(" ", "")
|
||||
await e.delete()
|
||||
for letter in message:
|
||||
await e.respond(letter)
|
||||
if BOTLOG:
|
||||
await e.client.send_message(
|
||||
BOTLOG_CHATID, "#CSPAM\n"
|
||||
"TSpam was executed successfully")
|
||||
|
||||
|
||||
@register(outgoing=True, pattern="^.wspam (.*)")
|
||||
async def tmeme(e):
|
||||
wspam = str(e.pattern_match.group(1))
|
||||
message = wspam.split()
|
||||
await e.delete()
|
||||
for word in message:
|
||||
await e.respond(word)
|
||||
if BOTLOG:
|
||||
await e.client.send_message(
|
||||
BOTLOG_CHATID, "#WSPAM\n"
|
||||
"WSpam was executed successfully")
|
||||
|
||||
|
||||
@register(outgoing=True, pattern="^.spam (.*)")
|
||||
async def spammer(e):
|
||||
counter = int(e.pattern_match.group(1).split(' ', 1)[0])
|
||||
spam_message = str(e.pattern_match.group(1).split(' ', 1)[1])
|
||||
await e.delete()
|
||||
await asyncio.wait([e.respond(spam_message) for i in range(counter)])
|
||||
if BOTLOG:
|
||||
await e.client.send_message(BOTLOG_CHATID, "#SPAM\n"
|
||||
"Spam was executed successfully")
|
||||
|
||||
|
||||
@register(outgoing=True, pattern="^.picspam")
|
||||
async def tiny_pic_spam(e):
|
||||
message = e.text
|
||||
text = message.split()
|
||||
counter = int(text[1])
|
||||
link = str(text[2])
|
||||
await e.delete()
|
||||
await asyncio.wait([e.client.send_file(e.chat_id, link) for i in range(counter)])
|
||||
if BOTLOG:
|
||||
await e.client.send_message(
|
||||
BOTLOG_CHATID, "#PICSPAM\n"
|
||||
"PicSpam was executed successfully")
|
||||
|
||||
|
||||
@register(outgoing=True, pattern="^.delayspam (.*)")
|
||||
async def spammer(e):
|
||||
spamDelay = float(e.pattern_match.group(1).split(' ', 2)[0])
|
||||
counter = int(e.pattern_match.group(1).split(' ', 2)[1])
|
||||
spam_message = str(e.pattern_match.group(1).split(' ', 2)[2])
|
||||
await e.delete()
|
||||
for i in range(1, counter):
|
||||
await e.respond(spam_message)
|
||||
await sleep(spamDelay)
|
||||
if BOTLOG:
|
||||
await e.client.send_message(
|
||||
BOTLOG_CHATID, "#DelaySPAM\n"
|
||||
"DelaySpam was executed successfully")
|
||||
|
||||
|
||||
CMD_HELP.update({
|
||||
"spam":
|
||||
".cspam <text>\
|
||||
\nUsage: Spam the text letter by letter.\
|
||||
\n\n.spam <count> <text>\
|
||||
\nUsage: Floods text in the chat !!\
|
||||
\n\n.wspam <text>\
|
||||
\nUsage: Spam the text word by word.\
|
||||
\n\n.picspam <count> <link to image/gif>\
|
||||
\nUsage: As if text spam was not enough !!\
|
||||
\n\n.delayspam <delay> <count> <text>\
|
||||
\nUsage: .bigspam but with custom delay.\
|
||||
\n\n\nNOTE : Spam at your own risk !!"
|
||||
})
|
||||
Reference in New Issue
Block a user