Skip to content

$advanceCooldown

$advanceCooldown will set a cooldown for a given ID.

Usage

$advanceCooldown[time;id;errorMessage]
  • You can retrieve the remaining cooldown in the $cooldown function by using %time% or any of the below.
    • %time% %year% %month% %week% %day% %hour% %min% %sec% %ms% %fullTime%

Parameters

FieldTypeDescriptionRequired
timestringThe duration of the cooldown.true
idnumberThe Id of a user, role or anything else.true
errorMessagestringError message to be displayed when there’s cooldown remaining.true

Example(s)

This will set a cooldown for the guild where you execute the command and return the remaining cooldown time:

1
client.command({
2
name: "advanceCooldown",
3
code: `
4
$advanceCooldown[2m;$guildID;Please wait %time% to execute this command again.]
5
`
6
});