How to make a discord bot using Python! Part 2: Discord.py Commands

  Рет қаралды 22,948

Code With Swastik

Code With Swastik

Күн бұрын

Пікірлер: 68
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Subscribe if you enjoyed! Comment below if you have doubts
@primedust1
@primedust1 4 жыл бұрын
I want to make the bot to run even though i have closed cmd
@vatot1295
@vatot1295 3 жыл бұрын
when ever i do anything it says No command found called ban/clear/kick...
@rudra3300
@rudra3300 3 жыл бұрын
ok
@zaaffe24bs16
@zaaffe24bs16 3 жыл бұрын
@@vatot1295 then add () at the end of client.command
@kawaranai6742
@kawaranai6742 3 жыл бұрын
How does one purge messages by a specific user?
@kupokinzyt
@kupokinzyt 4 жыл бұрын
Yu can open python thru cmd faster by going into the directory where the bot.py script is, and then in the taskbar up top of the file explorer (where you can type in), just simple type CMD. That will stop you from having to CD change everytime hehe
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Yup that's another way
@deianmihai8038
@deianmihai8038 4 жыл бұрын
can u send the code from this video I want to test it mine has a probleme and can't find it
@IronInspires
@IronInspires 3 жыл бұрын
first tutorial that works thank you so much
@louzynerd129
@louzynerd129 4 жыл бұрын
question, how can i make the bot respond to multiple word commands without underscores, because functions need underscores or just words stick together, i want it so that the bot can answer normal questions with spacing
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
You need to use sub commands for that, I'll be making a video on it soon
@louzynerd129
@louzynerd129 4 жыл бұрын
Code With Swastik thx
@rudra3300
@rudra3300 3 жыл бұрын
I wanted to make a bot that messages thank you whenever something is posted in the resources and notes channel as I am having a study server...... I did this @client.command() async def notes(ctx): await ctx.send("ThankYou for helping everyone....") but it didn't worked so How can I do that and it says Ignoring exception in command None: discord.ext.commands.errors.CommandNotFound: Command "notes" is not found
@parthivpedapati4485
@parthivpedapati4485 4 жыл бұрын
How do you stop running that bot!??!! It is sooo irritating to open and close the cmd again and again! 💢
@Vinaykumar-uk5jg
@Vinaykumar-uk5jg 3 жыл бұрын
do control c
@maevegfx7694
@maevegfx7694 4 жыл бұрын
Hi! I really love this series but I have problem with from discord.ext import commands - discord.ext is green underlined and it doesn't work. Could you please help me? 😀
@parthivpedapati4485
@parthivpedapati4485 4 жыл бұрын
In mine too it is, but it does work, just save it.
@PandoricGalaxy
@PandoricGalaxy 3 жыл бұрын
how to stop the bot like you did in 8:25
@zmados
@zmados 4 жыл бұрын
I have the same code as yours but mine reads it Letter by letter and only sends a letter instead of the sentence... do you know why that happens?
@mattivboiii
@mattivboiii 3 жыл бұрын
aliases doesn't work for me AT ALL
@whitelightmatei8398
@whitelightmatei8398 3 жыл бұрын
It says: Traceback (most recent call last): File "C:\Users\Matei Bolata Admin\Desktop\CreatorOfPeace\main.py", line 1, in import discord ModuleNotFoundError: No module named 'discord' How can I fix this? @Code With Swastik
@SfakAlex
@SfakAlex 3 жыл бұрын
open cmd and type "pip install discord"
@simplysem
@simplysem 4 жыл бұрын
im trying to make a bot and i can't seem to get the bot to send messages periodically, similar to the mee6 timed announcements. do you know the code to make the bot just send a message to the current channel?
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
You will have to use background tasks which I talked about in my latest video
@msrikarm3788
@msrikarm3788 4 жыл бұрын
is possible to use alliases twice?, if yes pls make a video
@muhammadshafeeq8779
@muhammadshafeeq8779 3 жыл бұрын
it is
@jitendraparmar3917
@jitendraparmar3917 3 жыл бұрын
How to do that without command prefix
@peanutbutter291
@peanutbutter291 4 жыл бұрын
Can you tell me how to call a function as a response for my bot?
@tarunthakur6091
@tarunthakur6091 2 жыл бұрын
Thanks it helped 🙂
@poojachaturvedi1361
@poojachaturvedi1361 4 жыл бұрын
I have a question in that rule topic, My question is this If I'm making public bot then what I have to write in that rule option?
@akcord7645
@akcord7645 3 жыл бұрын
U can leave the command
@KryptexDD
@KryptexDD 4 жыл бұрын
i tipe the code corect but wen i go to test it only rule on is showing. i meen wen i tipe .rule 1 is showing but wen i tipe .rule 2 is not showing why
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
There should be no spaces in the text file
@deianmihai8038
@deianmihai8038 4 жыл бұрын
It doesn't print anything I use Pycharm and it doesn't work
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Please don't use pycharm it's the worst for beginners
@deianmihai8038
@deianmihai8038 4 жыл бұрын
@@CodeWithSwastik I tried ti change but then it gives an eror in command prompt
@aradhyamathur6409
@aradhyamathur6409 4 жыл бұрын
Pls add your file link in description
@froyolan512
@froyolan512 4 жыл бұрын
if u close the vsc etc. will the bot go offline?
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Yes it will. You should get a hosting if you want to run the bot 24/7
@rbxless
@rbxless 4 жыл бұрын
When I try to do the command it gives me this error: Bot is ready Ignoring exception in command None: discord.ext.commands.errors.CommandNotFound: Command "rules" is not found This is my code: @client.command() async def rules(ctx): await ctx.send(rules)
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Don't name the command the same name as the list.
@rbxless
@rbxless 4 жыл бұрын
@@CodeWithSwastik Oh thank you!
@hid.op1470
@hid.op1470 3 жыл бұрын
Bot is offline when closing.py . Solutions ?? Pplzz
@YTMikeGames
@YTMikeGames 3 жыл бұрын
dont close your cmd prompt or py
@Melon21
@Melon21 4 жыл бұрын
it says parameter command_prefix unfilled..
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Did you add the command_prefix?
@1800_kam
@1800_kam 4 жыл бұрын
index error: can't fit int into a index sized integer.
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Whats the code?
@1800_kam
@1800_kam 4 жыл бұрын
@@CodeWithSwastik it works but it just keeps outputting that error
@xe9639
@xe9639 4 жыл бұрын
how do I do that txc file?
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Make a new file and save it with the file format .txt Also make sure to not have spaces between the lines in the txt file
@xe9639
@xe9639 4 жыл бұрын
@@CodeWithSwastik thanks!
@ralphzhyrosompoc5644
@ralphzhyrosompoc5644 4 жыл бұрын
is there a way to embed the rules? id like to know how
@Vinaykumar-uk5jg
@Vinaykumar-uk5jg 3 жыл бұрын
Yeah, go to discord.js.org . there, u can see how to embed
@ralphzhyrosompoc5644
@ralphzhyrosompoc5644 3 жыл бұрын
No need. I figured it out the day I asked that question plus I use python and not js. Thanks for the concern though
@Vinaykumar-uk5jg
@Vinaykumar-uk5jg 3 жыл бұрын
@@ralphzhyrosompoc5644 sorry, i used to code in js so it was in my mind .
@dhruvkabra5343
@dhruvkabra5343 2 жыл бұрын
bhai kha 15-25 like ki baat kr rhe ho yha apke 720 likes hogye
@sparkm
@sparkm 4 жыл бұрын
Thanks, dude
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Happy to help
@chanakyaks3936
@chanakyaks3936 4 жыл бұрын
Make chat bot too bruh
@CodeWithSwastik
@CodeWithSwastik 4 жыл бұрын
Sure 😁
@chanakyaks3936
@chanakyaks3936 4 жыл бұрын
@@CodeWithSwastik thanks Swastik
@softymods7743
@softymods7743 3 жыл бұрын
The name of your youtube channel is unfortunate
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН
黑天使只对C罗有感觉#short #angel #clown
00:39
Super Beauty team
Рет қаралды 36 МЛН
How Strong Is Tape?
00:24
Stokes Twins
Рет қаралды 96 МЛН
THE FUTURE OF DATA COMMUNICATION: TENDS TO WATCH!!
5:02
Varshit Kansal
Рет қаралды 89
How I make bots using python (educational)
17:12
Kian Brose
Рет қаралды 573 М.
I Scraped the Entire Steam Catalog, Here’s the Data
11:29
Newbie Indie Game Dev
Рет қаралды 813 М.
Germany | Can you solve this? | Math Olympiad
9:39
Master T Maths Class
Рет қаралды 1,9 М.
I Redesigned the ENTIRE YouTube UI from Scratch
19:10
Juxtopposed
Рет қаралды 1 МЛН
this BASH script will make you a MILLIONAIRE
19:20
NetworkChuck
Рет қаралды 734 М.
How is this Website so fast!?
13:39
Wes Bos
Рет қаралды 1,3 МЛН
How to make a Discord Bot using Python 2020! (Discord.py)
9:19
Code With Swastik
Рет қаралды 105 М.
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН