-
Notifications
You must be signed in to change notification settings - Fork 169
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
Get Guild Members #6
Comments
when i run it found out all GuildMembers are cached, Promise doesn't return results message.guild.members.fetch().then(() => message.guild.members.cache.forEach((member) => console.log(member.user.username))) sorry for your experience |
@andy-t-wang fetch() are not supported by userbot, therefore you have to use cached. |
if you look here the answer is correct this.guild.shard.send({
op: Opcodes.REQUEST_GUILD_MEMBERS,
d: {
guild_id: this.guild.id,
presences,
user_ids,
query,
nonce,
limit,
},
}); |
Is there a way to get guild members using a user account?
This works for a regular bot but does not return anything when using a user account.
guild.members.fetch().then( (members) => members.forEach((member) => console.log(member.user.username)), (message) => console.log(message) )
The text was updated successfully, but these errors were encountered: