Comments (5)
Thank you! I will get to work and make a bot with my friends to enjoy (and troll) with them! Thank you for your super-fast responses, I didn't expect it to be this fast tbh, but it's truly awesome. I'll make sure I send my ideas to you too, see you later! :)
from dingolingo.
Library version mismatch may've caused this. Try downgrading py-cord
to version 1.7.3
.
Alternatively, you can try my fork which is more up-to-date.
from dingolingo.
Thank you so much! I finally got it to work. I'm new to this whole coding thing, can you tell me if there's a way to add new commands (mostly misc. ones) and get them to work with this music bot as one? Or if I need to make a new cog, can you tell me how to make one? Thank you!
from dingolingo.
You can add new commands in BotFolder.musicbot.commands.music (or general) by using
@bridge.bridge_command(
name="commandName",
description="description but not a must have",
help="not a must have",
aliases=["this_works_too"],
)
async def _comandfunction(self, ctx: Context,):
your code
or you make a new file BotFolder.musicbot.commands.test
import discord
from config import config
from discord.ext import commands, bridge
from musicbot import linkutils, utils
from musicbot.bot import MusicBot, Context
class Test(commands.Cog):
def __init__(self, bot: MusicBot):
self.bot = bot
# logic is split to uconnect() for wide usage
@bridge.bridge_command(
name="commandName",
description="description but not a must have",
help="not a must have",
aliases=["this_works_too"],
)
async def _comandfunction(self, ctx: Context,):
your code
def setup(bot: MusicBot):
bot.add_cog(Test(bot))
and add
"musicbot.commands.test",
to initial_extensions in run.py
try to do the second approach so you can easily go back to the default untouched bot by just commenting out the "musicbot.commands.test", line ^^
*edit: this applies only to the DandelionMusic fork
from dingolingo.
Thank you so much! I finally got it to work. I'm new to this whole coding thing, can you tell me if there's a way to add new commands (mostly misc. ones)...
You're welcome. To make new commands you can inspect existing ones and create something similar. There are plenty of guides/examples online, like the one above.
If you think that these commands are useful to have in the bot, you can share your ideas by submitting an issue to my fork.
from dingolingo.
Related Issues (20)
- TypeError: Client.start() got an unexpected keyword argument 'bot' HOT 2
- Update requirements HOT 1
- Songs with colons (:) in their names causes the Bot to stop working. HOT 3
- missing 1 required keyword-only argument: 'intents' HOT 3
- Not Working on Heroku HOT 3
- Change discord-py to py-cord. HOT 1
- Running bot as .pyw prevents music from playing HOT 2
- Help HOT 2
- The bot doesn't play anything HOT 4
- Nothing gets added to queue HOT 3
- I can't use commands HOT 3
- I have a problem with intents HOT 3
- run.py is missing intents (.galex_ on discord)
- Cant play music: ClientException: ffmpeg was not found. HOT 1
- The bot responds to commands but does not play songs
- The above exception was the direct cause of the following exception: HOT 1
- Error: name 'Settings' is not defined
- Error when i opening run.py HOT 1
- The bot doesn't respond when I text it on the server. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dingolingo.