$If
If conditions meet in the 1st field, the code or message in the 2nd field will be executed.

FUNCTION USAGE

    $If[condition;execute]

Properties:

condition - The condition for the code to be executed. This field kind of acts like $onlyIf. execute - If condition meets, this field will execute code or a message.

Example: Throwing 3 commands into 1 command using $If.

1
bot.Command({
2
name: "test",
3
code: `
4
$If[$message[]==yes;no]
5
$If[$message[]==icon;$guildIcon]
6
$If[$message[]==reboot;$reboot[$client[mention] is rebooting...]]
7
`
8
})
Copied!
Last modified 3mo ago
Copy link
Contents
Properties: