Variables
getRoleVar
$getRoleVar — Value of a variable stored for a role (one value per role of the bot). The default is returned when nothing is stored.
Value of a variable stored for a role (one value per role of the bot). The default is returned when nothing is stored.
Syntax
$getRoleVar[name;roleID;(default)]
Parameters
- name (String, required) — Variable name
- roleID (String, required) — Role ID
- default (String, optional) — Value returned when the variable is empty
Return Value
- String.
Usage
$getRoleVar[name;roleID;default] → result
Example
$sendMessage[$getRoleVar[name;roleID;default]]
Try it
Paste an example into the playground to preview its message (functions that act on Discord are not run), or build the same thing with blocks.