$setUserRoles
Overrides all roles of the given user.
Syntax
$setUserRoles[User ID;Role ID;...]
Parameters
User ID
(Type: Snowflake || Flag: Required)
: ID of the user to set the role.Role ID
(Type: Snowflake || Flag: Required)
: Roles to be given to the user. Separate roles using;
.
Example
- Create two commands and set the trigger
!example
for one command and!roles
for the other. (!roles
is not required)
- Code with trigger
!example
:
$nomention
$setUserRoles[$authorID;$roleID[Support]]
We've reset all your roles! Now you have "Support" role.
- Code with trigger
!roles
:
$nomention
$userRoles[$authorID]
BDFD
Moderator
In this example, we will remove all roles and give one role with “Support” name.
How $roleID[]
, $authorID
and $userRoled[]
works?