Awaited reactions

(for premium bots)

Awaited reactions are similar to awaited commands. Unlike awaited commands which wait for a message, they wait for a reaction instead.

accept Do you accept? Accepted accept Do you accept? Declined

📝 Reaction roles are not possible at the moment since awaited reactions can only be triggered by the author and they expire whenever the bot goes offline.

Getting Started

To create an awaited reaction command, following functions and callback are used :

$awaitReactions[]

This function is used to await a reaction command.

Syntax

$awaitReactions[<Command name;Reaction>;...]

Parameters

  • Command name (Type: String || Flag: Required): It’s the name which will be used inside the $reaction[] callback.
  • Reaction (Type: Emoji || Flag: Required): It awaits the given emoji. Emoji must be either in Unicode or in Discord emoji ID format.

📝 You can group reactions by specifying more “command names” and “reactions” in $awaitReactions[].

⚠️ In group reactions, when one reaction is used, the others stop working i.e let’s say, a command awaits two reactions (✔️ & ❌). If the user reacts ✔️ then ❌ stops working.

$reaction[]

$reaction[] is a callback. It gets triggered whenever an awaited reaction occurs.

Syntax

$reaction[Name]

Parameters

  • Name (Type: String || Flag: Required): It’s the value which is used in the “command name” argument of $awaitReactions[].

$usedEmoji

This function is used to return the emoji which was triggered in the $reaction[] command.

Syntax

$usedEmoji

Example

Screenshot_20220809_194823 Screenshot_20220809_194754 Screenshot_20220809_194805

accept Do you accept? Accepted ✅