I want to recode my music bot (currently works with commands), so that a channel gets created. If you write any message in that channel, the bot is supposed to play the song from the message. For that I need to access stuff like voice_state, but on_message doesn't seem to provide that, while ctx does. Now I'm looking for any way to convert the message into a command, get ctx any other way or just access all the voice stuff somehow else.
Thanks in Advance.
There is, you can use Bot.get_context for this purpose. It's a coroutine.
example:
Positional arguments in command followed by keyword arguments. You don't need to provide
ctxargument asctx.invokesupplies that by default during command invocationand actually, no. You can use
message.guild.voice_clientfor accessing thevoice_client,ctx.voice_clientis a shortcut to that. Also, for accessing author's voice statemessage.author.voice, most of the things you do in context are shortcuts to Guild/Member object methods. There are some exceptions though.