-
-
Notifications
You must be signed in to change notification settings - Fork 240
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
VoiceClient not working for me #904
Comments
which operating system are you using for your bot? |
Windows 10 x64 |
can you try again with current dev-master? |
I use normal master
|
Remove 'pmChannels' from your Discord options, it is no longer available in v10 $discord = new Discord([
'pmChannels' => ... // remove this
]); |
My bot run successfully |
is your bot verified? is the command a message one without mention or through slash? do you have message_content intent enabled? |
My bot not verified, i don't have any slash command and message_content is enabled |
is it also enabled in the intents defined in the options for $discord = new Discord()? (See #905) |
i see the following issue, but if my bot return empty, then why functions like join voice not working |
I don't have any such issues as you described above, also, in regards to joining a voice channel, nothing really changed, so this should simply work, even on your 7.3.3, show me your discord construct (without the token) |
include __DIR__ . '/vendor/autoload.php';
require_once('secret.php');
$GLOBALS['prefix'] = '.';
$token = get_token();
$discord = new Discord([
'token' => $token,
'loadAllMembers' => false,
'storeMessages' => false,
// 'pmChannels' => false
// 'dnsConfig' => '8.8.8.8'
]);
$discord->on('ready', function(Discord $discord){
echo "Bot is online";
});
$discord->on('ready', function($discord) {
$activity = $discord->factory(Activity::class, [
'name' => 'KC',
'type' => Activity::TYPE_COMPETING
]);
$discord->updatePresence($activity, false, "idle", false);
});
$discord->on('error', function ($e) {
echo emit('udp-error', [$e]);
});
$discord->run(); |
@Dark-night45 Hello, I know it's late but I updated my Hiro-Bot and commands were not worked for me too. I fixed with adding intent, 'Intents::MESSAGE_CONTENT'. Example from my bot: $bot = new Hiro([
'token' => $_ENV['TOKEN'],
'prefix' => $_ENV['PREFIX'],
'shardId' => $shard_id,
'shardCount' => $shard_count,
'caseInsensitiveCommands' => true,
'loadAllMembers' => true,
'intents' => Intents::getDefaultIntents() | Intents::GUILD_MEMBERS | Intents::MESSAGE_CONTENT
]); I'm seeing you're not using intents so you can fix that with adding this to array: 'intents' => Intents::getDefaultIntents() | Intents::GUILD_MEMBERS | Intents::MESSAGE_CONTENT If you don't wanna to use GUILD_MEMBERS intent, 'intents' => Intents::getDefaultIntents() | Intents::MESSAGE_CONTENT this is works too. |
Had the same issue. Promise seemed stuck in an unresolved state after UDP connection was established (event listeners for the voice status change never fired). Updating the library to current dev-master resolved the issue. Seems like those events are no longer emitted on version pre 10.0-RC. |
Environment
Description
I have problem with play music from file in voice
when i run command, bot joined to voice but no sound.
in console i don't get any error. also i use debug code but no error.
i have all requirements too but file not played in voice.
Code :
Edit : Update discordphp version
The text was updated successfully, but these errors were encountered: