Skip to content
This repository has been archived by the owner on Jun 23, 2022. It is now read-only.

minor update to music cog #136

Open
wants to merge 11 commits into
base: main
Choose a base branch
from
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,5 @@ src/cogs/redditSettings.py
.DS_Store

#lavalink stuff
./lavalink/*
*.jar
logs/
9 changes: 9 additions & 0 deletions lavalink/Lavalink.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Lavalink Setup guide

#### downloading,installing and running lavalink
- Head over to [lavalink repo](https://github.com/freyacodes/Lavalink#server-configuration) and give it a star for all the hard work the devs are doing.
- Edit the `application.yml` file if you want to change the id/password and make sure to save it.
- Install [Java 17(windows)](https://download.oracle.com/java/17/latest/jdk-17_windows-x64_bin.exe) or **Java 13 and above** on the machine you are running lavalink on.
- Download [Lavalink.jar](https://ci.fredboat.com/viewLog.html?buildId=lastSuccessful&buildTypeId=Lavalink_Build&tab=artifacts&guest=1) and place it here or move this folder somewhere else.
- open your cmd / terminal and change directory to this one using `cd`.
- run: `java -jar Lavalink.jar`.
5 changes: 3 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
disnake>=2.1.0
disnake>=2.4.0
aiohttp>=3.7.0,<3.9.0
odmantic>=0.3.4
disnake-jishaku>=2.6.5
Expand All @@ -11,4 +11,5 @@ cryptography>=36.0.1
simpleeval>=0.9.11
praw
prawcore
Stealthy-wavelink
Stealthy-wavelink
humanize
13 changes: 12 additions & 1 deletion src/cogs/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
Context,
PrivateMessageOnly,
NoPrivateMessage,
BadUnionArgument
)
from disnake import Embed, Color
from disnake.ext.commands.errors import CommandNotFound, RoleNotFound, NotOwner
Expand Down Expand Up @@ -172,7 +173,17 @@ async def on_command_error(self, ctx: Context, error: Exception):
return

elif isinstance(error, NoChannelProvided):
return await ctx.send('You must be in a voice channel or provide one to connect to.')
return await ctx.send(embed=Embed(
description=f"You must be in a voice channel or provide one to connect to.",
color=Color.red(),
)
)
elif isinstance(error, BadUnionArgument):
return await ctx.send(embed=Embed(
description=f"Could not find the track requested!",
color=Color.red(),
)
)
else:
await ctx.send(
"An unexpected error occurred! Reporting this to my developer..."
Expand Down
1 change: 1 addition & 0 deletions src/cogs/fun.py
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,7 @@ async def loser(self, ctx, member: Member = None) -> None:
text=f"sent by {ctx.author.name}",
icon_url=ctx.author.display_avatar.url
)
await ctx.send(embed=embed)


def setup(bot: Jarvide) -> None:
Expand Down
Loading