-
Notifications
You must be signed in to change notification settings - Fork 2
Role Management Plugin
The role management plugin provides commands and features for the role management on the server. It provides self-assignable roles and roles which can be assigned by users with a corresponding mod role (or both).
For command list, see command reference page.
User can add or remove self-assignable roles by theirselfs via adding or removing the reaction for the role. Users with a mod role can add or remove the user to their corresponding roles via !role <user> <add|del> <role>. Admins can use this command for all roles the bot can add or remove to/from users.
If a user wants a role with a mod role, it can request it via !role request <role>. The command mentions the corresponding mod role, that the requesting user wants the role.
The !role add <role_name> [emoji|modrole] [color] command provides some features to add a role to the server. If a role with the given name already exists on the server, the role data will be added to the role management. If a role should be self-assignable via reaction and has a corresponding mod role, the command must be executed for both, first with the emoji for the reaction and then with the mod role or vice versa. The color argument on the command is only relevant if the role doesn't exists on the server. It can be a color name like 'blue' or a hexcode like '#0000ff'. It defines the color for the role.
All roles in the role management will be added to the init message with its reactions and mod roles data. If the init message doesn't exists, it will be generated automatically while adding or removing a role or updating the role management. The init message will be posted in the channel which is setted as announcements channel in the geckarbot.json system config.
The command !role del <role> can be used. It deletes the role on the server and the role management. If the role is already deleted on the server, the command will fail, because it wants a existing role. Roles which are deleted on the server can be removed from the bot management via !role update command. The update command removes all roles from the role management which aren't existing on the server and also removes deleted emojis and updates the reactions and the init message.
If a role should only be removed from role management, but not from server, !role untrack <role> can be used.
The init message will be automatically updated on adding or removing a role to/from server. The bot adds or removes the reactions for the self-assignable roles automatically, so the users can add their reaction easily. Reactions which aren't used for roles will be completely removed on every message update. The update can be forced via !role update [message_content] command. If a message content is given on the update command, the given message will be used as text for the init message.
In the role management configuration will be saved:
- The init message channel id and message id
- The init message text
- The role ids of the managed roles and their emojis and mod role ids