Giter VIP home page Giter VIP logo

autoroll's Introduction

AutoRoll Discord Bot

About

Little passion project of mine :) A discord bot that can (hopefully) do a little bit of everything!

.env file format (REQUIRED)

############################ General ############################ 

# Bot Token
TOKEN=""
# Optional development bot token (used for simultaneous development)
DEVTOKEN=""
# Setting this to TRUE will run the bot using the DEVTOKEN specified above
DEVMODE=FALSE
# Set bot's legacy command prefix
PREFIX="$"
# List of admin IDs for admin-only bot commands (CSV)
ADMINS=""

############################ Intents ############################ 

MESSAGES=FALSE
MEMBERS=FALSE
GUILDS=FALSE
VOICE_STATES=FALSE

autoroll's People

Contributors

joshuahuahua avatar imnel avatar

Stargazers

 avatar

Watchers

Kostas Georgiou avatar

autoroll's Issues

add auto afk listener

  • Log if the user has been afk in a voice channel for an extended period of time, assign afk role
  • If user is moved/moves to the "afk" channel, assign afk role

"Silenced" Manager

Admin command to manage "silenced" users.
When new user joins, notify admins that the user has been silenced - and provide a button to unsilence them.

/reload command

@client.slash_command()
@commands.is_owner()
async def reload(interaction : nextcord.Interaction):
    return
    if admin(interaction.user):
        await interaction.send('Reloading...')
        if platform.system() == 'Windows' and os.path.isfile('run.bat'):
            os.system('run.bat')
            quit()
        elif os.path.isfile('run.sh'):
            os.system('./run.sh')
            quit()
        else:
            await interaction.send('An error has occured')
    else:
        await interaction.send('You do not have permission to do that!')

General Config

Create config.json file and add more config options (add to .gitignore)

  • Admins
  • Prefix
  • Token

Misc Additions/Features

  • Add start time to startup message
  • Add returns to end of functions
  • Check descriptions
  • Create "/stats all" command (runs everything in the stats subcommand)
  • Move time remaining to time formtat function
  • Chage time function to use time.time() as opposed to just time() (and fix declaration)
  • Check spacing
  • Remove uneeded functions (and create issues if needed - with code snippets)
  • Move misc funtions into cog
  • add bot status
  • add debug switch + token
  • enforce .env structure

Add /help

@client.slash_command(description='Help Command')
async def help(interaction : nextcord.Interaction):
    # await support(interaction)
    # return
    
    embed = nextcord.Embed(
        title='Help Commands',
        description=f'Listing commands...',
        colour=nextcord.Colour.blue())
    embed.add_field(name='/ping', value='Will return "Pong" if the bot is online.', inline=False),
    embed.add_field(name='/roles <add/remove/list>', value='Commands relating to roles.', inline=False),
    embed.add_field(name='/no <keyword>', value='Creates a custom "No Bitches?" meme.', inline=False),
    await interaction.send(embed=embed)

Clean up files

  • .gitignore
  • .bat
  • .sh
  • .txt
  • .lnk
  • !run.bat
  • !run.sh
  • rename bot to bot.py

Convert to Dockerfile

    Yeah this is gross, since you only have 1 service you should be able to just build a docker container and have these like you've got in the docker file. Might have to still pass through the token as env vars or something. idk it works so fuck it

Originally posted by @imNel in #24 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.