8000 GitHub - 1JanPeters/easy-sounds: Easy-Sounds Bot is a powerful Discord bot that allows users to set join sounds, delete sounds, rename sounds, and download and trim sounds from YouTube all from a text channel for a custom soundboard experience.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Easy-Sounds Bot is a powerful Discord bot that allows users to set join sounds, delete sounds, rename sounds, and download and trim sounds from YouTube all from a text channel for a custom soundboard experience.

License

Notifications You must be signed in to change notification settings

1JanPeters/easy-sounds

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Easy-Sounds Bot

Easy-Sounds Bot is a powerful Discord bot that allows users to set join sounds, delete sounds, rename sounds, and download and trim sounds from YouTube all from a text channel for a custom soundboard experience.

Features

  • Easy-to-Use Soundboard: Sounds are displayed as buttons in the designated channel, making it very easy to play sounds with a single click.
  • Set Join Sound: Users can set a custom sound to play when they join a voice channel.
  • Delete Sound: Administrators can delete sound files from the soundboard.
  • Rename Sound: Administrators can rename sound files.
  • Download and Trim from YouTube: Users can download and trim sounds from YouTube.
  • Upload Sounds Directly: Users can upload sound files directly to the designated text channel to add them to the soundboard.
  • Adjust Sound Volume: Users can modify the volume of sound files with a specified multiplier and optionally replace the original file.

Command Usage

  • /setjoinsound

    • Description: Set a sound to play when you join a voice channel.
    • Usage: /setjoinsound sound_name
  • /deletesound

    • Description: Delete a sound file from the soundboard.
    • Usage: /deletesound sound_name
  • /rename

    • Description: Rename a sound file.
    • Usage: /rename "old_name" "new_name"
  • /ytdlsound

    • Description: Download and trim a sound from YouTube. -n name -l link -s start HH:MM:SS.sss -e end HH:MM:SS.sss
    • Usage: /ytdlsound -n name -l link [-s start_time] [-e end_time]
  • /volume

    • Description: Change the volume of a saved sound. -n name -m multiplier [-r to replace original]
    • Usage: /volume -n name -m multiplier [-r]
  • /refresh

    • Description: Refresh the soundboard to update the button list.
    • Usage: /refresh

Installation

  1. Clone the repository:

    git clone https://github.com/1JanPeters/easy-sounds.git
    cd easy-sounds
  2. Create and activate a virtual environment:

    python3 -m venv venv
    source venv/bin/activate
  3. Install the dependencies:

    pip install -r requirements.txt
  4. Install ffmpeg:

    • On Linux (Debian-based systems like Ubuntu):
      sudo apt update
      sudo apt install ffmpeg
    • On macOS (using Homebrew):
      brew install ffmpeg
    • On Windows:
      • Download ffmpeg from ffmpeg.org.
      • Extract the files and add the bin directory to your system's PATH. (Refer to this guide for detailed instructions.)
  5. Copy the configuration template:

    • Copy config_template.json and save it as config.json.
    • Edit config.json and replace placeholders with your Discord bot token, guild ID, soundboard channel ID, and the full path to your sounds folder (e.g., /home/user/sounds, C:\Users\user\sounds).

Requirements

  • discord.py==2.3.2
  • moviepy==1.0.3
  • pynacl
  • yt-dlp
  • ffmpeg (must be installed on your system)

Creating and Setting Up the Discord Bot

  1. Go to the Discord Developer Portal.

  2. Click on "New Application" and give it a name.

  3. Navigate to the "Bot" section on the left sidebar and click on "Add Bot". Confirm by clicking "Yes, do it!".

  4. Under the "TOKEN" section, click "Copy" to copy your bot token. This will be used in your config.json file.

  5. Enable the "MESSAGE CONTENT INTENT" in the "Privileged Gateway Intents" section.

  6. Retrieve your APPLICATION_ID:

    • On the "General Information" page of your application, copy the "Application ID".
  7. Generate your bot's invite link:

    • Use the following URL format, replacing APPLICATION_ID with your application's ID:
      https://discord.com/oauth2/authorize?client_id=APPLICATION_ID&scope=bot&permissions=2150632448
      
    • Paste the generated URL into your browser, and invite the bot to your server.
  8. Retrieve your GUILD_ID:

    • Right-click on your server icon in Discord.
    • Click on "Copy ID".
  9. Create a text channel in your server for the soundboard and retrieve the SOUNDBOARD_CHANNEL_ID:

    • Right-click on the channel name.
    • Click on "Copy ID".
  10. Update your config.json file with the TOKEN, GUILD_ID, and SOUNDBOARD_CHANNEL_ID.

Usage

  1. Run the bot:

    python bot.py
  2. Use the following commands in Discord:

    • /setjoinsound sound_name: Set a sound to play when you join a voice channel.
    • /deletesound sound_name: Delete a sound file from the soundboard (admin only).
    • /rename "old" "new": Rename a sound file (admin only).
    • /ytdlsound -n name -l link -s start HH:MM:SS.sss -e end HH:MM:SS.sss: Download and trim a sound from YouTube. The -s (start) and -e (end) parameters are optional. If not provided, the entire audio will be used as the sound.
  3. Upload sound files directly to the soundboard:

    • Drag and drop your audio files (e.g., .mp3, .wav) into the designated text channel to add them to the soundboard.

Disclaimer

This bot allows users to download and trim audio from YouTube. Users are responsible for ensuring they have the right to download and use the content in accordance with YouTube's Terms of Service. The developers of this bot are not responsible for any misuse of the tool.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Third-Party Libraries

About

Easy-Sounds Bot is a powerful Discord bot that allows users to set join sounds, delete sounds, rename sounds, and download and trim sounds from YouTube all from a text channel for a custom soundboard experience.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

0