Adding nft command to post dumb monkeys to the channel
This commit is contained in:
parent
38ea5a6fd8
commit
e594b9714c
22
app/bot.py
22
app/bot.py
@ -47,13 +47,13 @@ async def fix_cdn_url(ctx):
|
||||
await ctx.channel.send("%s said:\n%s" % (ctx.author.mention, ctx.content.replace('media.discordapp.net', 'cdn.discordapp.com')))
|
||||
return
|
||||
|
||||
@bot.listen('on_message')
|
||||
async def react_with_dale(ctx):
|
||||
if 'dale' in ctx.content.lower():
|
||||
emoji = discord.utils.get(ctx.guild.emojis, name='dale')
|
||||
if emoji:
|
||||
await ctx.add_reaction(emoji)
|
||||
return
|
||||
# @bot.listen('on_message')
|
||||
# async def react_with_dale(ctx):
|
||||
# if 'dale' in ctx.content.lower():
|
||||
# emoji = discord.utils.get(ctx.guild.emojis, name='dale')
|
||||
# if emoji:
|
||||
# await ctx.add_reaction(emoji)
|
||||
# return
|
||||
|
||||
@bot.listen('on_message')
|
||||
async def convert_heic_to_jpg(ctx):
|
||||
@ -483,6 +483,14 @@ async def flows(ctx):
|
||||
|
||||
await ctx.send(embed=result)
|
||||
|
||||
@bot.command(name='nft')
|
||||
async def nft(ctx):
|
||||
|
||||
import nft
|
||||
result = nft.get_nft()
|
||||
|
||||
await ctx.send(result)
|
||||
|
||||
@bot.command(name='8ball')
|
||||
async def eight_ball(ctx):
|
||||
|
||||
|
@ -108,6 +108,11 @@ def get_help_message(method):
|
||||
'help': [
|
||||
'Shows you this message'
|
||||
],
|
||||
'homepage': [
|
||||
'This function now outputs the SWEET-ASS picture of the day.',
|
||||
' Note this picture only changes once a day.',
|
||||
'\nUsage: !homepage'
|
||||
],
|
||||
'invite': [
|
||||
'Generates a one time use invite to the voice channel you are currently in.\n',
|
||||
'if you are not in a voice channel, the invite will be for whatever channel !invite was typed in.\n'
|
||||
@ -152,11 +157,10 @@ def get_help_message(method):
|
||||
'\nExamples of all templates can be seen here https://memegen.link/examples'
|
||||
'\n\nUsage: !meme doge top text; bottom text'
|
||||
],
|
||||
'homepage': [
|
||||
'This function now outputs the SWEET-ASS picture of the day.',
|
||||
' Note this picture only changes once a day.',
|
||||
'\nUsage: !homepage'
|
||||
],
|
||||
'nft': [
|
||||
'Polls opensea and gets a random monkey from bored ape yacht club',
|
||||
'\nUsage: !nft'
|
||||
]
|
||||
'owo': [
|
||||
'Returns some fucky wucky text\n',
|
||||
'Usage: !owo what the fuck did you just fucking say about me you little shit?'
|
||||
@ -221,7 +225,7 @@ def get_help_message(method):
|
||||
|
||||
def get_help_embed(bot):
|
||||
categories = {
|
||||
'fun': ['bf5', 'ffxiv', 'clap', 'youtube', 'excuse', 'greentext', 'lewd', 'message', 'meme', 'homepage', 'pout', 'roll', 'smug', 'owo', 'wink', 'verify', 'horny', 'wasted', 'simp', 'trackdays'],
|
||||
'fun': ['nft', 'bf5', 'ffxiv', 'clap', 'youtube', 'excuse', 'greentext', 'lewd', 'message', 'meme', 'homepage', 'pout', 'roll', 'smug', 'owo', 'wink', 'verify', 'horny', 'wasted', 'simp', 'trackdays'],
|
||||
'util': ['ask', 'corona', 'emoji', '8ball', 'decide', 'info', 'icon', 'wallpaper', 'stock', 'tts', 'issue'],
|
||||
'users': ['help', 'invite', 'purge', 'roles', 'source'],
|
||||
'pictures of animals': ['birb', 'redpanda', 'dale', 'dog', 'rat', 'koala', 'panda', 'raccoon', 'fox', 'cat', 'kangaroo'],
|
||||
|
9
app/nft.py
Normal file
9
app/nft.py
Normal file
@ -0,0 +1,9 @@
|
||||
import requests
|
||||
import random
|
||||
|
||||
|
||||
def get_nft():
|
||||
url = "https://api.opensea.io/api/v1/bundles?limit=50&asset_contract_address=0xbc4ca0eda7647a8ab7c2061c2e118a18a936f13d"
|
||||
x = requests.get(url).json()['bundles']
|
||||
|
||||
return random.choice(x)['assets'][0]['image_original_url']
|
Loading…
x
Reference in New Issue
Block a user