Entity Info
isMentionable
$isMentionable
Checks if a role is mentionable. Returns "true" or "false".
Syntax
$isMentionable[roleID;(guildID)]
$isMentionable
The function $isMentionable checks if a Discord role is mentionable by server members. A mentionable role can be used in messages with @Role.
Syntax
$isMentionable[roleID;(guildID)]
Parameters
| Parameter | Description |
|---|---|
roleID |
The ID of the role. Required. |
guildID |
Optional. The ID of the target server. |
Return Value
| Type | Description |
|---|---|
string |
"true" if the role is mentionable, "false" otherwise. |
Examples
Check a role
$if[$isMentionable[$roleID[Announcements]]==true]
$sendMessage[The Announcements role is mentionable.]
$else
$sendMessage[The Announcements role is not mentionable.]
$endif
List mentionable roles
$sendMessage[The Admin role is $isMentionable[$roleID[Admin]].]
Alert if not mentionable
$if[$isMentionable[$roleID[Modo]]==false]
$sendMessage[⚠️ The Modo role is not mentionable. Members cannot ping it.]
$endif
Retrieve via $roleInfo
$sendMessage[Mentionable: $roleInfo[123456789012345678;mentionable]]
Notes
- Returns a string
"true"or"false". - Equivalent to
$roleInfo[roleID;mentionable]. - Useful for checking before sending a role mention.