Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

It doesn't play anything #1

Open
Gentle-Ego opened this issue May 11, 2024 · 1 comment
Open

It doesn't play anything #1

Gentle-Ego opened this issue May 11, 2024 · 1 comment

Comments

@Gentle-Ego
Copy link

Gentle-Ego commented May 11, 2024

I tried the bot, but although all commands work perfectly the play one doesn't, I think that the problem is in:
search = await wavelink.YouTubeTrack.search(query=search, return_first=True)

because I tried some print() statements to see where the function blocks, and it blocks exactly before it:

@commands.command(name="play")
async def play_command(self, ctx: commands.Context, , search: str): #,
print("1, "+search)
search = await wavelink.YouTubeTrack.search(query=search, return_first=True)
print("2, "+search)

    if not ctx.voice_client:
        print("3")
        vc: wavelink.Player = await ctx.author.voice.channel.connect(cls=wavelink.Player)
        print("4")
    else:
        print("5")
        
        vc: wavelink.Player = ctx.voice_client
        print("6")

    #await vc.connect(ctx.author.voice.channel)
    print("7")
    await vc.play(search)
    print("8")
    
    mbed = discord.Embed(title=f"Music System", description=f"Now Playing {search}" ,color = THEME_COLOUR)
    await ctx.send(embed=mbed)

The only print I get is: 1, "search" that I choose for example Never Gonna Give You Up!

@Gentle-Ego
Copy link
Author

Nevermind I resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant