Denizen Script Commands


Commands are always written with a '-' before them, and are the core component of any script, the primary way to cause things to happen.
Learn about how commands work in The Beginner's Guide.


Showing 1 out of 184 commands...
NameCooldown
Syntaxcooldown [<duration>] (global) (script:<script>)
Short DescriptionTemporarily disables an interact script for the linked player.
Full DescriptionTemporarily disables an interact script for the linked player.

Cooldown requires a type (player or global), a script, and a duration.
It also requires a valid link to a PlayerTag if using a non-global cooldown.

To cooldown non-interact scripts automatically, consider Command:ratelimit.

Cooldown periods are persistent through a server restart as they are saved in the 'saves.yml'.
Related Tags<ScriptTag.cooled_down[player]> Returns whether the script is currently cooled down for the player. Any global (...)
<ScriptTag.cooldown> Returns the time left for the player to cooldown for the script.
Usage Example
# Use to keep the current interact script from meeting requirements.
- cooldown 20m
Usage Example
# Use to keep a player from activating a script for a specified duration.
- cooldown 11h script:bonus_script
- cooldown 5s script:hit_indicator
Usage Example
# Use the 'global' argument to indicate the script to be on cooldown for all players.
- cooldown global 24h script:daily_treasure_offering
Groupcore
Sourcehttps://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/core/CooldownCommand.java#L25