lines = [
'Play audio from a URL:',
'```',
- 'play URL [in CHANNEL]',
+ 'play URL',
+ 'play URL in CHANNEL',
+ 'play URL to MEMBER',
'```',
- 'If you do not specify a #channel I will play to the channel you are in.'
+ 'If you do not specify a #channel I will play to the channel you are in.',
+ "If you specify `to` a user I will play to that user's channel instead."
]
await bot.say_many(message.channel, lines)
voice = bot.parse_channel(param, author = message.author, text_ok = False)
if voice is not None:
ok = True
+ elif arg in ['for', 'to']:
+ if param is not None:
+ if param == 'me':
+ voice = bot.voice_channel_for_user(message.author)
+ else:
+ user = await bot.parse_user(param, author = message.author)
+ if user is not None:
+ voice = bot.voice_channel_for_user(user)
+ if voice is not None:
+ ok = True
else:
# arg is lowercase!
url = args[i]