Functions

Language basics Templates

Who and where

  • $username Name of the person who used the command. In events, the person who joined, left, was banned or reacted. Empty in scheduled commands.
  • $userID ID of the person who used the command: a long number that never changes. Use it wherever another function asks for a user. Empty in scheduled commands.
  • $mention Mentions the person who used the command, so they get notified. Empty in scheduled commands.
  • $serverName Name of this server.
  • $memberCount How many members this server has.
  • $channelName[channel?] Name of the channel the answer goes to, or of another channel. Join and leave events answer in the server's system channel.
  • $message[word number?] Everything typed after the command, or just one word of it.
  • $messageFrom[word number] Everything typed after the command, starting at this word. Handy for a reason after a mention.
  • $messageWordCount How many words were typed after the command.

Answer

  • $reply Sends the answer as a reply to the command message, so everyone sees what it answers.
  • $react[emoji] Adds a reaction to the bot's answer.
  • $deleteCommand Deletes the message that started the command, so only the answer stays.
  • $answerAs[name;avatar url?] Sends the answer under another name and picture. The bot needs the Manage Webhooks permission. Names that look like staff or the server owner are refused.

Embed

Messages

Members

Moderation

Variables

Rules

Logic

  • $if[condition] Runs the lines below only when the condition is true. End the block with $endif.
  • $elseif[condition] Inside an $if block: another condition, checked only when the ones above were false.
  • $else Inside an $if block: runs the lines below when no condition above was true.
  • $endif Ends an $if block. Every $if needs one.
  • $stop Ends the command right here. Nothing below it runs.
  • $try Starts a safe block. If something in it fails, the command goes on at $catch instead of stopping with an error.
  • $catch Inside a $try block: runs the lines below only if something above failed.
  • $endtry Ends a $try block. Every $try needs one.
  • $error Inside $catch: what went wrong in the $try block.
  • $comment[text] A note for yourself. It never runs and nobody sees it.
  • $and[condition;condition...] true if all conditions are true, otherwise false.
  • $or[condition;condition...] true if at least one condition is true, otherwise false.
  • $not[condition] Turns true into false and false into true.
  • $sameText[text;text] true if both texts are the same, ignoring capital letters and spaces around them.

Text

Numbers

Lists

Time

Server

Events

  • $reactionEmoji The emoji someone reacted with. Works in reaction events and after $waitForReaction.
  • $oldText In the message edited event: the text before the edit. Empty if the message was older than the bot.
  • $newText In the message edited event: the text after the edit.
  • $deletedText In the message deleted event: the text of the deleted message, if Fluxer still had it.
  • $awaitedMessage In an awaited command: the text of the answer the bot waited for.
  • $reactToCommand[emoji] Adds a reaction to the message that started this, like the command message or the edited message.

Waiting for answers

Schedules

Web

Files

  • $attachFile[url;file name?] Downloads a file from a link and sends it with the answer, up to 8 MB. Each file counts as a web request.
  • $attachmentCount How many files are attached to the message that started the command.
  • $attachmentURL[number?] The link to a file attached to the message that started the command. Empty when there is no such file.
  • $attachmentName[number?] The name of a file attached to the message that started the command. Empty when there is no such file.

Threads