Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- emb = discord.Embed(description=f'{ctx.author.mention}, что-бы забрать прибыль, придётся подождать ещё: `{round(h)}ч {round(m)}м {round(s)}сек`', color=0xa697ff)
- emb.set_thumbnail(url=ctx.author.avatar_url)
- emb.set_author(name=f"👷🏻♂️ Работа", icon_url='https://i.ibb.co/2ZRbtqv/1565.png')
- emb.set_footer(text=f'🚀 Вы можете использовать бустер , что-бы сократить время ожидание.', icon_url=strela)
- em1 = self.client.get_emoji(881769449047326750)
- one = Button(style = ButtonStyle.gray, label = 'Использовать ускоритель ', id='1' , emoji=em1)
- components1 = [one]
- await ctx.message.delete()
- await ctx.send(embed = emb, components=[components1])
- while True:
- try:
- responce = await self.client.wait_for('button_click', check = lambda message: message.author == ctx.author, timeout=30)
- if responce.component.id == '{}'.format(1):
- emojiFromServer = self.client.get_emoji(881769449047326750)
- msg2 = await ctx.send(content=f"Вот эмоджи {emojiFromServer}")
- menu1 = SelectOption(label=f'Бустер на 15 минут ',value='m1', description='Ускоряет время ожидание на 15 минут', emoji=f"{emojiFromServer}")
- menu2 = SelectOption(label='Второй итем',value='m2', description='Alle Infos zum GlobalMint-Bot', emoji='🌸')
- msg = await ctx.send(
- "Выберите придмет который вы хотите использовать",
- components=[
- SelectMenu(custom_id="test",placeholder="Только 1 придмет",max_values=1, options=[menu1, menu2])])
- # Wait for someone to click on it
- inter = await msg.wait_for_dropdown()
- # Send what you received
- labels = [option.value for option in inter.select_menu.selected_options]
- await inter.reply(f"Options: {', '.join(labels)}")
- except asyncio.TimeoutError as e:
- # message = await ctx.channel.fetch_message(message_id)
- # embed77.set_footer(text=f'Время ожидания закончилось.', icon_url=ctx.author.avatar_url)
- await responce.edit_origin(components=[])
Advertisement
Add Comment
Please, Sign In to add comment