Nederlandse Copypasta functie

This commit is contained in:
Mark Hoekveen
2020-06-29 19:19:20 +02:00
parent 892ca5a843
commit d5e56e110c
+17
View File
@@ -77,6 +77,23 @@ class General(commands.Cog):
print("No permission to delete message")
yield from ctx.channel.send(ctx.author.mention + ' ' + post.url)
@commands.command(pass_context=True)
@asyncio.coroutine
def kopieerpasta(self, ctx):
""" iets schattigs... """
print(type(ctx.message.channel))
rkopieerpasta = self.r.subreddit('kopieerpasta')
post = rkopieerpasta.top('month', limit=250)
listing = list(post)
random.shuffle(listing)
post = listing[0]
try:
yield from ctx.message.delete()
except:
print("No permission to delete message")
yield from ctx.channel.send('**'+post.title+'**```'+post.selftext+'```')
@commands.command(pass_context=True)
@asyncio.coroutine
def gif(self, ctx, yt: str, start: str="0", duration: str="5", res: str="320", fps: int=10):