Answer the question
In order to leave comments, you need to log in
How to put different pictures in emb.set_image so that the bot would throw random ones?
My code
@client.command( pass_context = True)
@commands.has_permissions( administrator = True )
async def bong( ctx ):
emb = discord.Embed(description = f"{ctx.author.mention} *" )
emb.set_image(url=" https://i.gifer.com/75Uv.gif ")
await ctx.send( embed = emb)
Answer the question
In order to leave comments, you need to log in
you can see right away, I wrote off the fsoka
@client.command()
@commands.has_permissions( administrator = True )
async def bong( ctx ):
images = ['ссылка1', 'ссылка2', 'ссылка3'] # можно хоть бесконечно
emb = discord.Embed(description = f"{ctx.author.mention} **Жестко затянулся бонгом**")
url = random.choice(images)
emb.set_image(url)
await ctx.send(emb)
await ctx.send(embed=emb)
await ctx.send(emb)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question