Skip to content

Guild Roles

nutmeg edited this page Feb 22, 2023 · 4 revisions

Run Down

Discord+PS improves on how guild roles can be used in a few ways

Role Count

Discord+PS' role count uses the guild's role cache so it may not be accurate until you restart the bot

PSClient.guild.roleCount(?guild);

Roles

PSClient.guild.roles() returns a list of all roles
Uses the guild's role cache so it may not update until you restart the bot

PSClient.guild.roles(?guild);

RoleF

RoleF is a function that lets you use every role in a server constantly updating although it's limited due to Discord.JS limitations

PSClient.guild.roleF( (roles) => {
	roles.forEach( (role) => {
		console.log(role.id);	
	});
});
Clone this wiki locally