Загрузка страницы

Discord Bot - The Complete Guide for Python - Part 1

Have you wanted to learn how to get started coding with Python but aren't sure where to start?

Well - I personally started with Discord bots - and it was a blast learning Python!

In this video - I go over how you can get everything set-up from installation to project creation, as well as environment set-up.

By the end of this video - you will have your very own working discord bot that you can use in either your private server, or our group server.

To add your bot to our group, first join by visiting:

https://www.discord.gg/fudstop

DEPENDENCIES FOR THIS PROJECT:

ANACONDA:

https://www.anaconda.com/

VISUAL STUDIO:

https://code.visualstudio.com/

PYTHON:

https://www.python.org/downloads/

DISCORD DEVELOPER PORTAL:

https://discord.com/developers/applications/1116168175881568316/bot

-----------BOT CODE SCRIPT TO GET STARTED------------------------
import disnake
from disnake.ext import commands

from config import token

intents = disnake.Intents.all()

class MyBot(commands.Bot):
def __init__(self, command_prefix, intents=intents):
super().__init__(command_prefix, intents=intents)

async def on_ready(self):
print(f"Bot is ready! Logged in as {self.user.name}")

async def on_message(self, message):
if message.author == self.user:
return

await self.process_commands(message)

bot = MyBot(command_prefix="!", intents=intents)
@bot.command()
async def hello(ctx):
await ctx.send("Hello, I'm a Discord bot!")

bot.run(token)

----------------------------------------------------------------------------------

I hope you find this video helpful, and hope it was able to help someone out there finally get started with coding!

Thanks for watching.

Видео Discord Bot - The Complete Guide for Python - Part 1 канала Charlie's Vids
Показать
Комментарии отсутствуют
Введите заголовок:

Введите адрес ссылки:

Введите адрес видео с YouTube:

Зарегистрируйтесь или войдите с
Информация о видео
8 июня 2023 г. 7:19:12
00:27:10
Яндекс.Метрика