command
out of 3897 meta-documentation entries...Name | command |
Event Lines | command
<command_name> command |
Triggers | when a player, console, or command block/minecart runs a Bukkit command. This happens before
any code of established commands, allowing scripts to 'override' existing commands. Note that for the sake of the event line, escaping is used, so 'bukkit:plugins' becomes 'bukkit&coplugins' |
Generated Examples | after command:
on command_name command: on command: after command_name command: |
Has Player | when source_type is player. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.command> returns the command name as an ElementTag.
<context.raw_args> returns any args used, unmodified as plaintext.
<context.args> returns a ListTag of the arguments.
<context.source_type> returns the source of the command. Can be: PLAYER, SERVER, COMMAND_BLOCK, or COMMAND_MINECART.
<context.command_block_location> returns the command block's location (if the command was run from one).
<context.command_minecart> returns the EntityTag of the command minecart (if the command was run from one).
|
Determine | "FULFILLED" to tell Bukkit the command was handled. |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Server |
Warning(s) | This event is to override existing commands, and should not be used to create new commands - use a command script instead. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/server/CommandScriptEvent.java#L27 |
Name | discordcommand |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordcommand (id:<bot>) [create/delete] (group:<group>) (name:<name>) (type:{slash}/user/message) (description:<description>) (options:<options>) |
Short Description | Manages Discord application commands. |
Full Description | Manages Discord application commands.
You can create a new command, edit the permissions of an existing command, or delete an existing command. To create (or delete) a command in a specific Discord guild, use the "group" argument. If not present, a global command will be created. NOTE: Global commands take up to an hour to register. When creating, both a name and description are required. Commands can be slash commands - activated via typing "/", message commands - activated by right-clicking a message, or user commands - activated by right-clicking a user. "Description" and "options" are only valid for slash commands. The "options" argument controls the command parameters. It is a MapTag of ordered MapTags that can sometimes hold ordered MapTags. It is recommended to use definemap or a data script key when creating commands. All option MapTags must have "type", "name", and "description" keys, with an optional "required" key (defaulting to true). The "type" key can be one of: STRING, INTEGER, BOOLEAN, USER, CHANNEL, ROLE, MENTIONABLE, NUMBER, ATTACHMENT. Additionally, the option map can include a "choices" key, which is a MapTag of ordered MapTags that have a "name" (what displays to the user) and a "value" (what gets passed to the client). Instead of choices, the option map can also include an "autocomplete" key controlling whether dynamic suggestions can be provided to the client (defaulting to false). See on discord command autocomplete. Editing application command permissions has been moved to the "Integrations" section in the server settings. Read more about it here: https://discord.com/blog/slash-commands-permissions-discord-apps-bots You DO NOT need to create a command on startup every time! Once a command is created, it will persist until you delete it. Using the "create" instruction on an existing command will update it. Commands and replies to interactions have limitations. See https://gist.github.com/MinnDevelopment/b883b078fdb69d0e568249cc8bf37fe9. See also Discord's internal API documentation for commands: https://discord.com/developers/docs/interactions/application-commands Generally used alongside discordinteraction The command should usually be ~waited for. See ~waitable. |
Related Tags | <entry[saveName].command> returns the DiscordCommandTag of a command upon creation, when the command is ~waited for.
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordCommandCommand.java#L40 |
Name | command unknown |
Event Lines | command unknown |
Triggers | when an unknown command is processed by the server. |
Generated Examples | on command unknown: |
Has Player | when source_type is player. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.message> returns an ElementTag of the message to be shown to the command sender.
<context.command> returns the command name as an Element.
<context.raw_args> returns any args used as an Element.
<context.args> returns a ListTag of the arguments.
<context.source_type> returns the source of the command. Can be: PLAYER, SERVER, COMMAND_BLOCK, or COMMAND_MINECART.
<context.command_block_location> returns the command block's location (if the command was run from one).
<context.command_minecart> returns the EntityTag of the command minecart (if the command was run from one).
|
Determine | ElementTag to change the message returned to the command sender.
"NONE" to cancel the message. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Group | Paper |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/UnknownCommandScriptEvent.java#L25 |
Name | discord application|slash|message|user command |
Event Lines | discord application|slash|message|user command |
Triggers | when a Discord user uses an application command. |
Generated Examples | after discord user command:
after discord slash command: |
Switches | for:<bot> to only process the event for a specified Discord bot.
channel:<channel_id> to only process the event when it occurs in a specified Discord channel. group:<group_id> to only process the event for a specified Discord group. name:<command_name> to only process the event for a specified Discord application command. Spaces are replaced with underscores. |
Contexts | <context.bot> returns the relevant DiscordBotTag.
<context.channel> returns the DiscordChannelTag.
<context.group> returns the DiscordGroupTag.
<context.interaction> returns the DiscordInteractionTag.
<context.command> returns the DiscordCommandTag.
<context.options> returns the supplied options as a MapTag.
|
Group | Discord |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/events/DiscordApplicationCommandScriptEvent.java#L8 |
Name | discord command autocomplete |
Event Lines | discord command autocomplete |
Triggers | when a Discord user queries a slash command option that can be autocompleted. |
Example |
|
Example |
|
Switches | for:<bot> to only process the event for a specified Discord bot.
channel:<channel_id> to only process the event when it occurs in a specified Discord channel. group:<group_id> to only process the event for a specified Discord group. name:<command_name> to only process the event for a specified Discord application command. Spaces are replaced with underscores. option:<option_name> to only process the event for a specified autocompletable option. |
Contexts | <context.bot> returns the relevant DiscordBotTag.
<context.channel> returns the DiscordChannelTag.
<context.group> returns the DiscordGroupTag.
<context.interaction> returns the DiscordInteractionTag.
<context.command> returns the DiscordCommandTag.
<context.options> returns the supplied options as a MapTag.
<context.focused_option> returns the name of the focused option.
|
Determine | "CHOICES:<ListTag>" to suggest values to the Discord client. Up to 25 suggestions are allowed to be sent. Each entry can be an ElementTag which controls both the value and display of the choice or a MapTag with "name" and "value" keys to control both separately. |
Group | Discord |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/events/DiscordCommandAutocompleteScriptEvent.java#L18 |
Name | player receives commands |
Event Lines | player receives commands |
Triggers | when the list of available server commands is sent to the player for tab completion. |
Generated Examples | after player receives commands: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.commands> returns a ListTag of received commands.
|
Determine | ListTag to set the player's available commands. NOTE: It is not possible to add entries to the command list, only remove them. |
Group | Player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/player/PlayerReceivesCommandsScriptEvent.java#L15 |
Name | proxy server command command |
Event Lines | proxy server (<command>) command |
Triggers | when a player runs a command on the bungee proxy server. |
Generated Examples | after proxy server command command: |
Has Player | when the player has been on this specific server before. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.sender> returns the name of the command sender.
<context.sender_id> returns the UUID of the command sender, if available.
<context.command> returns the command executed.
|
Determine | "COMMAND:<ElementTag>" to change the command that will be ran. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Group | Depenizen |
Requires | Depenizen, DepenizenBungee, BungeeCord |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/events/bungee/BungeeProxyServerCommandScriptEvent.java#L18 |
Name | /denizen debug command |
Description | Using the /denizen debug command interfaces with Denizen's debugger to allow control over debug messages.
To enable debugging mode, simply type '/denizen debug'. While debug is enabled, all debuggable scripts, and any invoked actions, will output information to the console as they are executed. By default, all scripts are debuggable while the debugger is enabled. To disable a script specifically from debugging, simply add the 'debug:' node with a value of 'false' to your script container. This is typically used to silence particularly spammy scripts. Any kind of script container can be silenced using this method. To stop debugging, simply type the '/denizen debug' command again. This must be used without any additional options. A message will be sent to show the current status of the debugger. Note: you should almost NEVER disable debug entirely. Instead, always disable it on a per-script basis. If debug is globally disabled, that will hide important error messages, not just normal debug output. There are also several options to further help debugging. To use an option, simply attach them to the /denizen debug command. One option, or multiple options can be used. For example: /denizen debug -sbi '-c' enables/disables color. This is sometimes useful when debugging with a non-color console. '-r' enables recording mode. See also: /denizen submit command '-s' enables/disables stacktraces generated by Denizen. We might ask you to enable this when problems arise. '-b' enables/disables the ScriptBuilder debug. When enabled, Denizen will show info on script and argument creation. Warning: Can be spammy. '-n' enables/disables debug trimming. When enabled, messages longer than 1024 characters will be 'snipped'. '-i' enables/disables source information. When enabled, debug will show where it came from (when possible). '-p' enables/disables packet debug logging. When enabled, all packets sent to players (from anywhere) will be logged to console. or, '--pfilter (filter)' to enable packet debug logging with a string contain filter. '-f' enables/disables showing of future warnings. When enabled, future warnings (such as upcoming deprecations) will be displayed in console logs. '-e' enables/disables extra output. This will spam more information about various internal things. '-v' enables/disables advanced ultra-verbose log output. This will *flood* your console super hard. '-o' enables/disables 'override' mode. This will display all script debug, even when 'debug: false' is set for scripts. '-l' enables/disables script loading information. When enabled, '/ex reload' will produce a potentially large amount of debug output. |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/DenizenCommandHandler.java#L93 |
Name | /denizen submit command |
Description | Use the '/denizen submit' command with '/denizen debug -r' to record debug output and post it online for assisting developers to see.
To begin recording, simply use '/denizen debug -r'. After that, any debug output sent to the console and any player chat will be added to an internal record. Once enabled, you should then fire off scripts and events that aren't working fully. Finally, you use the '/denizen submit' command to take all the recording information and paste it to an online pastebin hosted by the Denizen team. It will give you back a direct link to the full debug output, which you can view yourself and send to other helpers without trouble. There is no limit to the recording size, to prevent any important information from being trimmed away. Be careful not to leave debug recording enabled by accident, as it may eventually begin using up large amounts of memory. (The submit command will automatically disable recording, or you can instead just use '/denizen debug -r' again.) |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/DenizenCommandHandler.java#L53 |
Name | /ex command |
Description | The '/ex' command is an easy way to run a single denizen script command in-game.
'Ex' is short for 'Execute'. Its syntax, aside from '/ex' is exactly the same as any other Denizen script command. When running a command, some context is also supplied, such as '<player>' if being run by a player (versus the console), as well as '<npc>' if a NPC is selected by using the '/npc sel' command. By default, ex command debug output is sent to the player that ran the ex command (if the command was ran by a player). To avoid this, use '-q' at the start of the ex command. Like: /ex -q narrate "wow no output" The '/ex' command creates a new queue each time it's run, meaning for example '/ex define' would do nothing, as the definition will be lost immediately. If you need to sustain a queue between multiple executions, use '/exs' ("Execute Sustained"). A sustained queue will use the same queue on every execution until the queue stops (normally due to '/exs stop'). Be warned that waits will block the sustained queue - eg '/exs wait 10m' will make '/exs' effectively unusable for 10 minutes. Examples: /ex flag <player> test_flag:! /ex run npc_walk_script Need to '/ex' a command as a different player or NPC? Use The Player and NPC Arguments. Examples: /ex narrate player:<[aplayer]> 'Your health is <player.health.formatted>.' /ex walk npc:<[some_npc]> <player.cursor_on> |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/ExCommandHandler.java#L34 |
Name | /npc constant command |
Description | The /npc constants command configures a NPC's constants. Uses Denizen's ConstantTrait to keep track of
NPC-specific constants. This provides seamless integration with an assignment script's 'Default Constants' in which text variables can be stored and retrieved with the use of 'replaceable tags', or API. Constants set at the NPC level override any constants from the NPC's assignment script. Constants may be used in several ways: Setting, Removing, and Viewing To set a constant, all that is required is a name and value. Use the Bukkit command in the following manner: (Note the use of quotes on multi world values) /npc constant --set constant_name --value 'multi word value' Removing a constant from an NPC only requires a name. Note: It is not possible to remove a constant set by the NPCs Assignment Script, except by modifying the script itself. /npc constant --remove constant_name Viewing constants is easy, just use '/npc constant #', specifying a page number. Constants which have been overridden by the NPC are formatted with a strike-through to indicate this case. To reference a constant value, use the replaceable tag to get the NPCs 'constant' attribute. For example: <npc.constant[constant_name]>. Constants may also have other tags in their value, which will be replaced whenever the constant is used, allowing the use of dynamic information. |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/NPCCommandHandler.java#L117 |
Name | /npc pushable command |
Description | The '/npc pushable' command controls a NPCs Pushable Trait. When a NPC is 'pushable', the NPC
will move out of the way when colliding with another LivingEntity. Pushable NPCs have 3 different settings available: Toggled, Returnable, and Delay. When an NPCs Pushable Trait is toggled off, it will not function. Entities which collide may occupy the same space. To toggle pushable on or off, use the Bukkit command: /npc pushable -t Setting the NPC as 'returnable' will automatically navigate the NPC back to its original location after a specified delay. If not returnable, NPCs will retain their position after being moved. /npc pushable -r To change the delay of a returnable NPC, use the following Bukkit Command, specifying the number of seconds in which the delay should be. /npc pushable --delay # It is possible to use multiple arguments at once. For example: /npc pushable -t -r --delay 10 Note: If allowed to move in undesirable areas, the NPC may be un-returnable if the navigator cancels navigation due to being stuck. Care should be taken to ensure a safe area around the NPC. See also: 'pushable trait' |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/NPCCommandHandler.java#L36 |
Name | Command Script Containers |
Description | Command script containers allow you to register your own custom commands to the server.
This also allows the command to show up in the '/help' command, with some info on the command. Note that existing names or aliases from other plugins will be overridden. If you want to run a script at the same time as an existing command, see on command. The following is the format for the container. The required keys are 'name:', 'description:', 'usage:', and 'script:' All other keys can be excluded if unneeded. If you are not intentionally setting a specific value for the other keys, it is strongly recommended that you simply not include them at all. Please note that 'name:' is the true name of the command (written by users), and 'usage:' is for documentation in the '/help' command. These two options should almost always show the same name. Command scripts can be automatically disabled by adding "enabled: false" as a root key (supports any load-time-parseable tags).
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/CommandScriptContainer.java#L28 |
Name | Command Syntax |
Description | Almost every Denizen command and requirement has arguments after the command itself.
These arguments are just snippets of text showing what exactly the command should do, like what the chat command should say, or where the look command should point. But how do you know what to put in the arguments? You merely need to look at the command's usage/syntax info. Let's take for example:
Obviously, the command is 'animatechest'... but what does the rest of it mean? Anything in [brackets] is required... you MUST put it there. Anything in (parenthesis) is optional... you only need to put it there if you want to. Anything in {braces} is default... the command will just assume this if no argument is actually typed. Anything in <> is non-literal... you must change what is inside of it. Anything outside of <> is literal... you must put it exactly as-is. <#> represents a number without a decimal, and <#.#> represents a number with a decimal Lastly, input that ends with "|..." (EG, [<entity>|...] ) can take a list of the input indicated before it (In that example, a list of entities) An argument that contains a ":" (like "duration:<value>") is a prefix:value pair. The prefix is usually literal and the value dynamic. The prefix and the colon should be kept directly in the final command. A few examples: [<location>] is required and non-literal... you might fill it with a noted location, or a tag that returns one like '<player.location>'. (sound:{true}/false) is optional and has a default value of true... you can put sound:false to prevent sound, or leave it blank to allow sound. (repeats:<#>) is optional, has no clear default, and is a number. You can put repeats:3 to repeat three times, or leave it blank to not repeat. Note: Optional arguments without a default usually have a secret default... EG, the (repeats:<#>) above has a secret default of '0'. Also, you should never directly type in [], (), {}, or <> even though they are in the syntax info. The only exception is in a replaceable tag (EG: <npc.has_trait[<traitname>]> will take <npc.has_trait[mytrait]> as a valid actual usage) Highly specific note: <commands> means a block of commands wrapped in braces or as a sub-block... EG:
|
Group | Script Command System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/CommandRegistry.java#L45 |
Name | command_block |
Object | LocationTag |
Input | ElementTag |
Related Tags | <LocationTag.command_block> Returns the command a command block is set to.
|
Description | Sets the command of a command block. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L4910 |
Name | command_block_name |
Object | LocationTag |
Input | ElementTag |
Related Tags | <LocationTag.command_block_name> Returns the name a command block is set to.
|
Description | Sets the name of a command block. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L4893 |
Name | DiscordCommandTag |
Prefix | discordcommand@ |
Base Type | ElementTag |
Implements | FlaggableObject |
Identity Format | The identity format for Discord commands is the bot ID (optional), followed by the guild ID (optional), followed by the command ID (required).
For example: 1234 Or: 12,1234 Or: mybot,12,1234 |
Description | A DiscordCommandTag is an object that represents a created slash command on Discord, as a bot-specific reference.
This object type is flaggable. Flags on this object type will be stored in: plugins/dDiscordBot/flags/bot_(botname).dat, under special sub-key "__commands" |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordCommandTag.java#L25 |
Name | <&click[<click_command>].type[<type>]> |
Returns | ElementTag |
Description | Returns a special chat code that makes the following text execute the input command when clicked.
This tag must be followed by an <&end_click> tag. Available command types: OPEN_URL, OPEN_FILE, RUN_COMMAND, SUGGEST_COMMAND, COPY_TO_CLIPBOARD, or CHANGE_PAGE. For example: - narrate "You can <&click[https://denizenscript.com].type[OPEN_URL]>click here<&end_click> to learn about Denizen!" Note that this is a magic Denizen tool - refer to Denizen Text Formatting. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/TextTagBase.java#L84 |
Name | <&click[<click_command>]> |
Returns | ElementTag |
Description | Returns a special chat code that makes the following text execute the input command line value when clicked.
To execute a command "/" should be used at the start. Otherwise, it will display as chat. This tag must be followed by an <&end_click> tag. For example: - narrate "You can <&click[wow]>click here<&end_click> to say wow!" For example: - narrate "You can <&click[/help]>click here<&end_click> for help!" Note that this is a magic Denizen tool - refer to Denizen Text Formatting. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/TextTagBase.java#L67 |
Name | <discord_command[<command>]> |
Returns | DiscordCommandTag |
Description | Returns a Discord Command object constructed from the input value.
Refer to DiscordCommandTag. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/DenizenDiscordBot.java#L164 |
Name | <DiscordBotTag.command[<name>]> |
Returns | DiscordCommandTag |
Description | Returns the application command that best matches the input name, or null if there's no match. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordBotTag.java#L194 |
Name | <DiscordBotTag.commands> |
Returns | ListTag(DiscordCommandTag) |
Description | Returns a list of all application commands. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordBotTag.java#L141 |
Name | <DiscordCommandTag.description> |
Returns | ElementTag |
Description | Returns the description of the command. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordCommandTag.java#L199 |
Name | <DiscordCommandTag.id> |
Returns | ElementTag(Number) |
Description | Returns the ID of the command. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordCommandTag.java#L177 |
Name | <DiscordCommandTag.name> |
Returns | ElementTag |
Description | Returns the name of the command. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordCommandTag.java#L188 |
Name | <DiscordCommandTag.options> |
Returns | ListTag(MapTag) |
Description | Returns the option MapTags of the command. This is the same value as the one provided when creating a command, as documented in DiscordCommand. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordCommandTag.java#L210 |
Name | <DiscordGroupTag.command[<name>]> |
Returns | DiscordCommandTag |
Description | Returns the guild command that best matches the input name, or null if there's no match. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordGroupTag.java#L327 |
Name | <DiscordGroupTag.commands> |
Returns | ListTag(DiscordCommandTag) |
Description | Returns a list of all commands in the group. |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordGroupTag.java#L222 |
Name | <ElementTag.on_click[<command>]> |
Returns | ElementTag |
Description | Adds a click command to the element, which makes the element execute the input command when clicked.
To execute a command "/" should be used at the start. Prior to 1.19, leaving off the "/" would display the text as chat. This feature was removed as part of the 1.19 secure chat system. For activating interact script chat triggers (Chat Triggers), you can use the command "/denizenclickable chat SOME MESSAGE HERE" (requires players have permission "denizen.clickable") For that, instead prefer ElementTag.click_chat Note that this is a magic Denizen tool - refer to Denizen Text Formatting. |
Example |
|
Example |
|
Group | text manipulation |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitElementExtensions.java#L540 |
Name | <LocationTag.command_block_name> |
Returns | ElementTag |
Mechanism | LocationTag.command_block_name |
Description | Returns the name a command block is set to. |
Generated Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L3775 |
Name | <LocationTag.command_block> |
Returns | ElementTag |
Mechanism | LocationTag.command_block |
Description | Returns the command a command block is set to. |
Generated Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L3790 |
Name | <PlayerTag.tab_completions[<command>]> |
Returns | ListTag |
Description | Returns a list of all tab completions for the given plaintext of a command.
Input is formatted equivalent to if it were typed into a chat bar, minus the '/' slash at the start. Input must necessarily contain at least one space. For example: "<player.tab_completions[npc ]>" will return all /NPC sub command names available to the player. This is only compatible with commands registered in Spigot. Meaning in particular, vanilla commands are not recognized or supported. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2527 |
Name | <PluginTag.commands> |
Returns | MapTag(MapTag) |
Description | Gets a map of commands registered this plugin registers by default.
Note that dynamically registered commands won't show up (for example, command scripts won't be listed under Denizen). Map key is command name, map value is a sub-mapping with keys: description (ElementTag), usage (ElementTag), permission (ElementTag), aliases (ListTag) Not all keys will be present. For example, <plugin[denizen].commands.get[ex]> will return a MapTag with: [description=Executes a Denizen script command.;usage=/ex (-q) <Denizen script command> (arguments);permission=denizen.ex] |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PluginTag.java#L213 |
Name | <QueueTag.commands> |
Returns | ListTag |
Description | Returns a list of commands waiting in the queue. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/QueueTag.java#L248 |
Name | <QueueTag.last_command> |
Returns | ElementTag |
Description | Returns the last command executed in this queue (if any). |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/QueueTag.java#L267 |
Name | <server.command_plugin[<name>]> |
Returns | PluginTag |
Description | Returns the plugin that created a command (if known). |
Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L661 |
Name | <server.commands> |
Returns | ListTag |
Description | Returns a list of all registered command names in Bukkit. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L649 |
Name | <util.list_denizen_commands> |
Returns | ListTag |
Description | Returns a list of all currently loaded Denizen commands. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L420 |
Name | <FlaggableObject.flag_expiration[<flag_name>]> |
Returns | TimeTag |
Description | Returns a TimeTag indicating when the specified flag will expire.
See flag system. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/AbstractFlagTracker.java#L71 |
Name | <FlaggableObject.flag_map[<name>|...]> |
Returns | MapTag |
Description | Returns a raw map of the objects internal flag data for the flags with the given flag name. Names must be root names (no '.').
Output is a MapTag wherein each key is a flag name, and each value is a MapTag, containing keys '__value' and '__expiration', where '__value' contains the real object value. Output also may contain key '__clear', which is a ListTag of flags that were listed in input but weren't present in output. Using this without a parameter to get ALL flags is allowed exclusively for debug/testing reasons, and should never be used in a real script. See flag system. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/AbstractFlagTracker.java#L104 |
Name | <FlaggableObject.flag[<flag_name>]> |
Returns | ObjectTag |
Description | Returns the specified flag from the flaggable object.
If the flag is expired, will return null. Consider also using FlaggableObject.has_flag. See flag system. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/AbstractFlagTracker.java#L37 |
Name | <FlaggableObject.has_flag[<flag_name>]> |
Returns | ElementTag(Boolean) |
Description | Returns true if the flaggable object has the specified flag, otherwise returns false.
See flag system. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/AbstractFlagTracker.java#L55 |
Name | <FlaggableObject.list_flags> |
Returns | ListTag |
Description | Returns a list of the flaggable object's flags.
Note that this is exclusively for debug/testing reasons, and should never be used in a real script. See flag system. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/AbstractFlagTracker.java#L87 |
Action Lines | begin navigation |
Triggers | when the NPC has received a 'walk' command,
or is about to follow a path. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/NPCTagBase.java#L100 |
Action Lines | cast fishing rod |
Triggers | when the NPC casts a fishing rod. See also fish. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/FishingTrait.java#L172 |
Action Lines | catch fish |
Triggers | when the NPC catches a fish. See also fish. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/FishingTrait.java#L236 |
Action Lines | complete navigation |
Triggers | when the NPC has finished a 'walk' command,
or has reached a path point. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/NPCTagBase.java#L77 |
Action Lines | despawn |
Triggers | when the NPC is despawned.
This can be because a command was issued, or a chunk has been unloaded. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/DenizenNPCHelper.java#L103 |
Action Lines | dig |
Triggers | when the NPC breaks a block with the Break Command |
Contexts | <context.location> returns the location the NPC Dug
<context.material> Returns the Block dug
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/BreakCommand.java#L106 |
Action Lines | reel in fishing rod |
Triggers | when the NPC reels in its fishing rod. See also fish. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/FishingTrait.java#L225 |
Action Lines | spawn |
Triggers | when the NPC is spawned.
This will fire whenever an NPC's chunk is loaded, or a spawn command is issued. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/DenizenNPCHelper.java#L78 |
Action Lines | start fishing |
Triggers | when the NPC starts fishing. See also fish. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/FishingTrait.java#L86 |
Action Lines | stop fishing |
Triggers | when the NPC stops fishing. See also fish. |
Contexts | None
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/FishingTrait.java#L111 |
Name | Bungee |
Syntax | bungee [<server>|...] [<commands>] |
Short Description | Runs a set of commands on another server. |
Full Description | This command runs a set of commands on another server on the Bungee network.
Tags will be parsed on the remote server, but definitions from the originating queue will be used. The linked player will be available on the remote server if that server has ever seen the player. Generally, prefer BungeeRun. |
Related Tags | <bungee.list_servers> Returns a list of known bungee server names.
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, DepenizenBungee, BungeeCord |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/bungee/BungeeCommand.java#L29 |
Name | BungeeExecute |
Syntax | bungeeexecute [<command>] (as:<player>) |
Short Description | Runs a command on the Bungee proxy server, or a player. |
Full Description | This command runs a command on the Bungee proxy server. Works similarly to "execute as_server".
If you specify "as:", you can use a PlayerTag or a UUID to automatically execute as that player, similar to "execute as_player". |
Related Tags | None
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, DepenizenBungee, BungeeCord |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/bungee/BungeeExecuteCommand.java#L24 |
Name | Clickable |
Syntax | clickable (<script>/cancel:<id>) (def:<element>|.../defmap:<map>/def.<name>:<value>) (usages:<#>) (for:<player>|...) (until:<duration>) |
Short Description | Generates a clickable command for players. |
Full Description | Generates a clickable command for players.
Generally, prefer to write a command script and simply "on_click[/yourcommandhere]" rather than using generated clickables. Generated clickables are a utility intended to enable clickables that are restricted from being normally accessed without receiving a clickable message. Specify a task script to run, or put an executable script section as sub-commands. When running a task, optionally any definitions to pass. When using a sub-section, the running commands will be in their own queue, but copy out the original queue's definitions and context source. Optionally specify a maximum number of usages (defaults to unlimited). Optionally specify a maximum duration it can be used for with 'until'. If no duration is specified, the clickable will remain valid until the server stops or restarts. WARNING: if you use clickables very often without a duration limit, this can lead to a memory leak. Clickables that have a specified max duration will occasionally be cleaned from memory. Optionally specify what players are allowed to use it. Defaults to unrestricted (any player that sees the click message may use it). Note that it is possible for a player to find the generated command ID in their logs and send it to another player to "/" execute, so if you don't restrict player access it may be abused in that way. This internally generates a command of the form "/denizenclickable <generated_id>". Players will need the permission "denizen.clickable" to be able to use this. You can cancel a clickable at any time via "cancel:<id>", where ID is the generated ID from saving the initial generated command. |
Related Tags | <entry[saveName].command> returns the command to use in "on_click".
<entry[saveName].id> returns the generate command's ID.
<ElementTag.on_click[<command>]> Adds a click command to the element, which makes the element execute the input command when clicked. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ClickableCommand.java#L38 |
Name | Disengage |
Syntax | disengage (player) |
Short Description | Enables an NPCs triggers that have been temporarily disabled by the engage command. |
Full Description | Re-enables any toggled triggers that have been disabled by disengage.
Using disengage inside scripts must have an NPC to reference, or one may be specified by supplying a valid NPCTag object with the npc argument. Engaging an NPC by default affects all players attempting to interact with the NPC. You can optionally specify 'player' to only affect the linked player. This is mostly regarded as an 'interact script command', though it may be used inside other script types. This is because disengage works with the trigger system, which is an interact script-container feature. NPCs that are interacted with while engaged will fire an 'on unavailable' assignment script-container action. See Engage |
Related Tags | <NPCTag.engaged> Returns whether the NPC is currently engaged. (...)
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/DisengageCommand.java#L19 |
Name | Else |
Related Guide Page | https://guide.denizenscript.com/guides/basics/if-command.html |
Syntax | else (if <comparison logic>) |
Short Description | Helper command for usage with the if command. |
Full Description | A helper command to use with if commands.
See if command documentation. |
Related Tags | See IF command documentation.
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/ElseCommand.java#L17 |
Name | Execute |
Syntax | execute [as_player/as_op/as_npc/as_server] [<Bukkit-command>] (silent) |
Short Description | Executes an arbitrary server command as if the player, NPC, or server typed it in. |
Full Description | Allows the execution of server commands through a Denizen script.
Commands can be executed as the server, as an npc, as an opped player, or as a player, as though it was typed by the respective source. Note that you should generally avoid using 'as_op', which is only meant for very specific special cases. 'as_server' is usually a better option. Note: do not include the slash at the start. A slash at the start will be interpreted equivalent to typing two slashes at the front in-game. Note that this is a Denizen script command that executes Bukkit commands. This can be considered the inverse of '/ex' (a Bukkit command that executes Denizen script commands). The 'silent' option can be specified with 'as_server' to hide the output. Note that 'silent' might or might not work with different plugins depending on how they operate. It can also be used with 'as_player' or 'as_op' to use network interception to silence the command output to player chat. Generally, you should never use this to execute a vanilla command, there is almost always a script command that should be used instead. Usually the 'execute' command should be reserved for interacting with external plugins. |
Related Tags | <entry[saveName].output> returns the output to an as_server sender.
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/ExecuteCommand.java#L36 |
Name | Foreach |
Related Guide Page | https://guide.denizenscript.com/guides/basics/loops.html |
Syntax | foreach [stop/next/<object>|...] (as:<name>) (key:<name>) [<commands>] |
Short Description | Loops through a ListTag, running a set of commands for each item. |
Full Description | Loops through a ListTag of any type. For each item in the ListTag, the specified commands will be ran for that list entry.
Alternately, specify a map tag to loop over the set of key/value pairs in the map, where the key will be <[key]> and the value will be <[value]>. Specify "key:<name>" to set the key definition name (if unset, will be "key"). Specify "as:<name>" to set the value definition name (if unset, will be "value"). Use "as:__player" to change the queue's player link, or "as:__npc" to change the queue's NPC link. Note that a changed player/NPC link persists after the end of the loop. To end a foreach loop, do - foreach stop To jump immediately to the next entry in the loop, do - foreach next Note that many commands and tags in Denizen support inputting a list directly, making foreach redundant for many simpler cases. Note that if you delay the queue (such as with wait or ~waitable) inside a foreach loop, the loop can't process the next entry until the delay is over. This can lead to very long waits if you have a long list and a wait directly in the loop, as the total delay is effectively multiplied by the number of iterations. Use run if you want to run logic simultaneously for many entries in a list in a way that allows them to separately wait without delaying each other. |
Related Tags | <[value]> to get the current item in the loop
<[loop_index]> to get the current loop iteration number
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/ForeachCommand.java#L31 |
Name | Goto |
Syntax | goto [<name>] |
Short Description | Jump forward to a location marked by mark. |
Full Description | Jumps forward to a marked location in the script.
For example:
Most scripters should never use this. This is only for certain special cases. |
Related Tags | None
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/GotoCommand.java#L24 |
Name | If |
Related Guide Page | https://guide.denizenscript.com/guides/basics/if-command.html |
Syntax | if [<value>] (!)(<operator> <value>) (&&/|| ...) [<commands>] |
Short Description | Compares values, and runs a subset of commands if they match. |
Full Description | Compares values, and runs a subset of commands if they match.
Works with the else command, which handles alternatives for when the comparison fails. The if command is equivalent to the English phrasing "if something is true, then do the following". Values are compared using the comparable system. See operator for information. Comparisons may be chained together using the symbols '&&' and '||' or their text equivalents 'and' and 'or'. '&&' means "and", '||' means "or". So, for example "if <[a]> && <[b]>:" requires both a AND b to be true. "if <[a]> and <[b]>:" also requires both a AND b to be true. The "or" is inclusive, meaning "if <[a]> || <[b]>:" will pass for any of the following: a = true, b = true a = true, b = false a = false, b = true but will fail when a = false and b = false. Sets of comparisons may be grouped using ( parens ) as separate arguments. So, for example "if ( <[a]> && <[b]> ) || <[c]>", or "if ( <[x]> or <[y]> or <[z]> ) and ( <[a]> or <[b]> or <[c]> )" Grouping is REQUIRED when using both '&&' and '||' in one line. Otherwise, groupings should not be used at all. Boolean inputs and groups both support negating with the '!' symbol as a prefix. This means you can do "if !<[a]>" to say "if a is NOT true". Similarly, you can do "if !( <[a]> || <[b]> )", though be aware that per rules of boolean logic, that example is the exactly same as "if !<[a]> && !<[b]>". You can also use keyword "not" as its own argument to negate a boolean or an operator. For example, "if not <[a]>:" will require a to be false, and "if <[a]> not equals <[b]>:" will require that 'a' does not equal 'b'. When not using a specific comparison operator, true vs false will be determined by Truthiness, see ObjectTag.is_truthy for details. For example, "- if <player||null>:" will pass if a player is linked, valid, and online. |
Related Tags | <ObjectTag.is[<operator>].to[<element>]> Takes an operator, and compares the first object to the given second object. (...)
<ObjectTag.is[<operator>].than[<element>]> Takes an operator, and compares the first object to the given second object. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/IfCommand.java#L28 |
Name | Mark |
Syntax | mark [<name>] |
Short Description | Marks a location for goto. |
Full Description | Marks a location for the goto command. See goto for details. |
Related Tags | None
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/MarkCommand.java#L18 |
Name | Random |
Syntax | random [<commands>] |
Short Description | Selects a random choice from the following script commands. |
Full Description | The random command picks one of the following script command and skips all the other script commands that are in its section.
Commands like "repeat 1" or "if true" can be used to group together a sublisting of commands to execute together (as a way to get around the 1-command limit). If wanting to choose a random long set of commands, consider instead using choose with util.random.int.to |
Related Tags | <entry[saveName].possibilities> returns an ElementTag of the possibility count.
<entry[saveName].selected> returns an ElementTag of the selected number.
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/RandomCommand.java#L24 |
Name | Reload |
Syntax | reload ({scripts}/scripts_now/config/saves/notes) |
Short Description | Reloads all Denizen scripts. Primarily for use as an in-game command. |
Full Description | Reloads all Denizen scripts.
Primarily for use as an in-game command, like "/ex reload". By default, reloads scripts in a way that may delay a few ticks to avoid interrupting the server on large reloads. Optionally, specify "scripts_now" to force a locked reload (server freezes until reloaded). You can specify "config", "saves", or "notes" to reload that data instead of scripts. When using 'scripts' (default), the reload command is ~waitable. Refer to ~waitable. |
Related Tags | None
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/ReloadCommand.java#L25 |
Name | Repeat |
Related Guide Page | https://guide.denizenscript.com/guides/basics/loops.html |
Syntax | repeat [stop/next/<amount>] (from:<#>) (as:<name>) [<commands>] |
Short Description | Runs a series of braced commands several times. |
Full Description | Loops through a series of braced commands a specified number of times.
To get the number of loops so far, you can use <[value]>. Optionally, specify "as:<name>" to change the definition name to something other than "value". Optionally, to specify a starting index, use "from:<#>". Note that the "amount" input is how many loops will happen, not an end index. The default "from" index is "1". Note that the value you give to "from" will be the value of the first loop. To stop a repeat loop, do - repeat stop To jump immediately to the next number in the loop, do - repeat next |
Related Tags | <[value]> to get the number of loops so far
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | for |
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/RepeatCommand.java#L28 |
Name | Sit |
Syntax | sit (<location>) |
Short Description | Causes the NPC to sit. To make them stand, see Stand. |
Full Description | Makes the linked NPC sit at the specified location.
Use Stand to make the NPC stand up again. |
Related Tags | <NPCTag.is_sitting> Returns true if the NPC is sitting. Relates to sit.
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/SitCommand.java#L23 |
Name | sleep |
Syntax | sleep (<location>) |
Short Description | Causes the NPC to sleep. To make them wake up, see Stand. |
Full Description | Makes the linked NPC sleep at the specified location.
Use Stand to make the NPC wake back up. |
Related Tags | <NPCTag.is_sleeping> Returns true if the NPC is sleeping. Relates to sleep.
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/SleepCommand.java#L24 |
Name | While |
Related Guide Page | https://guide.denizenscript.com/guides/basics/loops.html |
Syntax | while [stop/next/[<value>] (!)(<operator> <value>) (&&/|| ...)] [<commands>] |
Short Description | Runs a series of braced commands until the tag returns false. |
Full Description | Runs a series of braced commands until the if comparisons returns false. Refer to if for if command syntax information.
To end a while loop, use the 'stop' argument. To jump to the next entry in the loop, use the 'next' argument. |
Related Tags | <[loop_index]> to get the number of loops so far.
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/WhileCommand.java#L26 |
Name | custom event |
Event Lines | custom event |
Triggers | when called by a script using customevent. |
Example |
|
Has Player | When the command is used with a player link. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Has NPC | When the command is used with an NPC link. |
Switches | id:<id> to only run the event if the given ID is used. This should almost always be specified.
data:<key>:<value> to only run the event if the given data key matches the given value, using advanced matchers for the given object type (note: the 'customevent' command call has to be careful about object type for this). |
Contexts | <context.id> returns the ID that was used.
<context.data> returns the MapTag of input data (if any! some events don't have context data).
<context.(key)> returns the value of the input data key, if available.
|
Determine | "OUTPUT:<Anything>" to add that value to the output list (note this is an ADD, not a SET). |
Group | Core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/core/CustomScriptEvent.java#L16 |
Name | redis pubsub message |
Event Lines | redis pubsub message |
Triggers | when a subscribed redis connection receives a published message, see Redis. |
Generated Examples | after redis pubsub message: |
Switches | channel:<channel> to only fire on events advanced-matching the given channel. |
Contexts | <context.redis_id> returns the connection id that saw this message.
<context.pattern> returns the redis pattern that matched the channel.
<context.channel> returns the actual channel matched.
<context.message> returns the published message.
|
Group | Core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/core/RedisPubSubMessageScriptEvent.java#L9 |
Name | server resources reloaded |
Event Lines | server resources reloaded |
Triggers | when vanilla resources (such as datapacks) are reloaded (by vanilla commands or by plugins). If you mess with datapacks often, it may be helpful to run reload in this event. |
Generated Examples | after server resources reloaded: |
Switches | cause:<cause> to only process the event if the cause of the resource reload matches the specified cause. |
Contexts | <context.cause> Returns the cause of the resource reload. Refer to https://jd.papermc.io/paper/1.19/io/papermc/paper/event/server/ServerResourcesReloadedEvent.Cause.html
|
Group | Paper |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/ServerResourcesReloadedScriptEvent.java#L12 |
Name | system time hh:mm |
Event Lines | system time <HH:MM>
system time hourly|minutely|secondly |
Triggers | when the system time changes to the specified value.
The system time is the real world time set in the server's operating system. It is not necessarily in sync with the game server time, which may vary (for example, when the server is lagging). For events based on in-game time passage, use delta time or wait. |
Example |
|
Example |
|
Example |
|
Switches | every:<count> to only run the event every *count* times (like "on system time secondly every:5" for every 5 seconds). |
Contexts | <context.hour> returns the exact hour of the system time.
<context.minute> returns the exact minute of the system time.
|
Synonyms (Search Aid) | cron |
Group | Core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/core/SystemTimeScriptEvent.java#L11 |
Name | webserver web request |
Event Lines | webserver web request |
Triggers | when a webserver opened by webserver receives a connection request. |
Example |
|
Example |
|
Example |
|
Switches | port:<#> to only handle requests to a specific port.
path:<path> to only handle requests that match the given advanced-matcher for the path. method:<method> to only handle requests with the specific method (such as GET or POST). has_response:<true/false> to only handle requests that do or don't have a response already. |
Contexts | <context.method> returns the method that was used (such as GET or POST).
<context.path> returns the path requested (such as "/index.html").
<context.port> returns the port connected to.
<context.remote_address> returns the IP address that connected.
<context.query> returns a MapTag of the query data (if no query, returns empty map).
<context.raw_query> returns the raw query input (if no query, returns null).
<context.raw_user_info> returns the raw user info input (if any) (this is a historical HTTP system that allows sending username/password over query).
<context.headers> returns a MapTag of all input headers, where the key is the header name and the value is a ListTag of header values for that name.
<context.body> returns the text content of the body that was sent, if any. Particularly for POST requests.
<context.body_binary> returns the raw binary content body that was sent, if any. Particularly for POST requests.
<context.has_response> returns true if a response body determination (raw_text_content, file, or cached_file) was applied, or false if not.
|
Determine | "CODE:<Element(Number)>" to set a standard web response code, such as 'code:200' for 'OK', or 'code:404' for 'File Not Found'
"HEADERS": + MapTag to set a map of headers, where map keys are the header name and map values are the text of the value, for example headers:[Content-Type=text/html] ... note that header are sometimes case-sensitive. "RAW_TEXT_CONTENT:<ElementTag>" to set a raw text content body in response. You may determine only one response - raw text, raw binary, a file, or a cached file. You cannot use multiple. "RAW_BINARY_CONTENT:<BinaryTag>" to set a raw binary content body in response. "FILE:<ElementTag>" to set a path to a file to send in response. File path must be within the web-root path configured in Denizen/config.yml. Files will be read async. "CACHED_FILE:<ElementTag>" to set a path to a file to send in response. The content of the file will be cached in RAM until the server restarts. This is useful for files that definitely won't change. First file read will be sync, all others are instant. "PARSED_FILE:<ElementTag>" - like "FILE:", but this file will be parsed for tags using syntax like "<{util.pi}>" to separate tags from HTML entries. "CACHED_PARSED_FILE:<ElementTag>" - like "PARSED_FILE" and "CACHED_FILE" combined. Note that the file will be cached, but the results of tags will be handled at runtime still. |
Group | Core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/core/WebserverWebRequestScriptEvent.java#L29 |
Name | ~Waitable |
Description | A command that is "~Waitable" (or "Holdable", or that can be "~waited for") is a command that:
- Might potentially take a while to execute - Is able to perform a slowed execution (that doesn't freeze the server) - And so supports the "~" prefix. This is written, for example, like: - ~run MySlowScript When a command is ~waited for, the queue it's in will wait for it to complete, but the rest of the server will continue running. This is of course similar to the "wait" command, but waits for the action to complete instead of simply for a period of time. Some commands, particularly those related to file operation, when ~waited for will move the file operation off-thread. Others may need to be on the server thread, and may split the operation into smaller segments spread out over 1 tick each or similar logic. Some of these commands, when NOT waited for, will freeze the server thread until the operation completes. Others, however, may still perform the action in a delayed/slow/off-thread manner, but simply not hold the queue. |
Group | Script Command System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/Holdable.java#L9 |
Name | Denizen Permissions |
Description | The following is a list of all permission nodes Denizen uses within Bukkit.
denizen.clickable # use the 'denizenclickable' command, which is automatically executed when using clickable and for clickable chat triggers denizen.basic # use the basics of the /denizen command denizen.ex # use the /ex command denizen.debug # use the /denizen debug command denizen.submit # use the /denizen submit command Additionally: denizen.npc.health, denizen.npc.sneak, denizen.npc.effect, denizen.npc.fish, denizen.npc.sleep, denizen.npc.stand, denizen.npc.sit, denizen.npc.nameplate, denizen.npc.nickname, denizen.npc.trigger, denizen.npc.assign, denizen.npc.constants, denizen.npc.pushable However, we recommend just giving op to whoever needs to access Denizen - they can op themselves through Denizen anyway, why not save the trouble? ( EG, /ex execute as_server "op <player.name>" ) |
Group | Console Commands |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/command/DenizenCommandHandler.java#L30 |
Name | The Global If Argument |
Description | The "if:<boolean>" argument is a special meta-argument that is available for all commands, but is more useful for some than others.
It is written like:
When the if argument is used, the command will only run if the value of the argument is 'true'. The most useful place to have this is a 'stop' command, to quickly stop a script if a condition is true (a player has a flag, lacks a permission, is outside a region, or whatever else). If you need more complex matching, especially using '&&', '||', '==', etc. you should probably just do an 'if' command rather than using the argument. Though if you really want to, you can use tags here like objecttag.is.to or elementtag.and or elementtag.or. |
Group | Script Command System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/CommandExecutor.java#L50 |
Name | The Player and NPC Arguments |
Description | The "player:<player>" and "npc:<npc>" arguments are special meta-arguments that are available for all commands, but are only useful for some.
They are written like: - give stick player:<server.flag[some_player]> or: - sit npc:<entry[save].created_npc> Denizen tracks a "linked player" and a "linked NPC" in queues and the commands within. Many commands automatically operate on the linked player/NPC default or exclusively (for example, "give" defaults to giving items to the linked player but that can be changed with the "to" argument, "sit" exclusively makes the linked NPC sit, and that cannot be changed except by the global NPC argument). When the player argument is used, it sets the linked player for the specific command it's on. This is only useful for commands that default to operating on the linked player. This can also be useful with the "run" command to link a specific player to the new queue. The NPC argument is essentially equivalent to the player argument, but for the linked NPC instead of the linked player. These arguments will also affect tags (mainly "<player>" and "<npc>") in the same command line (regardless of argument order). If you need to use the original player/NPC in a tag on the same line, use the define command to track it. You can also modify the linked player or NPC for an entire queue using the fake-definitions '__player' and '__npc', for example:
|
Group | Script Command System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/implementation/DenizenCoreImplementation.java#L104 |
Name | The Save Argument |
Description | The "save:<name>" argument is a special meta-argument that is available for all commands, but is only useful for some.
It is written like: - run MyScript save:mysave When the save argument is used, the results of the command will be saved on the queue, for later usage by the "entry" tag. The useful entry keys available for any command are listed in the "Tags" documentation section for any command. For example, the "run" command lists "<entry[saveName].created_queue>". The "saveName" part should be replaced with whatever name you gave to the "save" argument, and the "created_queue" part changes between commands. Some commands have multiple save entry keys, some have just one, most don't have any. Many users make the mistake of using dynamic save names like "save:<[something]>" - this is almost always wrong. Use a constant name, just like you do for definitions. |
Group | Script Command System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/CommandExecutor.java#L31 |
Name | Action |
Syntax | action [<action name>|...] (<npc>|...) (context:<name>|<object>|...) |
Short Description | Manually fires an NPC action. |
Full Description | This command will trigger an NPC action (an action within an 'assignment' type script attached to the NPC) exactly the same
as if an actual serverside event had caused it. You can specify as many action names as you want in the list, they will all be fired. You may also specify as many NPCs as you would like to run the action on, in a list. If no NPCs are specified, the NPC linked to the script will be assumed. The script's linked player and the specified NPC will automatically be sent through to the action. To add context information (tags like <context.location>) to the action, simply specify all context values in a list. Note that there are some inherent limitations... EG, you can't directly add a list to the context currently. To do this, the best way is to just escape the list value (see Escaping System). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/ActionCommand.java#L23 |
Name | Adjust |
Related Guide Page | https://guide.denizenscript.com/guides/basics/mechanisms.html |
Syntax | adjust [<ObjectTag>/def:<name>|...] [<mechanism>](:<value>) |
Short Description | Adjusts an object's mechanism. |
Full Description | Many object tag types contains options and properties that need to be adjusted.
Denizen employs a mechanism interface to deal with those adjustments. To easily accomplish this, use this command with a valid object mechanism, and sometimes accompanying value. Specify "def:<name>" as an input to adjust a definition and automatically save the result back to the definition. You can optionally adjust a MapTag of mechanisms to values. To adjust an item in an inventory, use inventory, as '- inventory adjust slot:<#> <mechanism>:<value>'. Note that that is only for items, not actual inventories. To adjust an actual InventoryTag mechanism, you should still use the normal 'adjust' command, not 'inventory adjust'. |
Related Tags | <entry[saveName].result> returns the adjusted object.
<entry[saveName].result_list> returns a ListTag of adjusted objects.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | mechanism |
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/AdjustCommand.java#L31 |
Name | AdjustBlock |
Related Guide Page | https://guide.denizenscript.com/guides/basics/mechanisms.html |
Syntax | adjustblock [<location>|...] [<mechanism>](:<value>) (no_physics) |
Short Description | Adjusts a mechanism on the material of a block at the location. |
Full Description | Adjusts a mechanism on the material of a block at the location.
That is, an equivalent to adjust, but that directly applies a "MaterialTag" mechanism onto a block. Input a location or list of locations, and the mechanism to apply. Use the "no_physics" argument to indicate that the change should not apply a physics update. If not specified, physics will apply to the block and nearby blocks. |
Related Tags | <LocationTag.material> Returns the material of the block at the location.
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/AdjustBlockCommand.java#L30 |
Name | Advancement |
Syntax | advancement [id:<name>] (delete/grant:<players>/revoke:<players>/{create}) (parent:<name>) (icon:<item>) (title:<text>) (description:<text>) (background:<key>) (frame:<type>) (toast:<boolean>) (announce:<boolean>) (hidden:<boolean>) (x:<offset>) (y:<offset>) (progress_length:<#>) |
Short Description | Controls a custom advancement. |
Full Description | Controls custom Minecraft player advancements. You should generally create advancements manually on server start.
Currently, the ID argument may only refer to advancements added through this command. The default action is to create and register a new advancement. You may also delete an existing advancement, in which case do not provide any further arguments. You may grant or revoke an advancement for a list of players, in which case do not provide any further arguments. The parent argument sets the root advancement in the advancements menu, in the format "namespace:key". If no namespace is specified, the parent is assumed to have been created through this command. The icon argument sets the icon displayed in toasts and the advancements menu. As of MC 1.20, an icon is required. Dirt will be used if it is missing. The title argument sets the title that will show on toasts and in the advancements menu. The description argument sets the information that will show when scrolling over a chat announcement or in the advancements menu. The background argument sets the image to use if the advancement goes to a new tab. If the background is unspecified, defaults to "minecraft:textures/gui/advancements/backgrounds/stone.png". The frame argument sets the type of advancement - valid arguments are CHALLENGE, GOAL, and TASK. The toast argument sets whether the advancement should display a toast message when a player completes it. Default is true. The announce argument sets whether the advancement should display a chat message to the server when a player completes it. Default is true. The hidden argument sets whether the advancement should be hidden until it is completed. The x and y arguments are offsets based on the size of an advancement icon in the menu. They are required for custom tabs to look reasonable. When creating an advancement, optionally specify 'progress_length' to make it require multiple parts. When granting an advancement, optionally specify 'progress_length' to only grant partial progress. To award a pre-existing vanilla advancement, instead use PlayerTag.award_advancement WARNING: Failure to re-create advancements on every server start may result in loss of data - use server prestart. If you mess with datapacks, you will also need to re-create advancements during server resources reloaded |
Related Tags | <PlayerTag.has_advancement[<advancement>]> Returns whether the player has completed the specified advancement.
<PlayerTag.advancements> Returns a list of the names of all advancements the player has completed.
<server.advancement_types> Returns a list of all registered advancement names. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/AdvancementCommand.java#L33 |
Name | Age |
Syntax | age [<entity>|...] (adult/baby/<age>) (lock) |
Short Description | Sets the ages of a list of entities, optionally locking them in those ages. |
Full Description | Some living entity types are 'ageable' which can affect an entities ability to breed, or whether they appear as a baby or an adult.
Using the 'age' command allows modification of an entity's age. Specify an entity and either 'baby', 'adult', or an integer age to set the age of an entity. Using the 'lock' argument will keep the entity from increasing its age automatically. NPCs which use ageable entity types can also be specified. |
Related Tags | <EntityTag.age> (Property) Returns the entity's age. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/AgeCommand.java#L27 |
Name | Anchor |
Syntax | anchor [id:<name>] [remove/add <location>] |
Short Description | Controls an NPC's Anchor Trait. |
Full Description | The anchor system inside Citizens allows locations to be 'bound' to an NPC, saved by an 'id'.
The anchor command can add and remove new anchors. The Anchors Trait can also be used as a sort of 'waypoints' system. As the Anchor command is an NPC specific command, a valid npc object must be referenced in the script entry. If none is provided by default, use the 'npc:<npc>' argument. |
Related Tags | <NPCTag.anchor[anchor_name]> Returns the location associated with the specified anchor, or null if it doesn't exist.
<NPCTag.list_anchors> Returns a list of anchor names currently assigned to the NPC.
<NPCTag.has_anchors> Returns whether the NPC has anchors assigned.
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/AnchorCommand.java#L26 |
Name | Animate |
Syntax | animate [<entity>|...] [animation:<name>] (for:<player>|...) |
Short Description | Makes a list of entities perform a certain animation. |
Full Description | Minecraft implements several player and entity animations which the animate command can use, just
specify an entity and an animation. Player animations require a Player-type entity or NPC. Available player animations include: ARM_SWING, HURT, CRIT, MAGIC_CRIT, SIT, SLEEP, SNEAK, STOP_SITTING, STOP_SLEEPING, STOP_SNEAKING, START_USE_MAINHAND_ITEM, START_USE_OFFHAND_ITEM, STOP_USE_ITEM, EAT_FOOD, ARM_SWING_OFFHAND All entities also have available Bukkit's entity effect list: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/EntityEffect.html These EntityEffect options can optionally be played only for specific players with the "for:" argument input. In addition, Denizen adds a few new entity animations: SKELETON_START_SWING_ARM, SKELETON_STOP_SWING_ARM, POLAR_BEAR_START_STANDING, POLAR_BEAR_STOP_STANDING, HORSE_BUCK, HORSE_START_STANDING, HORSE_STOP_STANDING, IRON_GOLEM_ATTACK, VILLAGER_SHAKE_HEAD, SWING_MAIN_HAND, SWING_OFF_HAND Note that the above list only applies where logical, EG 'WOLF_' animations only apply to wolves. In versions 1.20+, to specify the direction of damage for the HURT animation, use EntityTag.play_hurt_animation |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | entity |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/AnimateCommand.java#L29 |
Name | AnimateChest |
Syntax | animatechest [<location>] ({open}/close) (sound:{true}/false) (<player>|...) |
Short Description | Makes a chest appear to open or close. |
Full Description | This command animates a chest at a specified location in the world opening or closing.
By default, the chest will animate opening. Optionally, specify whether to play a sound with the animation. By default this will play. Optionally, specify a player or list of players that the animation should be visible to. By default, only the linked player can see the animation. Note that this uses a generic 'block action' packet internally, which means other block types may also react to this command. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/AnimateChestCommand.java#L30 |
Name | Assignment |
Related Guide Page | https://guide.denizenscript.com/guides/npcs/assignment-scripts.html |
Syntax | assignment [set/add/remove/clear] (script:<name>) (to:<npc>|...) |
Short Description | Changes an NPC's assignment. |
Full Description | Changes an NPC's assignment as though you used the '/npc assignment' command.
Uses the script: argument, which accepts an assignment-type script. Optionally, specify a list of NPCs to apply the trait to. If unspecified, the linked NPC will be used. 'Set' is equivalent to 'clear' + 'add'. |
Related Tags | <NPCTag.script> Deprecated variant of NPCTag.scripts.
<server.npcs_assigned[<assignment_script>]> Returns a list of all NPCs assigned to a specified script.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/AssignmentCommand.java#L30 |
Name | attach |
Syntax | attach [<entity>|...] [to:<entity>/cancel] (offset:<offset>) (relative) (yaw_offset:<#.#>) (pitch_offset:<#.#>) (sync_server) (no_rotate/no_pitch) (for:<player>|...) |
Short Description | Attaches a list of entities to another entity, for client-visible motion sync. |
Full Description | Attaches a list of entities to another entity, for client-visible motion sync.
You must specify the entity or list of entities to be attached. You must specify the entity that they will be attached to, or 'cancel' to end attachment. Optionally, specify an offset location vector to be a positional offset. This can include a yaw/pitch to offset those as well. Note that setting an offset of 0,0,0 will produce slightly different visual results from not setting any offset. Optionally, specify 'relative' to indicate that the offset vector should rotate with the target entity. If relative is used, optionally specify yaw_offset and/or pitch_offset to add an offset to rotation of the target entity when calculating the attachment offset. Optionally, specify 'for' with a player or list of players to only sync motion for those players. If unspecified, will sync for everyone. Optionally, specify 'sync_server' to keep the serverside position of the attached entities near the target entity. This can reduce some visual artifacts (such as entity unloading at distance), but may produce unintended functional artifacts. Note that you should generally only use 'sync_server' when you exclude the 'for' argument. Optionally specify 'no_rotate' to retain the attached entity's own rotation and ignore the target rotation. Optionally instead specify 'no_pitch' to retain the attached entity's own pitch, but use the target yaw. Note that attaches involving a player will not be properly visible to that player, but will still be visible to *other* players. It may be ideal to change setting "Packets.Auto init" in the Denizen config to "true" to guarantee this command functions as expected. |
Related Tags | <EntityTag.attached_entities[(<player>)]> Returns the entities attached to this entity by attach. (...)
<EntityTag.attached_to[(<player>)]> Returns the entity that this entity was attached to by attach. (...)
<EntityTag.attached_offset[(<player>)]> Returns the offset of an attachment for this entity to another that was attached by attach. (...)
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/AttachCommand.java#L26 |
Name | Attack |
Syntax | attack [<entity>|...] (target:<entity>/cancel) |
Short Description | Makes an entity, or list of entities, attack a target. |
Full Description | The attack command causes a mob entity to attack a target mob entity or player.
This technically can be used on an NPC, but it will trigger the Citizens internal punching-pathfinder. This attack mode doesn't work well. If you want NPC combat, consider using Sentinel instead: https://github.com/mcmonkeyprojects/Sentinel/blob/master/README.md. To cancel an attack, use the 'cancel' argument instead of specifying a target. |
Related Tags | <NPCTag.is_fighting> Returns whether the NPC is currently targeting an entity for the Citizens internal punching pathfinder. (...)
<NPCTag.attack_strategy> Returns the NPC's current navigator attack strategy. (...)
<NPCTag.target_entity> Returns the entity being targeted by the NPC's current navigation (if any).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/AttackCommand.java#L26 |
Name | Break |
Syntax | break [<location>] (<npc>) (radius:<#.#>) |
Short Description | Makes an NPC walk over and break a block. |
Full Description | By itself, the 'break' command will act as an NPC command in the sense that an attached
NPC will navigate to and break the block at the attached location. It can also accept a specified npc, to fulfill the command, just specify a 'fetchable' npc object. It can also accept a radius to start breaking the block from within. To specify the radius, prefix the radius with 'radius:'. The break command is ~waitable. Refer to ~waitable. |
Related Tags | <NPCTag.is_navigating> Returns whether the NPC is currently navigating.
<NPCTag.target_location> Returns the location the NPC is currently navigating towards (if any).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/BreakCommand.java#L31 |
Name | BungeeRun |
Syntax | bungeerun [<server>|...] [<script name>] (def:<definition>|...) |
Short Description | Runs a task script on another server. |
Full Description | This command runs a task on another server on the Bungee network. Works similarly to the 'run' command. |
Related Tags | <bungee.list_servers> Returns a list of known bungee server names.
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, DepenizenBungee, BungeeCord |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/bungee/BungeeRunCommand.java#L26 |
Name | BungeeTag |
Syntax | bungeetag [server:<server>] [<tags>] |
Short Description | Parses tags on another server on a Bungee network and returns the results for this server to process. |
Full Description | This command parses tags on another server on a Bungee network and returns the results for this server to process.
As a more technical explanation: All commands in Denizen parse tags in any input arguments prior to processing them further. This command skips that step, and sends the raw tags out to the specified server to then have that server perform the actual tag processing, when then gets sent back and allows the command to complete. Tags will be parsed on the remote server, but definitions from the originating queue will be used. The linked player will be available on the remote server if that server has ever seen the player. This command must be held with the '~' prefix. The queue will then wait for the result. |
Related Tags | <entry[saveName].result> returns the result of the parsed tag.
<bungee.list_servers> Returns a list of known bungee server names.
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, DepenizenBungee, BungeeCord |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/bungee/BungeeTagCommand.java#L31 |
Name | Burn |
Syntax | burn [<entity>|...] (duration:<value>) |
Short Description | Sets a list of entities on fire. |
Full Description | Burn will set a list of entities on fire.
Just specify a list of entities (or a single entity) and optionally, a duration. Normal mobs and players will see damage afflicted, but NPCs will block damage from a burn unless 'vulnerable'. Since this command sets the total time of fire, it can also be used to cancel fire on a burning entity by specifying a duration of 0. Specifying no duration will result in a 5 second burn. |
Related Tags | <EntityTag.fire_time> Returns the duration for which the entity will remain on fire
<EntityTag.on_fire> Returns whether the entity is currently ablaze or not.
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | ignite, fire, torch |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/BurnCommand.java#L25 |
Name | Cast |
Syntax | cast [<effect>] (remove) (duration:<value>) (amplifier:<#>) (<entity>|...) (no_ambient) (hide_particles) (no_icon) (no_clear) |
Short Description | Casts a potion effect to a list of entities. |
Full Description | Casts or removes a potion effect to or from a list of entities.
The effect type must be from https://hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html. If you don't specify a duration, it defaults to 60 seconds. An infinite duration will apply an infinite duration potion effect, refer to DurationTag for more details. The amplifier is how many levels to *add* over the normal level 1. If you don't specify an amplifier level, it defaults to 1, meaning an effect of level 2 (this is for historical compatibility reasons). Specify "amplifier:0" to have no amplifier applied (ie effect level 1). If no entity is specified, the command will target the linked player. If there isn't one, the command will target the linked NPC. If there isn't one either, the command will error. Optionally, specify "no_ambient" to hide some translucent additional particles, while still rendering the main particles. "Ambient" effects in vanilla come from a beacon, while non-ambient come from a potion. Optionally, specify "hide_particles" to remove the particle effects entirely. Optionally, specify "no_icon" to hide the effect icon in the corner of your screen. Optionally use "no_clear" to prevent clearing any previous effect instance before adding the new one. |
Related Tags | <EntityTag.has_effect[<effect>]> Returns whether the entity has a specified effect, or whether an arrow/area effect cloud will apply a certain effect. (...)
<server.potion_effect_types> Returns a list of all potion effects known to the server. (...)
<EntityTag.effects_data> Returns the active potion effects on the entity, or the potion effects an arrow/area effect cloud will apply. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | potion, magic |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/CastCommand.java#L34 |
Name | Chat |
Syntax | chat [<text>] (no_target/targets:<entity>|...) (talkers:<entity>|...) (range:<#.#>) |
Short Description | Causes an NPC/NPCs to send a chat message to nearby players. |
Full Description | Chat uses an NPC's speech controller provided by Denizen, typically inside 'interact' or 'task' script-containers.
Typically there is already player and NPC context inside a queue that is using the 'chat' command. In this case, only a text input is required. Alternatively, target entities can be specified to have any Entity chat to a different target/targets, or specify 'no_target' to not send the message to any specific target. Chat from an NPC is formatted by the settings present in Denizen's config.yml. Players being chatted to see a slightly different message than surrounding players. By default, a 'chat' will allow other players nearby to also see the conversation. For example:
The player being chatted to, by default the attached Player to the script queue, will see a message 'Jack says to you, Hello!', however surrounding entities will see something along the lines of 'Jack says to Bob, Hello!'. The format for this is configurable via the "Denizen/config.yml" file. If sending messages to the Player without any surrounding entities hearing the message is desirable, it is often times recommended to instead use the 'narrate' command. Alternatively, on a server-wide scale, the configuration node for the 'range' can be set to 0, however this is discouraged. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | say, speak |
Group | player |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ChatCommand.java#L43 |
Name | Choose |
Syntax | choose [<option>] [<cases>] |
Short Description | Chooses an option from the list of cases. |
Full Description | Chooses an option from the list of cases.
Intended to replace a long chain of simplistic if/else if or complicated script path selection systems. Simply input the selected option, and the system will automatically jump to the most relevant case input. Cases are given as a sub-set of commands inside the current command (see Usage for samples). Optionally, specify "default" in place of a case to give a result when all other cases fail to match. Cases must be static text. They may not contain tags. For multi-tag comparison, consider the IF command. Any one case line can have multiple values in it - each possible value should be its own argument (separated by spaces). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/ChooseCommand.java#L26 |
Name | Compass |
Syntax | compass [<location>/reset] |
Short Description | Redirects the player's compass to target the given location. |
Full Description | Redirects the compass of the player, who is attached to the script queue.
This is not the compass item, but the command is controlling the pointer the item should direct at. This means that all item compasses will point the same direction but differently for each player. To affect an individual compass item, use ItemTag.lodestone_location The y-axis is not used but its fine to be included in the location argument. Reset argument will turn the direction to default (spawn or bed) |
Related Tags | <PlayerTag.compass_target> Returns the location of the player's compass target.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/CompassCommand.java#L23 |
Name | Cooldown |
Syntax | cooldown [<duration>] (global) (script:<script>) |
Short Description | Temporarily disables an interact script for the linked player. |
Full Description | Temporarily 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 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 |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/core/CooldownCommand.java#L25 |
Name | CreateWorld |
Syntax | createworld [<name>] (generator:<id>) (worldtype:<type>) (environment:<environment>) (copy_from:<world>) (seed:<seed>) (settings:<json>) (generate_structures:true/false) |
Short Description | Creates a new world, or loads an existing world. |
Full Description | This command creates a new minecraft world with the specified name, or loads an existing world by that name.
Optionally specify a plugin-based world generator by its generator ID. If you want an empty void world with a void biome, you can use "denizen:void". If you want an empty void world with vanilla biomes, you can use "denizen:void_biomes". Optionally specify additional generator settings as JSON input. Optionally specify a world type which can be specified with 'worldtype:' (defaults to NORMAL). For all world types, see: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/WorldType.html Optionally specify an environment (defaults to NORMAL, can also be NETHER, THE_END). Optionally choose whether to generate structures in this world. Optionally specify an existing world to copy files from. The 'copy_from' argument is ~waitable. Refer to ~waitable. It's often ideal to put this command inside server prestart. |
Related Tags | <server.world_types> Returns a list of all world types known to the server. (...)
<server.worlds> Returns a list of all worlds.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | loadworld |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/CreateWorldCommand.java#L35 |
Name | Debug |
Related Guide Page | https://guide.denizenscript.com/guides/first-steps/problem-solving.html |
Syntax | debug [<type>] [<message>] (name:<name>) |
Short Description | Shows a debug message. |
Full Description | Use to quickly output debug information to console.
Valid types include: DEBUG: standard hideable debug. HEADER: standard hideable debug inside a header line. FOOTER: a footer line. SPACER: a spacer line. LOG: global output, non-hideable. APPROVAL: "Okay!" output, non-hideable. ERROR: "Error!" output, non-hideable. REPORT: normally used to describe the arguments of a command, requires a name, hideable. EXCEPTION: outputs a full java stacktrace. RECORD: Use message 'start' to start recording, 'submit' to submit a recording, or 'cancel' to cancel a recording. TODO: Should [<type>] be required? Perhaps default to 'debug' mode? |
Related Tags | <entry[saveName].submitted> returns the submit link (if any).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/DebugCommand.java#L23 |
Name | Define |
Related Guide Page | https://guide.denizenscript.com/guides/basics/definitions.html |
Syntax | define [<id>](:<action>)[:<value>] |
Short Description | Creates a temporary variable inside a script queue. |
Full Description | Definitions are queue-level 'variables' that can be used throughout a script, once defined, by using the <[<id>]> tag.
Definitions are only valid on the current queue and are not transferred to any new queues constructed within the script, such as by a 'run' command, without explicitly specifying to do so. Definitions are lighter and faster than creating a temporary flag. Definitions are also automatically removed when the queue is completed, so there is no worry for leaving unused data hanging around. This command supports data actions, see data actions. Definitions can be sub-mapped with the '.' character, meaning a def named 'x.y.z' is actually a def 'x' as a MapTag with key 'y' as a MapTag with key 'z' as the final defined value. In other words, "<[a.b.c]>" is equivalent to "<[a].get[b].get[c]>" |
Related Tags | <[<id>]> to get the value assigned to an ID
<QueueTag.definition[<definition>]> Returns the value of the specified definition. (...)
<QueueTag.definitions> Returns the names of all definitions that were added to the current queue.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | definition |
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/DefineCommand.java#L27 |
Name | Despawn |
Syntax | despawn (<npc>|...) |
Short Description | Temporarily despawns the linked NPC or a list of NPCs. |
Full Description | This command will temporarily despawn either the linked NPC or a list of other NPCs.
Despawning means they are no longer visible or interactable, but they still exist and can be respawned. |
Related Tags | <NPCTag.is_spawned> Returns whether the NPC is spawned.
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/DespawnCommand.java#L26 |
Name | Determine |
Related Guide Page | https://guide.denizenscript.com/guides/first-steps/world-script.html |
Syntax | determine (passively) [<value>] |
Short Description | Sets the outcome of a script. |
Full Description | Sets the outcome of a script.
The most common use case is within script events (for example, to cancel the event). This is also required for all procedure scripts. It may be useful in other cases (such as a task script that returns a result, via the save argument). By default, the determine command will end the queue (similar to stop). If you wish to prevent this, specify the "passively" argument. To make multiple determines, simply use the determine command multiple times in a row, with the "passively" argument on each. |
Related Tags | <QueueTag.determination> Returns the values that have been determined via Determine (...)
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | return |
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/DetermineCommand.java#L23 |
Name | discord |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discord [id:<id>] [disconnect/add_role/start_typing/remove_role/status (status:<status>) (activity:<activity>)/rename] (<value>) (message_id:<id>) (channel:<channel>) (user:<user>) (group:<group>) (role:<role>) (url:<url>) |
Short Description | Interacts with Discord. |
Full Description | Interacts with Discord.
Commands may fail if the bot does not have permission within the Discord group to perform them. When setting the status of the Discord bot, the status argument can be: ONLINE, DND, IDLE, or INVISIBLE, and the activity argument can be: PLAYING, STREAMING, LISTENING, or WATCHING. Streaming activity requires a 'url:' input. The command should always be ~waited for. See ~waitable. |
Related Tags | <discord[<bot_id>]> Returns the Discord bot for the given bot ID.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordCommand.java#L38 |
Name | discordban |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordban (id:<bot>) ({add}/remove) [user:<user>] [group:<group>] (reason:<reason>) (deletion_timeframe:<time>/{0s}) |
Short Description | Bans or unbans a member from a group. |
Full Description | Bans or unbans a member from a group.
To ban a user, use the "add" argument. To unban a user, use the "remove" argument. The group is required for both "add" and "remove" arguments, but "reason" can only be used with "add". Reasons show up in the group's Audit Logs. The "deletion_timeframe" argument will, if set, delete all messages sent by the user being banned within the timeframe given. The timeframe defaults to 0 seconds, which will not delete any messages. The timeframe cannot be greater than 7 days. This argument can only be used when adding a ban using the "add" argument, although it is not required. The command should usually be ~waited for. See ~waitable. |
Related Tags | <DiscordUserTag.is_banned[<group>]> returns if the user is banned from a certain group.
<DiscordGroupTag.banned_members> returns a list of all banned members in a group.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordBanCommand.java#L27 |
Name | discordconnect |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordconnect [id:<id>] [token:<secret>] (intents:<intent>|...) |
Short Description | Connects to Discord. |
Full Description | Connects to Discord.
The connection will automatically specify the following gateway intents: GUILD_MEMBERS, GUILD_EMOJIS_AND_STICKERS, GUILD_MESSAGES, GUILD_MESSAGE_REACTIONS, DIRECT_MESSAGES, DIRECT_MESSAGE_REACTIONS, MESSAGE_CONTENT Optionally specify additional Gateway Intents to use as a list of any of: GUILD_BANS, GUILD_WEBHOOKS, GUILD_INVITES, GUILD_VOICE_STATES, GUILD_PRESENCES, GUILD_MESSAGE_TYPING, DIRECT_MESSAGE_TYPING use "intents:clear|SOME_INTENT|etc" (ie the first entry as "clear") to clear out default intents and use only your manually specified choices. Note that you need to enable the 'members' and 'message content' intent on your bot in Discord bot settings https://discord.com/developers/applications And also may need to manually enable other intents if you specify any. If the members intent is not enabled, a significant amount of dDiscordBot's functionality will not work. Store your Discord bot token in the Denizen secrets file at 'plugins/Denizen/secrets.secret'. Refer to SecretTag for usage info. The command should usually be ~waited for. See ~waitable. |
Related Tags | <discord[<bot_id>]> Returns the Discord bot for the given bot ID.
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordConnectCommand.java#L52 |
Name | discordcreatechannel |
Syntax | discordcreatechannel (id:<bot>) [group:<group>] [name:<name>] (description:<description>) (type:<type>) (category:<category_id>) (position:<#>) (roles:<list>) (users:<list>) |
Short Description | Creates text channels on Discord. |
Full Description | Creates text channels on Discord.
This functionality requires the Manage Channels permission. You can optionally specify the channel description (aka "topic") with the "description" argument. You can optionally specify the channel type. Valid types are TEXT, NEWS, CATEGORY, and VOICE. Only text and news channels can have a description. Categories cannot have a parent category. You can optionally specify the channel's parent category with the "category" argument. By default, the channel will not be attached to any category. You can optionally specify the channel's position in the list as an integer with the "position" argument. You can optionally specify the roles or users that are able to view the channel. The "roles" argument takes a list of DiscordRoleTags, and the "users" argument takes a list of DiscordUserTags. Specifying either of these arguments will create a private channel (hidden for anyone not in the lists). The command can be ~waited for. See ~waitable. |
Related Tags | <entry[saveName].channel> returns the DiscordChannelTag of a channel upon creation when the command is ~waited for.
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordCreateChannelCommand.java#L30 |
Name | discordcreatethread |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordcreatethread (id:<bot>) [name:<name>] [message:<message>/parent:<channel> (private)] |
Short Description | Creates a new Discord thread. |
Full Description | Creates a new Discord thread.
You must specify the bot object ID, and the thread name. You can either specify a full DiscordMessageTag instance to create a thread based on that message, OR specify a DiscordChannelTag parent and optionally mark it private (otherwise it's public). The command can be ~waited for. See ~waitable. |
Related Tags | <entry[saveName].created_thread> returns the newly created thread.
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordCreateThreadCommand.java#L30 |
Name | discordinteraction |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordinteraction [defer/reply/delete] [interaction:<interaction>] (ephemeral) (rows:<rows>) (<message>) (embed:<embed>|...) (attach_files:<map>) |
Short Description | Manages Discord interactions. |
Full Description | Manages Discord interactions.
You can defer, reply to, edit, or delete an interaction. These instructions all require the "interaction" argument. The "ephemeral" argument can be used to have the reply message be visible to that one user. You can defer an interaction before replying, which is useful if your reply may take more than a few seconds to be selected. If you defer, the 'ephemeral' option can only be set by the defer - you cannot change it with the later reply. Replying to an interaction uses similar logic to normal messaging. See discordmessage. If you deferred without using 'ephemeral', the 'delete' option will delete the "Thinking..." message. Ephemeral replies cannot have files. Slash commands, and replies to interactions, have limitations. See https://gist.github.com/MinnDevelopment/b883b078fdb69d0e568249cc8bf37fe9. Generally used alongside discordcommand The command can be ~waited for. See ~waitable. |
Related Tags | <entry[saveName].command> returns the DiscordCommandTag of a slash command upon creation, when the command is ~waited for.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordInteractionCommand.java#L31 |
Name | discordmessage |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordmessage (id:<id>) [reply:<message>/edit:<message>/channel:<channel>/user:<user>] (<message>) (no_mention) (rows:<rows>) (embed:<embed>|...) (attach_files:<map>) (post_title:<name>) |
Short Description | Sends a message to a Discord channel. |
Full Description | Sends a message to a Discord channel.
Command may fail if the bot does not have permission within the Discord group to send a message in that channel. You can send the message to: a channel, user, or in reply to a previous message. If sending as a reply, optionally use "no_mention" to disable the default reply pinging the original user. Channels can be specified as either a copied ID, or using any tag that returns a valid DiscordChannelTag. To get IDs, enable "Developer Mode" in your Discord settings, then right click on the channel and press "Copy ID". You can edit an existing message by using "edit:<message>". You can use "attach_file_name:<name>" and "attach_file_text:<text>" to attach a text file with longer content than a normal message allows. Alternatively, you can use "attach_files:<map>" to attach files as a MapTag of the name of the file to the text or a BinaryTag. To send embeds, use "embed:<embed>|...". You can use "rows" to attach action rows of components, such as buttons to the message, using DiscordButtonTag, and DiscordSelectionTag. You can send a message into a Forum Channel with "post_title" specified to create a post in that forum. The command can be ~waited for. See ~waitable. |
Related Tags | <entry[saveName].message> returns the DiscordMessageTag of the sent message, when the command is ~waited for.
<discord[mybot].group[Denizen].channel[bot-spam]> is an example of a tag that will return an appropriate channel object for a named channel in a named group.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordMessageCommand.java#L43 |
Name | discordmodal |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordmodal [interaction:<interaction>] [name:<name>] [rows:<rows>] (title:<title>) |
Short Description | Manages Discord modals. |
Full Description | With this command you can respond to an interaction using a modal.
A "modal" is a popup window that presents the user with a form to fill out. You can specify the modal's internal name for matching with in events. You can specify the title as text to display to the user. You can specify rows of user-inputs using DiscordTextInputTag. At time of writing, Selection input is not supported. You can listen to the responses to forms using discord modal submitted. You cannot defer an interaction before using a modal. It must be sent immediately. Note that the interaction can be any button or application command, but cannot be a modal submission - you cannot reply to a modal submit with a second modal. The command can be ~waited for. See ~waitable. |
Related Tags | None
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordModalCommand.java#L34 |
Name | discordreact |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordreact (id:<bot>) (channel:<channel>) [message:<message>] [add/remove/clear] [reaction:<reaction>/all] (user:<user>) |
Short Description | Manages message reactions on Discord. |
Full Description | Manages message reactions on Discord.
The message can be a DiscordMessageTag, or just the message ID, with a channel ID also given. You can add or remove reactions from the bot, or clear all reactions of a specific ID, or clear all reactions from a message entirely. Reactions can be unicode symbols, or custom emoji IDs. Optionally specify a user for 'remove' to remove only a specific user's reaction. 'Add' requires basic add-reaction permissions. 'Clear' requires 'manage messages' permission. For custom emoji, the ID is the numeric ID. For default emoji, the ID is the unicode symbol of the emoji. In both cases, you can copy the correct value by typing the emoji into Discord and prefixing it with a "\" symbol, like "\:myemoji:" and sending it - the sent message will show the internal form of the emoji. The command can be ~waited for. See ~waitable. |
Related Tags | <DiscordMessageTag.reactions> Returns a list of reaction on this message.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordReactCommand.java#L33 |
Name | discordtimeout |
Related Guide Page | https://guide.denizenscript.com/guides/expanding/ddiscordbot.html |
Syntax | discordtimeout (id:<bot>) ({add}/remove) [user:<user>] [group:<group>] (reason:<reason>) (duration:<duration>/{60s}) |
Short Description | Puts a user in timeout. |
Full Description | Puts a user in timeout.
To put a user in timeout, use the "add" argument. To remove the timeout, use the "remove" argument. The group is required for both "add" and "remove" arguments, but "reason" can only be used with "add". Reasons show up in the group's Audit Logs. The timeout duration defaults to 60 seconds. The duration cannot be greater than 28 days. This argument can only be used when putting a user in timeout using the "add" argument, although it is not required. The command can be ~waited for. See ~waitable. |
Related Tags | <DiscordUserTag.is_timed_out[<group>]> returns if the user is timed out in a certain group.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | external |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/commands/DiscordTimeoutCommand.java#L31 |
Name | disguise |
Syntax | disguise [<entity>] [cancel/as:<type>] (global/players:<player>|...) (self) |
Short Description | Makes the player see an entity as though it were a different type of entity. |
Full Description | Makes the player see an entity as though it were a different type of entity.
The entity won't actually change on the server. The entity will still visibly behave the same as the real entity type does. Be warned that the replacement is imperfect, and visual or internal-client errors may arise from using this command. If you disguise a player to themself, they will see a slightly-lagging-behind copy of the disguise entity. The disguise will last until a server restart, or the cancel option is used. Optionally, specify a list of players to show or cancel the entity to. If unspecified, will default to the linked player. Or, specify 'global' to make the disguise or cancel apply for all players. If using global, use "self" to show to the self-player. To remove a disguise, use the 'cancel' argument. |
Related Tags | <PlayerTag.disguise_to_self[(<player>)]> Returns the fake entity used to disguise the entity in the player's self-view (only relevant to players), either globally (if no context input given), or to the specified player. (...)
<EntityTag.is_disguised[(<player>)]> Returns whether the entity is currently disguised, either globally (if no context input given), or to the specified player. (...)
<EntityTag.disguised_type[(<player>)]> Returns the entity type the entity is disguised as, either globally (if no context input given), or to the specified player. (...)
<EntityTag.disguise_to_others[(<player>)]> Returns the fake entity used to disguise the entity in other's views, either globally (if no context input given), or to the specified player. (...)
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/DisguiseCommand.java#L42 |
Name | DisplayItem |
Syntax | displayitem [<item>] [<location>] (duration:<value>) |
Short Description | Makes a non-touchable item spawn for players to view. |
Full Description | This command drops an item at the specified location which cannot be picked up by players.
It accepts a duration which determines how long the item will stay for until disappearing. If no duration is specified the item will stay for 1 minute, after which the item will disappear. Use "duration:infinite" to indicate that the item should never remove itself. |
Related Tags | <EntityTag.item> (Property) An entity's item, which can be: (...)
<entry[saveName].dropped> returns a EntityTag of the spawned item.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/DisplayItemCommand.java#L38 |
Name | Draw |
Syntax | draw [id:<id>] [pixel/rectangle/oval/image:<image>] (width:<width>) (height:<height>) (filled) [x:<x>] [y:<y>] (color:<color>) |
Short Description | Draws on an image. |
Full Description | Draws a pixel, shape, or image onto an image.
"id:" - the id of the image to draw on, see Image. "x:" and "y:" - the position that should be drawn on, see Image positions. For pixels or shapes: "color:" - a ColorTag of the color to draw in. For non-pixel shapes: "width:" and "height:" - the size of the shape being drawn, required. "filled" - whether the shape should be filled or just a border. optional, defaults to false. And for images: "image:" - the image to draw, required. "width:" and "height:" - the size to rescale the image being drawn to, optional. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | image |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/DrawCommand.java#L16 |
Name | effectlib |
Syntax | effectlib [type:<effect>] (origin:<entity>/<location>) (target:<entity>/<location>) (for:<player>) (effect_data:<map>) |
Short Description | Show custom effects using EffectLib |
Full Description | Displays EffectLib effects.
Specify which effect to display using the 'type:' argument, note that effect names are CASE-SENSITIVE. The origin is the entity/location to play the effect at. If an entity is specified, the effect will follow it. Defaults to the linked player if unspecified. Some effects (such as the 'Line' effect) require an origin and a target, an effect's target can be a location or an entity. If an entity is specified, the effect will follow it. You can optionally use the 'for:' argument to show the effect to one player only. EffectLib effects can take additional data to change how the effect looks/works, you can specify that data in the form of a MapTag using the 'effect_data:' argument. See EffectLib's docs for further information on the available options for each effect: https://reference.elmakers.com/#effectlib Note that this should only be used for displaying EffectLib's advanced effect shapes. For more general particle usage, use playeffect. The effectlib command is ~waitable. Refer to ~waitable. When ~waited for, the command will wait until the effect is done playing. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, EffectLib |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/effectlib/EffectLibCommand.java#L40 |
Name | Engage |
Syntax | engage (<duration>) (player) |
Short Description | Temporarily disables an NPCs toggled interact script-container triggers. |
Full Description | Engaging an NPC will temporarily disable any interact script-container triggers.
To reverse this behavior, use either the disengage command, or specify a duration in which the engage should timeout. Specifying an engage without a duration will render the NPC engaged until a disengage is used on the NPC. Engaging an NPC by default affects all players attempting to interact with the NPC. You can optionally specify 'player' to only affect the linked player. While engaged, all triggers and actions associated with triggers will not 'fire', except the 'on unavailable' assignment script-container action, which will fire for triggers that were enabled previous to the engage command. Engage can be useful when NPCs are carrying out a task that shouldn't be interrupted, or to provide a good way to avoid accidental 'retrigger'. See Disengage |
Related Tags | <NPCTag.engaged> Returns whether the NPC is currently engaged. (...)
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/EngageCommand.java#L30 |
Name | Equip |
Syntax | equip (<entity>|...) (hand:<item>) (offhand:<item>) (head:<item>) (chest:<item>) (legs:<item>) (boots:<item>) (saddle:<item>) (horse_armor:<item>) |
Short Description | Equips items and armor on a list of entities. |
Full Description | This command equips an item or armor to an entity or list of entities to the specified slot(s).
Set the item to 'air' to unequip any slot. |
Related Tags | <EntityTag.equipment> Returns a ListTag containing the entity's equipment. (...)
<InventoryTag.equipment> Returns the equipment of an inventory as a list of items. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/EquipCommand.java#L32 |
Name | Experience |
Syntax | experience [set/give/take] (level) [<#>] |
Short Description | Gives or takes experience points to the player. |
Full Description | This command allows modification of a players experience points.
Experience can be modified in terms of XP points, or by levels. This command works with offline players, but using it on online players is safer. |
Related Tags | <PlayerTag.xp> Returns the percentage of experience points to the next level.
<PlayerTag.xp_to_next_level> Returns the amount of XP the player needs to get to the next level. (...)
<PlayerTag.xp_total> Returns the total amount of experience points the player has. (...)
<PlayerTag.xp_level> Returns the number of XP levels the player has. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ExperienceCommand.java#L22 |
Name | Explode |
Syntax | explode (power:<#.#>) (<location>) (fire) (breakblocks) (source:<entity>) |
Short Description | Causes an explosion at the location. |
Full Description | This command causes an explosion at the location specified (or the npc / player location).
By default, this will not destroy blocks or set fire to blocks within the explosion. Specify the 'fire' argument to set blocks on fire within the explosion radius. Specify the 'breakblocks' argument to cause the explosion to break blocks within the power radius. If no power is specified, the default power will be 1. If no location is given, the default will be the linked NPC or player's location. It is highly recommended you specify a location to be safe. Optionally specify a source entity that will be tracked as the damage cause. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | detonate, bomb, tnt |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/ExplodeCommand.java#L22 |
Name | FakeEquip |
Syntax | fakeequip [<entity>|...] (for:<player>|...) (duration:<duration>/reset) (hand:<item>) (offhand:<item>) (head:<item>) (chest:<item>) (legs:<item>) (boots:<item>) |
Short Description | Fake-equips items and armor on a list of entities for players to see without real change. |
Full Description | This command fake-equips items and armor on a list of entities.
The change doesn't happen on-server, and no armor effects will happen from it. The equipment can only be seen by certain players. By default, the linked player is used. The changes will remain in place for as long as the duration is specified (even if the real equipment is changed). The changes can be manually reset early by using the 'reset' argument. If you do not provide a duration, the fake equipment will last until manually reset. This does not persist across server restarts. Set the item to 'air' to unequip any slot. |
Related Tags | <EntityTag.equipment> Returns a ListTag containing the entity's equipment. (...)
<InventoryTag.equipment> Returns the equipment of an inventory as a list of items. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FakeEquipCommand.java#L34 |
Name | FakeItem |
Syntax | fakeitem [<item>|...] [slot:<slot>] (duration:<duration>) (players:<player>|...) (raw) |
Short Description | Show a fake item in a player's inventory. |
Full Description | This command allows you to display an item in an inventory that is not really there.
To make it automatically disappear at a specific time, use the 'duration:' argument. Note that the reset can be unreliable, especially if the player changes their open inventory view. Consider using "- inventory update" after a delay instead. By default, it will use any inventory the player currently has open. Slots function as follows: Player inventory is slots 1-36, same as normal inventory slot indices. If the player has an open inventory, to apply the item to a slot in that inventory, add 36 to the slot index. If the player does not have an open inventory, slots 36-40 are equipment, 41 is offhand, 42 is recipe result, 43-46 are recipe. For modifying equipment, consider PlayerTag.fake_equipment instead. The slot argument can be any valid slot, see Slot Inputs. Optionally specify 'raw' to indicate that the slow is a raw network slot ID. |
Related Tags | None
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/FakeItemCommand.java#L39 |
Name | FakeSpawn |
Syntax | fakespawn [<entity>] [<location>/cancel] (players:<player>|...) (duration:<duration>{10s}) (mount_to:<entity>) |
Short Description | Makes the player see a fake entity spawn that didn't actually happen. |
Full Description | Makes the player see a fake entity spawn that didn't actually happen.
This means that the server will not track the entity, and players not included in the command will not see the entity. You must specify an entity to spawn and a location to spawn it at, or to remove a fake entity, specify the fake entity object and 'cancel' instead of a location. Optionally, specify a list of players to show the entity to. If unspecified, will default to the linked player. Optionally, specify how long the fake entity should remain for. If unspecified, will default to 10 seconds. After the duration is up, the entity will be removed from the player(s). Optionally, specify an entity to mount the fake entity to via mount_to:<entity>. |
Related Tags | <PlayerTag.fake_entities> Returns a list of fake entities the player can see, as set by fakespawn. (...)
<entry[saveName].faked_entity> returns the spawned faked entity.
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/FakeSpawnCommand.java#L32 |
Name | FileCopy |
Syntax | filecopy [origin:<origin>] [destination:<destination>] (overwrite) |
Short Description | Copies a file from one location to another. |
Full Description | Copies a file from one location to another.
The starting directory is server/plugins/Denizen. May overwrite existing copies of files. Note that in most cases this command should be ~waited for (like "- ~filecopy ..."). Refer to ~waitable. This command can be disabled by setting Denizen config option "Commands.Filecopy.Allow copying files" to false. |
Related Tags | <entry[saveName].success> returns whether the copy succeeded (if not, either an error or occurred, or there is an existing file in the destination.)
|
Usage Example |
|
Group | file |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/FileCopyCommand.java#L29 |
Name | FileRead |
Syntax | fileread [path:<path>] |
Short Description | Reads the file at the given path. |
Full Description | Reads the file at the given path.
The starting directory is server/plugins/Denizen. Note that in most cases this command should be ~waited for (like "- ~fileread ..."). Refer to ~waitable. This command must be enabled by setting Denizen config option "Commands.File.Allow read" to true. |
Related Tags | <entry[saveName].data> returns a BinaryTag of the raw file content.
|
Usage Example |
|
Group | file |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/FileReadCommand.java#L26 |
Name | FileWrite |
Syntax | filewrite [path:<path>] [data:<binary>] |
Short Description | Writes the given raw data to the file at the given path. |
Full Description | Writes the given raw data to the file at the given path.
Will overwrite any existing file at the path. The starting directory is server/plugins/Denizen. Directories will automatically be generated as-needed. Note that in most cases this command should be ~waited for (like "- ~filewrite ..."). Refer to ~waitable. This command must be enabled by setting Denizen config option "Commands.File.Allow write" to true. |
Related Tags | None
|
Usage Example |
|
Group | file |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/FileWriteCommand.java#L26 |
Name | Firework |
Syntax | firework (<location>) (power:<#>) (<type>/random) (primary:<color>|...) (fade:<color>|...) (flicker) (trail) (life:<duration>) |
Short Description | Launches a firework with customizable style. |
Full Description | This command launches a firework from the specified location.
If no location is given, the linked NPC or player's location will be used by default. The power option, which defaults to 1 if left empty, specifies the 'power' integer of the firework, which mainly controls how high the firework will go before exploding. Alternately, the "life" option allows you to manually specify a specific duration. The type option which specifies the shape the firework will explode with. If unspecified, 'ball' will be used. Can be any of: ball, ball_large, star, burst, or creeper The primary option specifies what color the firework explosion will start with, as a ColorTag. If unspecified, 'yellow' will be used. The fade option specifies what color the firework explosion will fade into, as a ColorTag. The trail option means the firework will leave a trail behind it. The flicker option means the firework will explode with a flicker effect. |
Related Tags | <EntityTag.firework_item> If the entity is a firework, returns the firework item used to launch it.
<ItemTag.is_firework> Returns whether the item is a firework. (...)
<ItemTag.firework> Returns the firework's property value as a list, matching the non-MapTag format of the mechanism. (...)
<entry[saveName].launched_firework> returns a EntityTag of the firework that was launched.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/FireworkCommand.java#L38 |
Name | Flag |
Related Guide Page | https://guide.denizenscript.com/guides/basics/flags.html |
Syntax | flag [<object>|...] [<name>([<#>])](:<action>)[:<value>] (expire:<time>) |
Short Description | Sets or modifies a flag on any flaggable object. |
Full Description | The flag command sets or modifies custom data values stored on any flaggable object (the server, a player/NPC/entity, a block location, ...).
See also flag system. This command supports data actions, see data actions. Flags by default are added permanently (or for the lifetime of the object they're attached to). You can optionally specify a system time the flag will expire at, using either a DurationTag or a TimeTag. If a DurationTag is used, it will be equivalent to: <util.time_now.add[<your_duration_here>]> |
Related Tags | <FlaggableObject.flag[<flag_name>]> Returns the specified flag from the flaggable object. (...)
<FlaggableObject.has_flag[<flag_name>]> Returns true if the flaggable object has the specified flag, otherwise returns false. (...)
<FlaggableObject.flag_expiration[<flag_name>]> Returns a TimeTag indicating when the specified flag will expire. (...)
<FlaggableObject.list_flags> Returns a list of the flaggable object's flags. (...)
<server.online_players_flagged[<flag_name>]> Returns a list of all online players with a specified flag set. (...)
<server.players_flagged[<flag_name>]> Returns a list of all players (online or offline) with a specified flag set. (...)
<server.spawned_npcs_flagged[<flag_name>]> Returns a list of all spawned NPCs with a specified flag set. (...)
<server.npcs_flagged[<flag_name>]> Returns a list of all NPCs with a specified flag set. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/FlagCommand.java#L88 |
Name | Give |
Syntax | give [<item>|...] (quantity:<#>) (unlimit_stack_size) (to:<inventory>) (slot:<slot>) (allowed_slots:<slot-matcher>) (ignore_leftovers) |
Short Description | Gives the player an item or xp. |
Full Description | Gives the linked player items.
Optionally specify a slot to put the items into. If the slot is already filled, the next available slot will be used. If the inventory is full, the items will be dropped on the ground at the inventory's location. For player inventories, only the storage contents are valid - to equip armor or an offhand item, use equip. Specifying "unlimit_stack_size" will allow an item to stack up to 64. This is useful for stacking items with a max stack size that is less than 64 (for example, most weapon and armor items have a stack size of 1). When giving an item, you can specify any valid inventory as a target. If unspecified, the linked player's inventory will be used. You may optionally specify a "slot" as any valid slot input per Slot Inputs to be the starting slot index. You may optionally specify "allowed_slots" to forcibly restrict the item to only be given to certain specific slots that match a slot-matcher. You may optionally specify "ignore_leftovers" to cause leftover items to be ignored. If not specified, leftover items will be dropped. To give xp to a player, use experience. To give money to a player, use money. |
Related Tags | <PlayerTag.inventory> Returns a InventoryTag of the player's current inventory. (...)
<entry[saveName].leftover_items> returns a ListTag of any item(s) that didn't fit into the inventory.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/GiveCommand.java#L31 |
Name | Group |
Syntax | group [add/remove/set] [<group>] (<world>) |
Short Description | Adds a player to, removes a player from, or sets a player's permissions group. |
Full Description | Controls a player's permission groups, which the ability to add, remove or set a player's groups.
The 'add' argument adds the player to the group and any parent groups, and the 'remove' command does the opposite, removing the player from the group and any inheriting groups. The set command removes all existing groups and sets the player's group. Note: This requires a permissions plugin and Vault. |
Related Tags | <PlayerTag.in_group[<group>]> Returns whether the player is in the specified group. (...)
<PlayerTag.in_group[<group>].global> Returns whether the player has the group with no regard to the (...)
<PlayerTag.in_group[<group>].world> Returns whether the player has the group in regards to a specific world. (...)
<PlayerTag.groups[(<world>)]> Returns a list of all groups the player is in. (...)
<server.permission_groups> Returns a list of all permission groups on the server.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Requires | Vault |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/GroupCommand.java#L24 |
Name | Heal |
Syntax | heal (<#.#>) ({player}/<entity>|...) |
Short Description | Heals the player or list of entities. |
Full Description | This command heals a player, list of players, entity or list of entities.
If no amount is specified it will heal the specified player(s)/entity(s) fully. |
Related Tags | <EntityTag.health> Returns the current health of the entity.
<EntityTag.health_max> Returns the maximum health of the entity.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/HealCommand.java#L26 |
Name | Health |
Syntax | health ({npc}/<entity>|...) [<#>] (state:{true}/false/toggle) (heal) |
Short Description | Changes the target's maximum health. |
Full Description | Use this command to modify an entity's maximum health.
If the target is an NPC, you can use the 'state' argument to enable, disable, or toggle the Health trait (which is used to track the NPC's health, and handle actions such as 'on death'). The Health trait will be enabled by default. By default, this command will target the linked NPC but can be set to target any other living entity, such as a player or mob. Optionally specify the 'heal' argument to automatically heal the entity to the new health value. If not specified, the entity's health will remain wherever it was (so for example a change from 20 max to 50 max will leave an entity with 20 health out of 50 max). Additionally, you may input a list of entities, each one will calculate the effects explained above. |
Related Tags | <EntityTag.health> Returns the current health of the entity.
<EntityTag.health_max> Returns the maximum health of the entity.
<NPCTag.has_trait[health]> Returns whether the NPC has a specified trait.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/HealthCommand.java#L26 |
Name | Hurt |
Syntax | hurt (<#.#>) ({player}/<entity>|...) (cause:<cause>) (source:<entity>/<location>) |
Short Description | Hurts the player or a list of entities. |
Full Description | Does damage to a list of entities, or to any single entity.
If no entities are specified: if there is a linked player, the command targets that. If there is no linked player but there is a linked NPC, the command targets the NPC. If neither is available, the command will error. Does a specified amount of damage usually, but, if no damage is specified, does precisely 1HP worth of damage (half a heart). Optionally, specify (source:<entity>) to make the system treat that entity as the attacker. If using a block-type cause such as "contact", you *must* specify (source:<location>) to set that block location as the attacker. The block can be any block, even just "<player.location>" (as long as the player in inside a world). You may also specify a damage cause to fire a proper damage event with the given cause, only doing the damage if the event wasn't cancelled. Calculates the 'final damage' rather than using the raw damage input number. See damage cause for damage causes. Using a valid 'cause' value is best when trying to replicate natural damage, excluding it is best when trying to force the raw damage through. Note that using invalid or impossible causes may lead to bugs |
Related Tags | <EntityTag.health> Returns the current health of the entity.
<EntityTag.last_damage.amount> Returns the amount of the last damage taken by the entity.
<EntityTag.last_damage.cause> Returns the cause of the last damage taken by the entity.
<EntityTag.last_damage.duration> Returns the duration of the last damage taken by the entity.
<EntityTag.last_damage.max_duration> Returns the maximum duration of the last damage taken by the entity.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | damage, injure |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/HurtCommand.java#L31 |
Name | Image |
Syntax | image [id:<id>] [load [image:<image>/path:<path>]]/[save [path:<path>] [format:<format>]]/[unload] |
Short Description | Loads, saves, and unloads images. |
Full Description | Loads, saves, and unloads images.
With "load", specify either a file path to read from or an image object to load. With "save", specify a file path to save the image to and a format to save the image in (e.g. "png", "jpg", "bmp"...), defaults to "png". For both of these the starting path is "plugins/Denizen". Use waitable syntax ("- ~image") when loading or saving from a file to avoid locking up the server during file IO, refer to ~waitable. All uses of the image command must include the "id:" argument. This is any arbitrary name, as plaintext or from a tag, to uniquely and globally identify the image object in memory. This ID can only be used by one image object at a time. IDs are stored when "load" is used, and only removed when "unload" is used. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | image |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/ImageCommand.java#L27 |
Name | Inventory |
Syntax | inventory [open/close/copy/move/swap/set/keep/exclude/fill/clear/update/adjust <mechanism>:<value>/flag <name>(:<action>)[:<value>] (expire:<time>)] (destination:<inventory>) (origin:<inventory>/<item>|...) (slot:<slot>) |
Short Description | Edits the inventory of a player, NPC, or chest. |
Full Description | Use this command to edit the state of inventories.
By default, the destination inventory is the current attached player's inventory. If you are copying, swapping, removing from (including via "keep" and "exclude"), adding to, moving, or filling inventories, you'll need both destination and origin inventories. Origin inventories may be specified as a list of ItemTags, but destinations must be actual InventoryTags. Using "open", "clear", or "update" only require a destination. "Update" also requires the destination to be a valid player inventory. Using "close" closes any inventory that the currently attached player has opened. The "adjust" option adjusts mechanisms on an item within a specific slot of an inventory (the "slot" parameter is required). Note that this is only for items, it does NOT adjust the inventory itself. Use adjust to adjust an inventory mechanism. The "flag" option sets a flag on items, similar to flag. See also flag system. The "update" option will refresh the client's view of an inventory to match the server's view, which is useful to workaround some sync bugs. Note that to add items to an inventory, you should usually use give, and to remove items from an inventory, you should usually use take. The slot argument can be any valid slot, see Slot Inputs. |
Related Tags | <PlayerTag.inventory> Returns a InventoryTag of the player's current inventory. (...)
<PlayerTag.enderchest> Gets the player's enderchest inventory. (...)
<PlayerTag.open_inventory> Gets the inventory the player currently has open. If the player has no open (...)
<NPCTag.inventory> Returns the InventoryTag of the NPC.
<LocationTag.inventory> Returns the InventoryTag of the block at the location. If the (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/InventoryCommand.java#L95 |
Name | Kill |
Syntax | kill ({player}/<entity>|...) |
Short Description | Kills the player or a list of entities. |
Full Description | Kills a list of entities, or a single entity.
If no entities are specified, the command targets the linked player. If there is no linked player, the command targets the linked NPC. If neither is available, the command errors. |
Related Tags | <EntityTag.is_spawned> Returns whether the entity is spawned.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/KillCommand.java#L25 |
Name | Light |
Syntax | light [<location>] [<#>/reset] (duration:<duration>) |
Short Description | Creates a light source at the location with a specified brightness. |
Full Description | This command can create and reset a light source at a specified location, regardless of the type of block.
It will be shown to all players near the location until it is reset. The brightness must be between 0 and 15, inclusive. Optionally, specify the amount of time the light should exist before being removed. Note that lights do not persist across server restarts, but will still be visible in the world after a restart until there is a block change near the location (to reset the light). |
Related Tags | <LocationTag.light> Returns the total amount of light on the location.
<LocationTag.light.blocks> Returns the amount of light from light blocks that is (...)
|
Usage Example |
|
Usage Example |
|
Group | world |
Warning(s) | May cause lag spikes, use carefully.
Incompatible with Paper in 1.17+. Use Spigot, or use vanilla Light blocks. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/LightCommand.java#L24 |
Name | Log |
Syntax | log [<text>] (type:{info}/severe/warning/fine/finer/finest/none/clear) [file:<name>] |
Short Description | Logs some debugging info to a file. |
Full Description | This is a quick and simple way to store debugging information for admins to read.
You just input a file name and some text, and it will store that information in the file with a date/time stamp and the chosen type ('INFO' by default). If you don't want the date/time stamp and type, you can set the type to 'none' and it will only add the message text. Regardless of type, each usage of the log command will add a new line to the file, you can't just keep adding to one line. You might choose to use this to record some important things, for example, every time a player uses a dangerous command you might log the player's name and their location, so you'll know who to blame if you find something damaged. Remember that the file location is inside the server's primary folder. You most likely want to prefix file names with a folder name, For example: 'file:logs/security.log' If the file or folder path you input do not already exist, they will be automatically created. Warning: Remember that file operations are dangerous! A typo in the filename could ruin your server. It's recommended you use this command minimally. This command can be disabled by setting Denizen config option "Commands.Log.Allow logging" to false. This should almost always be ~waited for. Refer to ~waitable. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | textfile |
Group | file |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/LogCommand.java#L26 |
Name | LookClose |
Syntax | lookclose (<npc>) (state:<true/false>) (range:<#>) (realistic) |
Short Description | Interacts with an NPCs 'lookclose' trait as provided by Citizens. |
Full Description | Use this command with any NPC to alter the state and options of its 'lookclose' trait.
When an NPC's 'lookclose' trait is toggled to true, the NPC's head will follow nearby players. Specifying realistic will enable a higher precision and detection of players, while taking into account 'line-of-sight', however can use more CPU cycles. You may also specify a range integer to specify the number of blocks that will trigger the NPC's attention. |
Related Tags | <NPCTag.lookclose> Returns whether the NPC has lookclose enabled.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/LookcloseCommand.java#L23 |
Name | Map |
Syntax | map [<#>/new:<world>] (reset:<location>) (scale:<value>) (tracking) (image:<file>) (resize) (script:<script>) (dot:<color>) (radius:<#>) (x:<#>) (y:<#>) (text:<text>) |
Short Description | Modifies a new or existing map by adding images or text. |
Full Description | This command modifies an existing map, or creates a new one. Using this will override existing non-Denizen map renderers with Denizen's custom map renderer.
You must specify at least one of 'reset', 'script', 'image', 'dot', 'text'. You can specify multiple at once if you prefer. When using 'reset', you can specify optionally 'scale' and/or 'tracking'. When using 'image' you can optionally specify 'resize'. When using 'dot', you can specify any valid ColorTag (it will be compressed to map's color space), and you can optionally also specify 'radius' as a number. Use "radius:0" with dot to set on a single pixel. 1 or higher will make a circle centered on the x/y given. You can reset this at any time by using the 'reset:<location>' argument, which will remove all images and texts on the map and show the default world map at the specified location. You can also specify 'reset' without a location. The 'scale' argument takes input of one of the values listed here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/map/MapView.Scale.html The 'tracking' argument determines if the map will track its location on the map it displays. This is often the player holding the map's location. Note that all maps have a size of 128x128. The file path is relative to the 'plugins/Denizen/images/' folder. Instead of a local file path, an http(s) URL can be used, which will automatically download the image from the URL given. If the file path points to a .gif, the map will automatically be animated. Use escaping to let the image and text arguments have tags based on the player viewing the map. Custom maps will persist over restarts using the 'maps.yml' save file in the Denizen plugins folder. |
Related Tags | <entry[saveName].created_map> returns the map created by the 'new:' argument if used.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/MapCommand.java#L33 |
Name | mcMMO |
Syntax | mcmmo [add/remove/set] [levels/xp/xprate/vampirism/hardcore/leader] (skill:<skill>) (state:{toggle}/true/false) (quantity:<#>) (party:<party>) |
Short Description | Edits mcMMO information. |
Full Description | This command allows you to add or remove skill levels and experience for players, add or remove
players to/from parties, set the level, xp, xprate, vampirism state, hardcore state of a player's skill, or set the leader of a party. |
Related Tags | <PlayerTag.mcmmo.party> Returns the name of the player's party.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, mcMMO |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mcmmo/McMMOCommand.java#L26 |
Name | Midi |
Syntax | midi [cancel/<file> (tempo:<#.#>) (volume:<#.#>)] (<location>/<entity>|...) |
Short Description | Plays a midi file at a given location or to a list of players using note block sounds. |
Full Description | This will fully load a midi song file stored in the '../plugins/Denizen/midi/' folder.
The file must be a valid midi file with the extension '.mid'. It will continuously play the song as noteblock songs at the given location or group of players until the song ends. If no location or entity is specified, by default this will play for the attached player. Also, an example Midi song file has been included: "Denizen" by Black Coyote. He made it just for us! Check out more of his amazing work at: http://www.youtube.com/user/BlaCoyProductions The midi command is ~waitable. Refer to ~waitable. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | music |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/MidiCommand.java#L30 |
Name | MobArena |
Syntax | mobarena [<mobarena>] (add:<player>|...) (remove:<player>|...) (spectate:<player>|...) |
Short Description | Make a player join, remove a player from or make a player spectate a MobArena. |
Full Description | This command allows you to make a player join an arena, make them leave an arena or make them spectate an arena.
Follows normal MobArena functionality, so acts as if the player has typed '/mobarena join'. NOTE: You can use all 3: ("add", "remove", and "spectate") as once, however avoid conflicts. |
Related Tags | <player.mobarena.in_arena> Returns whether the player is in an arena.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, MobArena |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mobarena/MobArenaCommand.java#L23 |
Name | ModifyBlock |
Syntax | modifyblock [<location>|.../<ellipsoid>/<cuboid>] [<material>|...] (no_physics/naturally:<tool>) (delayed) (<script>) (<percent chance>|...) (source:<player>) (max_delay_ms:<#>) |
Short Description | Modifies blocks. |
Full Description | Changes blocks in the world based on the criteria given.
Use 'no_physics' to place the blocks without physics taking over the modified blocks. This is useful for block types such as portals or water. This does NOT control physics for an extended period of time. Specify (<percent chance>|...) to give a chance of each material being placed (in any material at all). Use 'naturally:' when setting a block to air to break it naturally, meaning that it will drop items. Specify the tool item that should be used for calculating drops. Use 'delayed' to make the modifyblock slowly edit blocks at a time pace roughly equivalent to the server's limits. Optionally, specify 'max_delay_ms' to control how many milliseconds the 'delayed' set can run for in any given tick (defaults to 50). Note that specifying a list of locations will take more time in parsing than in the actual block modification. Optionally, specify a script to be ran after the delayed edits finish. (Doesn't fire if delayed is not set.) Optionally, specify a source player. When set, Bukkit events will fire that identify that player as the source of a change, and potentially cancel the change. The source argument might cause weird interoperation with other plugins, use with caution. The modifyblock command is ~waitable. Refer to ~waitable. |
Related Tags | <LocationTag.material> Returns the material of the block at the location.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | setblock, changeblock, placeblock, breakblock |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/ModifyBlockCommand.java#L62 |
Name | Mongo |
Syntax | mongo [id:<ID>] [connect:<uri> database:<database> collection:<collection>/disconnect/command:<map>/find:<map> (by_id:<id>)/insert:<map>/update:<update> new:<new> (upsert:true/{false})/use_database:<database>/use_collection:<collection>] |
Short Description | Interacts with a MongoDB server. |
Full Description | This command is used to interact with a MongoDB server.
MongoDB is a NoSQL database which uses concepts such as Documents and Collections to store data. MongoDB uses a form of JSON to represent its data. It can interact with localhost connections as well as hosted connections (such as MongoDB's Atlas) via a connection URI. Store your connection URI in the Denizen secrets file at 'plugins/Denizen/secrets.secret'. Refer to SecretTag for usage info. Mongo works as a document-oriented database, where data is stored in Documents. Documents are stored inside Collections. Collections can contain many Documents. Collections are then stored inside Databases. Usage of the mongo command should almost always be used as ~waitable (see ~waitable), as large queries and insertions can take a while to retrieve or send. You can open a mongo connection with connect:<uri>. You must specify a database and collection to connect to with the database:<database> and collection:<collection> options. You can change the database or collection you are connected to with use_database:<database> and use_collection:<collection> If a Database or Collection you connect to does not exist, once you insert some data then the Database or Collection will be created automatically. To insert Documents, use insert:<map>. To find a specific document from fragments of data, use find:<map>. You can include MongoDB's special query filters to further refine your query. If you want to search by a Document's ID, use by_id:id. To update a Document's data, use update:<update> with the old data, and new:<new> for the new data being updated. This will update every Document matched with the provided data. You can also include the upsert flag, to create a new Document if the Document you are trying to update does not already exist. As MongoDB offers a variety of commands, to run a command not wrapped here you can use command:<map>. TODO: When opening a connection, Mongo will output a lot of data to the console. There currently is not a way to turn this off. The mongo command is merely a wrapper, and further usage details should be gathered from an official MongoDB command reference rather than from Denizen command help. You can view the official mongo documentation here: https://www.mongodb.com/docs/manual/introduction/. You can view a list of commands that MongoDB supports here: https://www.mongodb.com/docs/manual/reference/command/. |
Related Tags | <util.mongo_connections> returns a ListTag of all the current Mongo connections.
<entry[saveName].result> returns the text result sent back from Mongo in a JSON format. JSON can be in an ElementTag or a ListTag depending on the action run.
<entry[saveName].inserted_id> returns the ID of the item that has been inserted via the `insert` action.
<entry[saveName].ok> returns the 'ok' value from the result. Used with the `command` action.
<entry[saveName].upserted_id> returns the ID the upserted item. Returned if the `upsert` bool is true when updating.
<entry[saveName].updated_count> returns the amount of Documents updated via the `update` action.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/MongoCommand.java#L36 |
Name | nbs |
Syntax | nbs [play/stop] (file:<file_path>) (targets:<entity>|...) (at:<location>) (distance:<#>/{16}) |
Short Description | Plays or stops a noteblock song. |
Full Description | Plays a .nbs file for the targets, being players specified.
If no targets are specified, the target will be the player in the queue. Optionally specify the location to play the song from using the 'at' argument. Players must still be added using 'targets' in order to hear the song when they are within range. Setting 'distance' will change the range in blocks that a player must be in to hear the song. Numbers below 16 will decrease volume, not decrease range. Numbers greater than 16 will increase range. Note block song files are created using NoteBlockStudio or other programs. The file path starts in the denizen folder: /plugins/Denizen/ The nbs command is ~waitable. Refer to ~waitable. |
Related Tags | <PlayerTag.nbs_is_playing> Returns true if the player is currently listening to a note block song.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, NoteBlockAPI |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/noteblockapi/NBSCommand.java#L40 |
Name | Pause |
Syntax | pause [waypoints/activity] (<duration>) |
Short Description | Pauses an NPC's waypoint navigation or goal activity temporarily or indefinitely. |
Full Description | The pause command pauses an NPC's waypoint navigation or goal activity temporarily or indefinitely.
This works along side resume. "Waypoints" refers to the NPC's path navigation, usually set via "/npc path". "Activity" refers to the Citizens AI Goal system, which may be used by some plugins but usually is not. If no duration is specified, the resume command must be used to unpause it. |
Related Tags | <NPCTag.is_navigating> Returns whether the NPC is currently navigating.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/PauseCommand.java#L35 |
Name | PlayEffect |
Syntax | playeffect [effect:<name>] [at:<location>|...] (data:<#.#>) (special_data:<map>) (visibility:<#.#>) (quantity:<#>) (offset:<#.#>,<#.#>,<#.#>) (targets:<player>|...) (velocity:<vector>) |
Short Description | Plays a visible or audible effect at the location. |
Full Description | Allows the playing of particle effects anywhere without the need of the source it comes from originally.
The particles you may use, can come from sources such as a potion effect or a portal/Enderman with their particles respectively. Some particles have different data which may include different behavior depending on the data. Default data is 0 Specifying a visibility value changes the sight radius of the effect. For example if visibility is 15; Targeted players won't see it unless they are 15 blocks or closer. You can add a quantity value that allow multiple of the same effect played at the same time. If an offset is set, each particle will be played at a different location in the offset area. Everyone will see the particle effects unless a target has been specified. See Particle Effects for a list of valid effect names. Version change note: The original PlayEffect command raised all location inputs 1 block-height upward to avoid effects playing underground when played at eg a player's location. This was found to cause too much confusion, so it is no longer on by default. However, it will still happen for older commands. The distinction is in whether you include the (now expected to use) "at:" prefix on your location argument. If you do not have this prefix, the system will assume your command is older, and will apply the 1-block height offset. Some particles will require input to the "special_data" argument. The data input is a MapTag with different keys per particle. - For DUST particles, the input is of format [size=<size>;color=<color>], e.g. "[size=1.2;color=red]". - For DUST_COLOR_TRANSITION particles, the input is of format [size=<size>;from=<color>;to=<color>], e.g "[size=1.2;from=red;to=blue]". - For BLOCK, BLOCK_CRUMBLE, BLOCK_MARKER, DUST_PILLAR, or FALLING_DUST particles, the input is of format [material=<material>], e.g. [material=stone] - For VIBRATION particles, the input is of format [origin=<location>;destination=<location/entity>;duration=<duration>], for example: [origin=<player.location>;destination=<player.cursor_on>;duration=5s] - For ITEM particles, the input is of format [item=<item>], e.g. "[item=stick]". - For TRAIL particles, the input is of format [color=<color>;target=<location>;duration=<duration>], e.g. "[color=red;target=<player.cursor_on>;duration=20s]". - For ENTITY_EFFECT particles, the input is of format [color=<color>], e.g. "[color=green]". - For SHRIEK particles, the input is of format [duration=<duration>], e.g. "[duration=1m]". - For SCULK_CHARGE particles, the input is of format [radians=<element>], e.g. "[radians=<element[90].to_radians>]". Optionally specify a velocity vector for standard particles to move. Note that this ignores the 'data' input if used. |
Related Tags | <server.effect_types> Returns a list of all 'effect' types known to the server. (...)
<server.particle_types> Returns a list of all particle effect types known to the server. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | particle |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/PlayEffectCommand.java#L55 |
Name | Push |
Syntax | push [<entity>|...] (origin:<entity>/<location>) (destination:<location>) (speed:<#.#>) (duration:<duration>) (script:<name>) (def:<element>|...) (force_along) (precision:<#>) (no_rotate) (no_damage) (ignore_collision) |
Short Description | Pushes entities through the air in a straight line. |
Full Description | Pushes entities through the air in a straight line at a certain speed and for a certain duration,
triggering a script when they hit an obstacle or stop flying. You must specify an entity to be pushed. Usually, you should specify the origin and the destination. If unspecified, they will be assumed from contextual data. You can specify the script to be run with the (script:<name>) argument, and optionally specify definitions to be available in this script with the (def:<element>|...) argument. Using the 'no_damage' argument causes the entity to receive no damage when they stop moving. Optionally use the "ignore_collision" argument to ignore block collisions. Optionally use "speed:#" to set how fast it should be pushed. Optionally use "force_along" to cause the entity to teleport through any blockage. Optionally use "no_rotate" to prevent entities being rotated at the start of the push. Optionally use "duration:#" to set the max length of time to continue pushing. The push command is ~waitable. Refer to ~waitable. |
Related Tags | <EntityTag.velocity> Returns the movement velocity of the entity. (...)
<entry[saveName].pushed_entities> returns the list of pushed entities.
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/PushCommand.java#L40 |
Name | Quests |
Syntax | quests [add/remove/set] (quest:<quest_id>) (stage:<#>) (points:<#>) (override_checks:{true}/false) |
Short Description | Edits quest player information. |
Full Description | This command allows you to give, quit, or set the stage of a quest for a player, or to add, subtract, or set the amount of Quest Points that a player holds.
When modifying quests, the ID (read: NOT the name) must be specified. Numerical stage number must be present when setting progress. 'override_checks' indicates whether to bypass associated checks (see Usage). If not modifying a quest, points must be included as a numerical value. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, Quests |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/quests/QuestsCommand.java#L26 |
Name | Queue |
Syntax | queue (<queue>) [clear/stop/pause/resume/delay:<duration>] |
Short Description | Modifies the current state of a script queue. |
Full Description | Allows queues to be modified during their run. This can also be used to modify other queues currently running.
Clearing a queue will remove any commands still queued within it, and thus end the queue. When trying to clear the current queue, use stop instead. Using the "stop" argument will force the queue to immediately stop running. When trying to stop the current queue, use stop instead. Using the "delay:<duration>" argument will cause the queue to wait for a specified duration. When trying to delay the current queue, use wait instead. Using the "pause" argument will freeze the queue but keep it listed, waiting for a "resume" instruction. It is of course not possible to resume the current queue (as if you're running a 'queue' command, the queue can't be paused). Generally, the queue is considered a non-ideal way of doing things - that is, there's usually a better/cleaner way to achieve similar results. It's most useful within the "/ex" command for quick problem solving (eg if a script in testing gets caught in an infinite loop, you can do "/ex queue ID_HERE stop" to fix that). |
Related Tags | <queue> Returns a queue object constructed from the input value. (...)
<QueueTag.id> Returns the full textual id of the queue.
<QueueTag.size> Returns the number of script entries in the queue.
<util.queues> Returns a list of all currently running queues on the server.
<ScriptTag.queues> Returns all queues which are running for this script.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/QueueCommand.java#L22 |
Name | Redis |
Syntax | redis [id:<ID>] [connect:<host> (auth:<secret>) (port:<port>/{6379}) (ssl:true/{false})/disconnect/subscribe:<channel>|.../unsubscribe/publish:<channel> message:<message>/command:<command> (args:<arg>|...)] |
Short Description | Interacts with a Redis server. |
Full Description | This command is used to interact with a redis server. It can run any standard redis commands as well as subscribe for pub/sub redis channel notifications.
Redis is a simple key/value data store that is typically used for caching and sending data between servers. The redis server runs in memory, meaning requests are insanely fast. If you run redis locally, you can expect responses to take under a millisecond. It is normally advised to run commands as ~waitable (see ~waitable), but because of the usual fast responses when the server is on localhost, you can also run commands without ~waiting. When running commands, make sure to escape unpredictable values such as player input. Alternatively, include the main redis command as the 'command' input and further arguments as a ListTag input for 'args'. This command supports subscribing to pub/sub redis channels. This allows you to listen to published messages to redis from any source, including other servers. When you subscribe to a channel, matching messages sent to the channel will trigger the redis pubsub message event. Connections that are subscribed to channels get tied up listening for messages and are unavailable to run redis commands. The channels you subscribe to support wildcard (*) matchers and other patterns, defined by the redis docs: https://redis.io/commands/psubscribe Note: Make sure there are at least a few ticks between opening a subscription and closing it, otherwise strange behavior will occur. You can publish messages to listening subscribers via publish:<channel> message:<message>. Note that this has to be done on a separate redis connection if it is already subscribed. Saving the result of this call returns the number of connected subscribers the message was sent to. The redis command is merely a wrapper, and further usage details should be gathered from an official redis command reference rather than from Denizen command help. You can view the official redis documentation and the supported commands here: https://redis.io/ |
Related Tags | <entry[saveName].result> returns an ElementTag or ListTag of the results of your command, depending on the redis command you ran.
<util.redis_connections> Returns a list of all Redis connections opened by redis.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/RedisCommand.java#L25 |
Name | ReflectionSet |
Syntax | reflectionset [object:<object>] [field:<name>] (value:<value>) |
Short Description | Sets a field on an object to a given value, or null. |
Full Description | Give a JavaReflectedObjectTag as the object, a field name, and a value (or leave off for null) to set the value of a field on that object.
Uses reflection to set, and so can bypass 'private' or 'final' field limits if permitted by config. If the value is fed as a general ObjectTag, automatic conversion will be attempted. If automatic conversion is not possible, you must pass a JavaReflectedObjectTag with the appropriate type as the value. Requires config setting "Reflection.Allow set command". |
Related Tags | <ObjectTag.reflected_internal_object> Returns the reflected internal Java object for a given ObjectTag.
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/ReflectionSetCommand.java#L30 |
Name | region |
Syntax | region [{add} <cuboid>/remove <world>] [id:<name>] |
Short Description | Adds or removes a protected region. |
Full Description | Adds a protected region to a region manager based on the specified cuboid,
or removes a protected region from a region manager based on the specified world. Currently, this command only supports cuboid-shaped regions. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, WorldGuard |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/worldguard/RegionCommand.java#L27 |
Name | Remove |
Syntax | remove [<entity>|...] (world:<world>) |
Short Description | Despawns an entity or list of entities, permanently removing any NPCs. |
Full Description | Removes the selected entity. May also take a list of entities to remove.
Any NPC removed this way is completely removed, as if by '/npc remove'. For temporary NPC removal, see despawn. If a generic entity name is given (like 'zombie'), this will remove all entities of that type from the given world. Optionally, you may specify a world to target. (Defaults to the world of the player running the command) |
Related Tags | <EntityTag.is_spawned> Returns whether the entity is spawned.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/RemoveCommand.java#L28 |
Name | Rename |
Syntax | rename [<name>/cancel] (t:<entity>|...) (per_player) (for:<player>|...) (list_name_only) |
Short Description | Renames the linked NPC or list of entities. |
Full Description | Renames the linked NPC or list of entities.
Functions like the '/npc rename' command. Can rename a spawned or unspawned NPC to any name up to 256 characters. Can rename a vanilla entity to any name up to 256 characters, and will automatically make the nameplate visible. Can rename a player to any name up to 16 characters. This will affect only the player's nameplate. Optionally specify 'per_player' to reprocess the input tags for each player when renaming a vanilla entity (meaning, if you use "- rename <player.name> t:<[someent]> per_player", every player will see their own name on that entity). A per_player rename will remain active until the entity is renamed again or the server is restarted. Rename to "cancel" per_player to intentionally end a per_player rename. Optionally specify "for:" a list of players when using per_player. Optionally specify 'list_name_only' to only change the tab list name for a player. Works with 'per_player'. |
Related Tags | <EntityTag.name> Returns the name of the entity. (...)
<NPCTag.nickname> Returns the NPC's display name, as set by the Nickname trait (or the default NPC name).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/RenameCommand.java#L41 |
Name | Reset |
Syntax | reset (<player>|...) [cooldown/global_cooldown] (<script>) |
Short Description | Resets various parts of Denizen's interact save data, including a script's cooldowns. |
Full Description | This command can reset save data for a player, or globally.
The "cooldown" argument removes the player's cooldown for a specific script, as set by cooldown. The "global_cooldown" argument removes all cooldowns for the specified script (not player-specific). |
Related Tags | None
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/core/ResetCommand.java#L23 |
Name | ResourcePack |
Syntax | resourcepack [url:<url>] [hash:<hash>] (forced) (prompt:<text>) (targets:<player>|...) |
Short Description | Prompts a player to download a server resource pack. |
Full Description | Sets the current resource pack by specifying a valid URL to a resource pack.
The player will be prompted to download the pack, with the optional prompt text or a default vanilla message. Once a player says "yes" once, all future packs will be automatically downloaded. If the player selects "no" once, all future packs will automatically be rejected. Players can change the automatic setting from their server list in the main menu. Use "hash:" to specify a 40-character (20 byte) hexadecimal SHA-1 hash value (without '0x') for the resource pack to prevent redownloading cached data. Specifying a hash is required, though you can get away with copy/pasting a fake value if you don't care for the consequences. There are a variety of tools to generate the real hash, such as the `sha1sum` command on Linux, or using the 7-Zip GUI's Checksum option on Windows. Specify "forced" to tell the vanilla client they must accept the pack or quit the server. Hacked clients may still bypass this requirement. "Forced" and "prompt" inputs only work on Paper servers. Optionally specify players to send the pack to. If unspecified, will use the linked player. See also resource pack status. |
Related Tags | None
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ResourcePackCommand.java#L28 |
Name | Resume |
Syntax | resume [waypoints/activity] (<duration>) |
Short Description | Resumes an NPC's waypoint navigation or goal activity temporarily or indefinitely. |
Full Description | The resume command resumes an NPC's waypoint navigation or goal activity temporarily or indefinitely.
This works along side pause. See the documentation of the pause command for more details. |
Related Tags | <NPCTag.is_navigating> Returns whether the NPC is currently navigating.
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/PauseCommand.java#L71 |
Name | Rotate |
Syntax | rotate (cancel) (<entity>|...) (yaw:<#.#>) (pitch:<#.#>) (infinite/duration:<duration>) (frequency:<duration>) |
Short Description | Rotates a list of entities. |
Full Description | Induces incremental rotation on a list of entities over a period of time.
The yaw and pitch arguments specify how much the entity will rotate each step. Default to 10 and 0 respectively. The frequency argument specifies how long it takes between each rotation step. Defaults to 1t. The duration argument specifies how long the whole rotation process will last. Defaults to 1s. Alternatively, use "infinite" if you want the entity to spin forever. You can use "cancel" to prematurely stop the ongoing rotation (useful when set to infinite) The rotate command is ~waitable. Refer to ~waitable. |
Related Tags | <EntityTag.location> Returns the location of the entity. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | spin |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/RotateCommand.java#L30 |
Name | Run |
Related Guide Page | https://guide.denizenscript.com/guides/basics/run-options.html |
Syntax | run [<script>] (path:<name>) (def:<element>|.../defmap:<map>/def.<name>:<value>) (id:<name>) (speed:<value>/instantly) (delay:<value>) |
Short Description | Runs a script in a new queue. |
Full Description | Runs a script in a new queue.
You must specify a script object to run. Optionally, use the "path:" argument to choose a specific sub-path within a script. Optionally, use the "def:" argument to specify definition values to pass to the script, the definitions will be named via the "definitions:" script key on the script being ran, or numerically in order if that isn't specified (starting with <[1]>). Alternately, use "defmap:<map>" to specify definitions to pass as a MapTag, where the keys will be definition names and the values will of course be definition values. Alternately, use "def.<name>:<value>" to define one or more named definitions individually. Optionally, use the "speed:" argument to specify the queue command-speed to run the target script at, or use the "instantly" argument to use an instant speed (no command delay applied). If neither argument is specified, the default queue speed applies (normally instant, refer to the config file). Generally, prefer to set the "speed:" script key on the script to be ran, rather than using this argument. Optionally, use the "delay:" argument to specify a delay time before the script starts running. Optionally, specify the "id:" argument to choose a custom queue ID to be used. If none is specified, a randomly generated one will be used. Generally, don't use this argument. The run command is ~waitable. Refer to ~waitable. |
Related Tags | <entry[saveName].created_queue> returns the queue that was started by the run command.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/RunCommand.java#L31 |
Name | RunLater |
Syntax | runlater [<script>] (path:<name>) [delay:<duration>] (id:<id>) (def:<element>|.../defmap:<map>/def.<name>:<value>) |
Short Description | Causes a task to run sometime in the future, even if the server restarts. |
Full Description | Causes a task to run sometime in the future, even if the server restarts.
Script, path, and definition inputs work the exact same as with run. This command will store intended script runs to a file, so that even if the server restarts, they will still run. Script runs are guaranteed to happen after the time is up - if the server is turned off at the scheduled time, they will run at next startup. The guarantee can be broken if the server crashes or other errors occur. The delay input is a DurationTag instance, that is relative to system time (not server delta time). Definitions and queue object links will be preserved, so long as they remain valid at time of execution. Objects that are lost before the delay is up (such as a linked NPC that is removed) may cause errors. You can optionally specify the "id" argument to provide a unique tracking ID for the intended future run, which can then also be used to cancel it via system.cancel_runlater. If you use IDs, they must be unique - you cannot have the same ID scheduled twice. Use util.runlater_ids if you need to dynamically check if an ID is in use. Implementation note: the system that tracks when scripts should be ran is a fair bit more optimized than 'wait' commands or the 'run' command with a delay, specifically for the case of very large delays (hours or more) - in the short term, 'wait' or 'run' with a delay will be better. |
Related Tags | <util.runlater_ids> Returns a list of all scheduled task IDs for runlater. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/RunLaterCommand.java#L36 |
Name | Schematic |
Syntax | schematic [create/load/unload/rotate/save/flip_x/flip_y/flip_z/paste (fake_to:<player>|... fake_duration:<duration>) (noair) (mask:<material_matcher>)] [name:<name>] (filename:<name>) (angle:<#>) (<location>) (area:<area>) (delayed) (max_delay_ms:<#>) (entities) (flags) |
Short Description | Creates, loads, pastes, and saves schematics (Sets of blocks). |
Full Description | Creates, loads, pastes, and saves schematics. Schematics are files containing info about blocks and the order of those blocks.
Denizen offers a number of tools to manipulate and work with schematics. Schematics can be rotated, flipped, pasted with no air, or pasted with a delay. All schematic command usages must specify the "name" argument, which is a unique global identifier of the schematic in memory. This will be created by "create" or "load" options, and persist in memory until "unload" is used (or the server is restarted). The 'create' option requires an area and a center location as input. The area can be defined as any valid AreaObject, such as a CuboidTag. Note that all schematics are internally tracked as cuboids, and other area shapes will only constrain the copy region. Note that the block boundaries of non-cuboid regions are defined by whether the region definition contains the center of a block. This will create a new schematic in memory based on world data. The "rotate angle:#" and "flip_x/y/z" options will apply the change to the copy of the schematic in memory, to later be pasted or saved. This will rotate the set of blocks itself, the relative origin, and any directional blocks inside the schematic. Rotation angles must be a multiple of 90 degrees. When using 'paste', you can specify 'angle:#' to have that paste rotated, without rotating the original schematic. The "delayed" option makes the command non-instant. This is recommended for large schematics. For 'save', 'load', and 'rotate', this processes async to prevent server lockup. For 'paste' and 'create', this delays how many blocks can be processed at once, spread over many ticks. Optionally, specify 'max_delay_ms' to control how many milliseconds the 'delayed' set can run for in any given tick (defaults to 50) (for create/paste only). The "load" option by default will load '.schem' files. If no '.schem' file is available, will attempt to load a legacy '.schematic' file instead. For load and save, the "filename" option is available to specify the name of the file to look for. If unspecified, the filename will default to the same as the "name" input. The "noair" option skips air blocks in the pasted schematics- this means those air blocks will not replace any blocks in the target location. The "mask" option can be specified to limit what block types the schematic will be pasted over. When using "create" and "mask", any block that doesn't match the mask will become a structure void. The "fake_to" option can be specified to cause the schematic paste to be a fake (packet-based, see showfake) block set, instead of actually modifying the blocks in the world. This takes an optional duration as "fake_duration" for how long the fake blocks should remain. The "create" and "paste" options allow the "entities" argument to be specified - when used, entities will be copied or pasted. At current time, entity types included will be: Paintings, ItemFrames, ArmorStands. The "create" option allows the "flags" argument to be specified - when used, block location flags will be copied. The schematic command is ~waitable as an alternative to 'delayed' argument. Refer to ~waitable. To delete a schematic file, use server.delete_file. |
Related Tags | <schematic[<name>].height> Returns the height (Y) of the schematic.
<schematic[<name>].length> Returns the length (Z) of the schematic.
<schematic[<name>].width> Returns the width (X) of the schematic.
<schematic[<name>].block[<location>]> Returns the material for the block at the location in the schematic. (...)
<schematic[<name>].origin> Returns the origin location of the schematic.
<schematic[<name>].blocks> Returns the number of blocks in the schematic.
<schematic[<name>].exists> Returns whether the schematic exists.
<schematic[<name>].cuboid[<origin_location>]> Returns a cuboid of where the schematic would be if it was pasted at an origin.
<schematic.list> Returns a list of all loaded schematics.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L58 |
Name | Scoreboard |
Syntax | scoreboard ({add}/remove) (viewers:<player>|...) (lines:<player>/<text>|...) (id:<value>/player/{main}) (objective:<value>) (criteria:<criteria>/{dummy}) (score:<#>) (displayslot:<value>/{sidebar}/none) (displayname:<name>) (rendertype:<type>) |
Short Description | Add or removes viewers, objectives and scores from scoreboards. |
Full Description | Lets you make players see a certain scoreboard and then a certain objective in that scoreboard.
Please note that a 'scoreboard' is NOT a 'sidebar' - if you want that thing where text is on the right side of the screen, use sidebar. 'Scoreboard' is the underlying internal system that powers sidebars, below_name plates, team prefixing, and a lot of other systems. Generally, you should avoid using this command directly. The ID can be 'main' for the global default scoreboard, 'player' for the attached player's current scoreboard, or any other value for a custom named scoreboard. There are currently three slots where objectives can be displayed: in the sidebar on the right of the screen, below player names and in the player list that shows up when you press Tab. The names of these slots can be found here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/scoreboard/DisplaySlot.html Every objective has several lines of scores. Technically, the lines track players, but fake player names can be used by Denizen to let you call the lines anything you want. When using the sidebar as the display slot, all the scores set for an objective will be displayed there, but you will need to put actual player names in the lines to be able to use the below_name display slot (which displays each player's score underneath his/her name) and the player_list display slot (which displays each player's score to the right of his/her name in the player list). If you do not specify a display slot, the sidebar will be used. You can also use "none" as the display slot if you want to add a hidden objective without automatically making it get displayed. If the object already exists, and you don't specify the display slot, it will use the existing setting. When setting an objective, you can also optionally set the display name by using the "displayname:" argument. "Rendertype" can be "INTEGER" or "HEARTS". Defaults to integer. You can set scores manually, or you can use different Minecraft criteria that set and update the scores automatically. A list of these criteria can be found here: https://minecraft.wiki/w/Scoreboard#Objectives If the object already exists, and you don't specify the criteria, it will use the existing setting. You can use the "remove" argument to remove different parts of scoreboards. The more arguments you use with it, the more specific your removal will be. For example, if you only use the "remove" argument and the "id" argument, you will completely remove all the objectives in a scoreboard, but if you specify an objective as well, you will only delete that one objective from that scoreboard, and if you also specify certain lines, you will only delete those specific lines from that objective. Similarly, if you use the "remove" argument along with the "id" and "viewers" arguments, you will only remove those viewers from the scoreboard, not the entire scoreboard. |
Related Tags | <server.scoreboard[(<board>)].exists> Returns whether a given scoreboard exists on the server.
<server.scoreboard[(<board>)].team[<team>].members> Returns a list of all members of a scoreboard team. Generally returns as a list of names or text entries. (...)
<PlayerTag.scoreboard_id> Returns the ID of the scoreboard from scoreboard that a player is currently viewing, if any.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/ScoreboardCommand.java#L34 |
Name | Shoot |
Syntax | shoot [<entity>|...] (origin:<entity>/<location>) (destination:<location>) (height:<#.#>) (speed:<#.#>) (script:<name>) (def:<element>|...) (shooter:<entity>) (spread:<#.#>) (lead:<location>) (no_rotate) |
Short Description | Shoots an entity through the air, useful for things like firing arrows. |
Full Description | Shoots an entity through the air up to a certain height, optionally triggering a script on impact with a target.
The launch has three modes: arc, lead, and direct. The "arc" mode calculates a launch arc to exactly hit the target location. If you want to use this, specify the "height" argument as how high the arc should go, in blocks. Do not specify "speed" or "lead". You can optionally specify a custom "gravity" (hidden from syntax line intentionally) if you know what you're doing and really need to. The "lead" mode calculates a modified arc intended to hit a target based on a lead factor (usually the entity's velocity). To use, specify the "lead" argument as a vector and "speed" as a launch speed. Do not specify "height". Generally, most users should prefer direct mode: it just launches straight in the direction of the destination, at the speed you specify. To use this, just input the "speed" argument, and don't specify "height" or "lead". If the origin is not an entity, you can specify a "shooter" so the damage handling code knows who to assume shot the projectile. Normally, a list of entities will spawn mounted on top of each other. To have them instead fire separately and spread out, specify the "spread" argument with a decimal number indicating how wide to spread the entities. Optionally, add "no_rotate" to prevent the shoot command from rotating launched entities. Use the "script:<name>" argument to run a task script when the projectiles land. When that script runs, the following definitions will be available: <[shot_entities]> for all shot entities (as in, the projectiles), <[last_entity]> for the last one (The controlling entity), <[location]> for the last known location of the last shot entity, and <[hit_entities]> for a list of any entities that were hit by fired projectiles. The shoot command is ~waitable. Refer to ~waitable. Note that for ~waiting or the "script" arg, tracking is only accurate for projectile entities (such as arrows). This will be inaccurately estimated for other entity types. |
Related Tags | <entry[saveName].shot_entity> returns the single entity that was shot (as in, the projectile) (if you only shot one).
<entry[saveName].shot_entities> returns a ListTag of entities that were shot (as in, the projectiles).
<entry[saveName].hit_entities> returns a ListTag of entities that were hit (if any). (Only works when you ~wait for the command).
<entry[saveName].location> returns the last known location of the last shot entity. (Only works when you ~wait for the command).
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | launch |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/ShootCommand.java#L52 |
Name | ShowFake |
Syntax | showfake [<material>|.../cancel] [<location>|...] (players:<player>|...) (d:<duration>{10s}) |
Short Description | Makes the player see a block change that didn't actually happen. |
Full Description | Makes the player see a block change that didn't actually happen.
This means that the server will still register the block being what it was before the command, and players not included in the command will still see the original block. You must specify a location (or list of locations), and a material (or list of materials). The material list does not have to be of the same size as the location list (materials will be repeated automatically). Optionally, specify a list of players to show the change to. If unspecified, will default to the linked player. Optionally, specify how long the fake block should remain for. If unspecified, will default to 10 seconds. After the duration is up, the block will revert back to whatever it really is (on the server-side). Note that while the player will see the block as though it were real, the server will have no knowledge of this. This means that if the player, for example, stands atop a fake block that the server sees as air, that player will be seen as flying. The reverse applies as well: if a player walks through fake air (that is actually solid), the server will see a player walking through walls. This can easily lead to players getting kicked by anti-cheat systems or similar results. You can enable the player to walk through fake air via PlayerTag.noclip. Note as well that some clientside block effects may occur (eg fake fire may appear momentarily to actually ignite things, but won't actually damage them). Warning: extremely complex chunks (those with a significant variety of block types in a small area) might not be able to retain fake blocks over time properly. |
Related Tags | <PlayerTag.fake_block_locations> Returns a list of locations that the player will see a fake block at, as set by showfake or connected commands.
<PlayerTag.fake_block[<location>]> Returns the fake material that the player will see at the input location, as set by showfake or connected commands. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | fakeblock |
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ShowFakeCommand.java#L31 |
Name | Sidebar |
Syntax | sidebar (add/remove/{set}/set_line) (title:<title>) (scores:<#>|...) (values:<line>|...) (start:<#>/{num_of_lines}) (increment:<#>/{-1}) (players:<player>|...) (per_player) |
Short Description | Controls clientside-only sidebars. |
Full Description | This command was created as a simpler replacement for using the Scoreboard command to display per-player sidebars.
By using packets and dummies, it enables you to have non-flickering, fully functional sidebars, without wasting processing speed and memory on creating new Scoreboards for every single player. Using this command, you can add, remove, or set lines on the scoreboard. To set the title of the sidebar, use the 'title:' parameter in any case where the action is 'set'. By default, the score numbers descend from the total line count to 1. To customize the automatic score values, use the 'start:' and 'increment:' arguments in any case where the action is 'set'. 'Start' is the score where the first line will be shown with. The default 'start' value is determined by how many items are specified in 'values:'. 'Increment' is the difference between each score and the default is -1. To instead set entirely custom numbers, use the 'scores:' input with a list of numbers, where each number is the score to use with the value at the same place in the 'values:' list. You can remove by line value text, or by score number. The per_player argument is also available, and helps to reduce the number of loops required for updating multiple players' sidebars. When it is specified, all tags in the command will fill based on each individual player in the players list. So, for example, you could have <player.name> on a line and it will show each player specified their name on that line. |
Related Tags | <PlayerTag.sidebar_lines> Returns the current lines set on the player's Sidebar via sidebar.
<PlayerTag.sidebar_title> Returns the current title set on the player's Sidebar via sidebar.
<PlayerTag.sidebar_scores> Returns the current scores set on the player's Sidebar via sidebar, (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/SidebarCommand.java#L37 |
Name | Sneak |
Syntax | sneak [<entity>|...] ({start}/stop) (fake/stopfake) (for:<player>|...) |
Short Description | Causes the entity to start or stop sneaking. |
Full Description | Causes an entity to start or stop sneaking.
If the entity is NPC, adds the SneakingTrait to apply the sneak setting persistent. Can optionally use the 'fake' argument to apply a fake sneak using packets, either globally or for specific players. Use 'stopfake' to disable faking of sneak. A fake sneak only affects the name plate, not the entity's pose. Note: using this command on a player will only show to other players. You cannot alter a player in their own view. Note that EntityTag.is_sneaking is also available. |
Related Tags | <EntityTag.is_sneaking> (Property) Whether an entity is sneaking. (...)
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | crouch, shift |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/SneakCommand.java#L30 |
Name | SQL |
Syntax | sql [id:<ID>] [disconnect/connect:<server> (username:<username>) (password:<secret>) (ssl:true/{false})/query:<query>/update:<update>] |
Short Description | Interacts with a MySQL server. |
Full Description | This command is used to interact with a MySQL server. It can update the database or query it for information.
This commands exists primarily for interoperability with pre-existing databases and external services. It should never be used for storing data that only Denizen needs to use. Consider instead using flag. The general usage order is connect -> update/query -> disconnect. It is not required that you disconnect right after using, and in fact encouraged that you keep a connection open where possible. When connecting, the server format is IP:Port/Database, EG 'localhost:3306/test'. You can also append options to the end, like 'localhost:3306/test?autoReconnect=true' Store your password in the Denizen secrets file at 'plugins/Denizen/secrets.secret'. Refer to SecretTag for usage info. You can switch whether SSL is used for the connection (defaults to false). Note that when using tag, it is recommended you escape unusual inputs to avoid SQL injection. The SQL command is merely a wrapper for SQL queries, and further usage details should be gathered from an official MySQL query reference rather than from Denizen command help. SQL connections are not instant - they can take several seconds, or just never connect at all. It is recommended you hold the command by doing "- ~sql ..." rather than just "- sql ..." as this will delay the commands following the SQL command until after the SQL operation is complete. If you have an SQL database server other than MySQL, be sure to include the driver prefix (defaults to "mysql://" when unspecified). |
Related Tags | <entry[saveName].result_list> returns a ListTag of all row ListTags from a query or update command. That's a ListTag of ListTags, so for example to get the second entry of the first row you'd use "result_list.get[1].get[2]"
<entry[saveName].affected_rows> returns how many rows were affected by an update command.
<util.sql_connections> Returns a list of all SQL connections opened by sql.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/SQLCommand.java#L34 |
Name | Stand |
Syntax | stand |
Short Description | Causes the NPC to stand up from sitting or sleeping. |
Full Description | Makes the linked NPC stop sitting or sleeping.
To make them sit, see Sit. To make them sleep, see Sleep. |
Related Tags | None
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/StandCommand.java#L23 |
Name | Strike |
Syntax | strike [<location>] (no_damage) (silent) |
Short Description | Strikes lightning down upon the location. |
Full Description | Causes lightning to strike at the specified location, which can optionally have damage disabled.
The lightning will still cause fires to start, even without the 'no_damage' argument. Lightning caused by this command will cause creepers to activate. Using the no_damage argument makes the lightning do no damage to the player or any other entities, and means creepers struck will not activate. Use 'silent' to remove the sound of the lightning strike. NOTE: The 'silent' option appears to have been removed in a Minecraft update and thus lightning will be audible until/unless Mojang re-adds it. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | lightning, electrocute |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/StrikeCommand.java#L20 |
Name | Take |
Syntax | take [iteminhand/cursoritem/bydisplay:<name>/bycover:<title>|<author>/slot:<slot>/flagged:<flag>/item:<matcher>] (quantity:<#>) (from:<inventory>) |
Short Description | Takes an item from the player. |
Full Description | Takes items from a player or inventory.
If the player or inventory does not have the item being taken, nothing happens. Using 'slot:' will take the items from that specific slot. Using 'flagged:' with a flag name will take items with the specified flag name, see flag system. Using 'iteminhand' will take from the player's held item slot. Using 'cursoritem' will take from the player's held cursor item (as in, one that's actively being picked up and moved in an inventory screen). Using 'bydisplay:' will take items with the specified display name. Using 'bycover:' will take a written book by the specified book title + author pair. Using 'raw_exact:' (Intentionally undocumented) will compare all raw details of an item exactly. This is almost always a bad idea to use. DO NOT USE. Using 'item:' will take items that match an advanced item matcher, using the system behind Advanced Object Matching. Flagged, Slot, ByDisplay, and Raw_Exact, all take a list as input to take multiple different item types at once. If no quantity is specified, exactly 1 item will be taken. Specifying a raw item without any matching method is considered unreliable and should be avoided. Optionally using 'from:' to specify a specific inventory to take from. If not specified, the linked player's inventory will be used. The options 'iteminhand' and 'cursoritem' require a linked player and will ignore the 'from:' inventory. To take xp from a player, use experience. To take money from a player, use money. |
Related Tags | <PlayerTag.item_in_hand> Returns the item the entity is holding, or air if none.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | item |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/TakeCommand.java#L41 |
Name | Team |
Syntax | team (id:<scoreboard>/{main}) [name:<team>] (add:<entry>|...) (remove:<entry>|...) (prefix:<prefix>) (suffix:<suffix>) (option:<type> status:<status>) (color:<color>) |
Short Description | Controls scoreboard teams. |
Full Description | The Team command allows you to control a scoreboard team.
Use the "prefix" or "suffix" arguments to modify a team's playername prefix and suffix. The "entry" value can be a player's name to affect that player, or an entity's UUID to affect that entity. You can alternately input a raw PlayerTag or EntityTag, and they will be automatically translated to the name/UUID internally. Use the "color" argument to set the team color (for glowing, names, etc). Must be from https://hub.spigotmc.org/javadocs/spigot/org/bukkit/ChatColor.html. Use the "add" and "remove" arguments to add or remove players by name to/from the team. Use the "option" and "status" arguments together to set a team option's status. Option can be "COLLISION_RULE", "DEATH_MESSAGE_VISIBILITY", or "NAME_TAG_VISIBILITY", with status "ALWAYS", "FOR_OTHER_TEAMS", "FOR_OWN_TEAM", or "NEVER". Option can instead be "FRIENDLY_FIRE" or "SEE_INVISIBLE", only allowing status "ALWAYS" or "NEVER". |
Related Tags | <server.scoreboard[(<board>)].team[<team>].members> Returns a list of all members of a scoreboard team. Generally returns as a list of names or text entries. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/TeamCommand.java#L32 |
Name | Teleport |
Syntax | teleport (<entity>|...) [<location>] (cause:<cause>) (entity_options:<option>|...) (relative) (relative_axes:<axis>|...) (offthread_repeat:<#>) (offthread_yaw) (offthread_pitch) |
Short Description | Teleports the entity(s) to a new location. |
Full Description | Teleports the entity or entities to the new location.
Entities can be teleported between worlds using this command. You may optionally specify a teleport cause for player entities, allowing proper teleport event handling. When not specified, this is "PLUGIN". See teleport cause for causes. Instead of a valid entity, an unspawned NPC or an offline player may also be used. Optionally specify "relative" to use relative teleportation (Paper only). This is primarily useful only for players, but available for all entities. Relative teleports are smoother for the client when teleporting over short distances. Optionally, you may use "relative_axes:" to specify a set of axes to move relative on (and other axes will be treated as absolute), as any of "X", "Y", "Z", "YAW", "PITCH". Optionally, you may use "offthread_repeat:" with the relative arg when teleporting a player to smooth out the teleport with a specified number of extra async packets sent within a single tick. Optionally, specify "offthread_yaw" or "offthread_pitch" while using offthread_repeat to smooth the player's yaw/pitch to the new location's yaw/pitch. Optionally, specify additional teleport options using the 'entity_options:' arguments (Paper only). This allows things like retaining an open inventory when teleporting - see the links below for more information. See https://jd.papermc.io/paper/1.19/io/papermc/paper/entity/TeleportFlag.EntityState.html for all possible options. Note that the API this is based on is marked as experimental in Paper, and so may change in the future. |
Related Tags | <EntityTag.location> Returns the location of the entity. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | tp |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/TeleportCommand.java#L39 |
Name | tick |
Syntax | tick [rate/step/sprint/freeze/reset] (amount:<#.#>/cancel) |
Short Description | Controls the server's tick rate. |
Full Description | Controls the server's tick rate. MC versions 1.20+ only.
The tick rate affects things such as entity movement (including player movement), entity animations, plant growth, etc. Be careful when setting the tick rate, as a high tick rate can overload the server. If tick rate is high, crops will grow faster, animations will speed up, and so forth. Conversely, if the tick rate is low, crops will grow slower, animations will slow down, and entity movement (including player movement) will slow down and appear to be in slow motion. For a list of all the things that the tick rate affects, see https://minecraft.wiki/w/Tick To change the tick rate, use the 'rate' argument and input the amount using 'amount'. The tick rate must be a number between 1.0 and 10000.0 (inclusive). To reset the tick rate to the normal value (20.0), use the 'reset' argument. To freeze the tick rate, use the 'freeze' argument. To unfreeze, add the 'cancel' argument. Freezing the tick rate will cause all entities (except for players and entities that a player is riding) to stop ticking. This means that entity movement and animations will stop, as well as stop things like crop growth, daylight cycle, etc. To step the tick rate while the server is frozen for a specific amount of time, use the 'step' argument and input the amount of ticks using 'amount'. Tick rate stepping is allowing the tick rate to resume for a specific amount of ticks while the server is frozen. After the amount of specified ticks have passed, the tick rate will refreeze. Step input should not be a number less than one. If the server is not frozen when trying to use the 'step' argument, nothing will happen. To make the tick rate as fast as possible for a specific amount of time, use the 'sprint' argument and input the amount of ticks using 'amount'. The tick rate will increase as much as possible without overloading the server for the amount of specified ticks. Sprint input should be not be a number less than one. For example, if you want to sprint 200 ticks, the tick rate will run 200 ticks as fast as possible and then return to the previous tick rate. To stop stepping or sprinting early, use the 'cancel' argument. The tick rate resets to 20.0 on server restart. For information about tick rate arguments, see https://minecraft.wiki/w/Commands/tick |
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Warning(s) | Be careful, this command will affect plugins that depend on tick rate and may cause them to break. For example, setting the tick rate to 1 will cause the tick event to fire once per second. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/TickCommand.java#L11 |
Name | Trait |
Syntax | trait (state:true/false/{toggle}) [<trait>] (to:<npc>|...) |
Short Description | Adds or removes a trait from an NPC. |
Full Description | This command adds or removes a trait from an NPC.
Use "state:true" to add or "state:false" to remove. If neither is specified, the default is "toggle", which means remove if already present or add if not. Note that a redundant instruction, like adding a trait that the NPC already has, will give an error message. The trait input is simply the name of the trait, like "sentinel". Optionally, specify a list of NPCs to apply the trait to. If unspecified, the linked NPC will be used. |
Related Tags | <NPCTag.has_trait[<trait>]> Returns whether the NPC has a specified trait.
<NPCTag.traits> Returns a list of all of the NPC's traits.
<server.traits> Returns a list of all available NPC traits on the server.
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/TraitCommand.java#L29 |
Name | Trigger |
Related Guide Page | https://guide.denizenscript.com/guides/npcs/interact-scripts.html |
Syntax | trigger [name:<trigger>] (state:{toggle}/true/false) (cooldown:<duration>) (radius:<#>) |
Short Description | Enables or disables a trigger. |
Full Description | This command enables or disables an interact script trigger for the linked NPC.
This is generally meant to be used within the 'on assignment' action in an assignment script. This might also be useful on timed activations or other special events (such as an NPC that "goes to bed" at the end of the day, you might disable the proximity trigger that would otherwise normally show a greeting message). The "name" argument is required, and can have any supported trigger name. The 4 triggers available by default are chat, click, damage, and proximity. For more details of the available trigger types, refer to Interact Script Triggers. The "state" argument can be 'true' (to enable it), 'false' (to disable it), or unspecified to toggle it (that is, enable if it's currently off, or disable if it's currently on). You can specify the "cooldown" argument to set how long the trigger must wait after any firing before it can be fired again. You can specify the "radius" argument to set how far away a player can be when activating it. Note that the way this applies varies from trigger to trigger. For the "chat" trigger, a large radius can be easily accidentally triggered by unrelated chatter. For the "proximity" trigger, the radius argument should almost always be specified, as you generally want to control this with care. For the "click" and "damage" trigger, the radius argument will be ignored. |
Related Tags | <NPCTag.has_trigger[<trigger>]> Returns whether the NPC has a specified trigger.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/TriggerCommand.java#L24 |
Name | WaitUntil |
Syntax | waituntil (rate:<duration>) (max:<duration>) [<comparisons>] |
Short Description | Delays a script until the If comparisons return true. |
Full Description | Delays a script until the If comparisons return true. Refer to if for if command syntax information.
Optionally, specify an update rate (if unset, will update at queue speed). The update rate controls how often the tag will be checked. This generally doesn't need to be set, unless you're concerned about script efficiency. Never set this to faster than queue update rate. Optionally specify a maximum duration to wait for (delta time). |
Related Tags | <QueueTag.speed> Returns the speed of the queue as a Duration. A return of '0' implies it is 'instant'. (...)
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/WaitUntilCommand.java#L29 |
Name | Walk |
Syntax | walk (<entity>|...) [<location>/stop] (speed:<#.#>) (auto_range) (radius:<#.#>) (lookat:<location>) |
Short Description | Causes an entity or list of entities to walk to another location. |
Full Description | Causes an entity or list of entities to walk to another location.
Specify a destination location to walk to, or 'stop' to stop all walking. Optionally, specify a "speed:<#.#>" argument to control the speed of the NPCs. Optionally, specify "auto_range" to automatically set the path range for the walk instruction (if not specified, an NPC will not be able to walk to a location outside of its existing path range, by default 25 blocks). (Does not apply to non-NPC entities). Note that in most cases, the walk command should not be used for paths longer than 100 blocks. For ideal performance, keep it below 25. Optionally, specify a list of entities to give them all the same walk instruction at the same time. If the list is of NPCs, optionally specify a "radius:<#.#>" argument to change the flocking radius. ('Radius' does not apply to non-NPC entities). Optionally, specify "lookat:<location>" to cause the NPCs to stare at a specific location while walking (as opposed to straight ahead). ('Radius' does not apply to non-NPC entities). The walk command is ~waitable. Refer to ~waitable. |
Related Tags | <NPCTag.is_navigating> Returns whether the NPC is currently navigating.
<NPCTag.speed> Returns the current speed of the NPC.
<NPCTag.range> Returns the NPC's current maximum pathfinding range.
<NPCTag.target_location> Returns the location the NPC is currently navigating towards (if any).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/WalkCommand.java#L35 |
Name | Webget |
Syntax | webget [<url>] (data:<data>) (method:<method>) (headers:<map>) (timeout:<duration>/{10s}) (savefile:<path>) (hide_failure) |
Short Description | Gets the contents of a web page or API response. |
Full Description | Connects to a webpage or API and downloads its contents, to be used via the save argument and corresponding entry tags.
This should almost always be ~waited for. Refer to ~waitable. Note that while this will replace URL spaces to %20, you are responsible for any other necessary URL encoding. You may want to use the ElementTag.url_encode tag for this. Optionally, use "data:<data>" to specify a set of data to send to the server (changes the default method from GET to POST). A BinaryTag input will be used directly - any other input will be treated as a String and encoded as UTF-8. Optionally, use "method:<method>" to specify the HTTP method to use in your request. Can be: GET, POST, HEAD, OPTIONS, PUT, DELETE, TRACE, PATCH. Optionally, use "headers:" to specify a MapTag of headers. Optionally, use "savefile:" to specify a path to save the retrieved file to. This will remove the 'result' entry savedata. Path is relative to server base directory. Optionally, specify the "timeout:" to set how long the command should wait for a webpage to load before giving up. Defaults to 10 seconds. Optionally, specify 'hide_failure' to indicate that connection errors are acceptable and shouldn't display in logs. This command accepts secret inputs via SecretTag as the URL or as the value of any header. Note that you cannot mix secret with non-secret - meaning, "webget <secret[my_secret]>" and "webget https://example.com" are both valid, but "webget https://example.com/<secret[my_secret]>" is not. Similarly, for headers, each individual header value can either be a secret or not a secret. |
Related Tags | <entry[saveName].failed> returns whether the webget failed. A failure occurs when the status is not 2XX/3XX or webget failed to connect.
<entry[saveName].result> returns the text of the result of the webget. This is null only if webget failed to connect to the url.
<entry[saveName].result_binary> returns the raw binary data of the result of the webget. This is null only if webget failed to connect to the url.
<entry[saveName].result_headers> returns a MapTag of the headers returned from the webserver. Every value in the result is a list.
<entry[saveName].status> returns the HTTP status code of the webget. This is null only if webget failed to connect to the url.
<entry[saveName].time_ran> returns a DurationTag indicating how long the web connection processing took.
<ElementTag.url_encode> Encodes the element using URL encoding.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | wget |
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/WebGetCommand.java#L39 |
Name | WebServer |
Syntax | webserver [start/stop] (port:<#>) (ignore_errors) |
Short Description | Creates a local HTTP web-server within your minecraft server. |
Full Description | Creates a local HTTP web-server within your minecraft server.
The server does not provide SSL (HTTPS) security or functionality. The server does not provide active abuse-prevention or routing control or etc. If your webserver is meant for public connection, it is very strongly recommended you put the webserver behind a reverse-proxy server, such as Nginx or Apache2. The port, if unspecified, defaults to 8080. You should usually manually specify a port. The "ignore_errors" option can be enabled to silence basic connection errors that might otherwise spam your console logs. You can only exactly one webserver per port. If you use multiple ports, you can thus have multiple webservers. When using the stop instruction, you must specify the same port you used when starting. The webserver only does anything if you properly handle webserver web request Most webserver processing is done in the event, and thus is synchronous with the minecraft thread, and thus may induce lag if not done with care. Note per the event's meta, "file:" is handled async, and "cached_file:" only runs sync once per file. This command must be enabled in the Denizen/config.yml before it can be used. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/WebServerCommand.java#L29 |
Name | worldedit |
Syntax | worldedit [create_schematic/copy_to_clipboard/paste] (file:<file path>) (cuboid:<cuboid>) (position:<location>) (rotate:<#>) (undoable) (noair) |
Short Description | Controls schematics and clipboards in WorldEdit. |
Full Description | Controls schematics and clipboards in WorldEdit. You should almost always use schematic instead of this.
The action can be create_schematic, copy_to_clipboard, or paste. For 'paste': Specify 'noair' to exclude air blocks. Specify 'rotate' to rotate the schematic when pasting it. Specify 'undoable' to attach the paste to the player's WorldEdit history which allows them to undo/redo. For 'copy_to_clipboard': Specify either a cuboid or a file. The file path starts in the folder: /plugins/Denizen/schematics/ For 'create_schematic': Either specify a cuboid, or the player's clipboard will be used. Specify a file to save to. |
Related Tags | <PlayerTag.we_selection> Returns the player's current block area selection, as a CuboidTag, EllipsoidTag, or PolygonTag.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, WorldEdit |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/worldedit/WorldEditCommand.java#L44 |
Name | Yaml |
Syntax | yaml [create]/[load:<file>]/[loadtext:<text> raw_format]/[unload]/[savefile:<file>]/[copykey:<source_key> <target_key> (to_id:<name>)]/[set <key>([<#>])(:<action>):<value> (data_type:{string}/integer/double/boolean/auto)] [id:<name>] |
Short Description | Edits YAML data, especially for YAML files. |
Full Description | Edits YAML configuration data.
This commands exists primarily for interoperability with pre-existing data files and other plugins. It should never be used for storing data that only Denizen needs to use. Consider instead using flag. Use waitable syntax ("- ~yaml load:...") with load or savefile actions to avoid locking up the server during file IO. Refer to ~waitable. For loading and saving, the starting path is within 'plugins/Denizen'. The file path follows standard system file path rules. That means '/' separators folders, and '..' as a folder name means go-up-one folder, for example '../WorldGuard/config.yml' would load the WorldGuard plugin config. Also be aware that some servers (Linux/Mac based) have case sensitive file systems while others (Windows based) don't. Generally, when using existing paths, make sure your casing is correct. When creating new paths, prefer all-lowercase to reduce risk of issues. Please note that all usages of the YAML command except for "load" and "savefile" arguments are purely in memory. That means, if you use "set" to make changes, those changes will not be saved to any file, until you use "savefile". Similarly, "create" does not create any file, instead it only creates a YAML object in RAM. When loading, optionally specify 'raw_format' to indicate that this YAML file needs to maintain compatibility with some external system using raw YAML data (for example, when altering YAML data files used by external plugins). Note that this can have side effects of custom data disappearing (for example, the value "yes" gets magically converted to "true") or strange data parsing in. In-memory changes to a loaded YAML object will mark that object as having changes. Before saving, you can check whether the YAML object needs to be written to disk with the has_changes tag. Note that the '.yml' extension is not automatically appended, and you will have to include that in filenames. All usages of the YAML command must include the "id:" argument. This is any arbitrary name, as plaintext or from a tag, to uniquely and globally identify the YAML object in memory. This ID can only be used by one YAML object at a time. IDs are stored when "create" or "load" arguments are used, and only removed when "unload" is used. If, for example, you have a unique YAML data container per-player, you might use something like "id:myscript_<player>". For ways to use the "set" argument, refer to data actions. When setting a value directly, you can optionally specify "data_type" as "string", "integer", "double", "boolean", or "auto", to force the input to a specific data type, which may be needed for compatibility with some external YAML files. Only applicable when setting a single value, not lists/maps/etc. 'Auto' will attempt to choose the best type for the value. |
Related Tags | <yaml[<idname>].contains[<path>]> Returns true if the file has the specified path. (...)
<yaml[<idname>].read[<path>]> Returns the value from a data key on the YAML document as an ElementTag, ListTag, or MapTag.
<yaml[<idname>].list_keys[<path>]> Returns a ListTag of all the keys at the path (and not sub-keys). (...)
<yaml[<idname>].has_changes> Returns whether this YAML object has had changes since the last save or load.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | file |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L44 |
Name | Zap |
Related Guide Page | https://guide.denizenscript.com/guides/npcs/interact-scripts.html |
Syntax | zap (<script>) [<step>] (<duration>) |
Short Description | Changes the current interact script step. |
Full Description | Changes the current interact script step for the linked player.
The step name input should match the name of a step in the interact script. The step name can be '*' to automatically zap to the default step. If used inside an interact script, will default to the current interact script. If used elsewhere, but there is a linked NPC with an assignment and interact, that NPC's interact script will be used. For anywhere else, you must specify the script by name. Optionally specify a duration. When the duration is up, the script will zap back to the step it was previously on. If any zap commands are used during the duration, that duration will be discarded. The command's name was inspired by a command in the language "ZZT-OOP", from a 1991 DOS game enjoyed by the original developer of Denizen. |
Related Tags | <ScriptTag.step[<player>]> Returns the name of a script step that the player is currently on. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | step |
Group | core |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/core/ZapCommand.java#L31 |
Name | entity knocks back entity |
Event Lines | <entity> knocks back <entity> |
Triggers | when an entity is knocked back from the hit of another entity. |
Generated Examples | after npc knocks back npc:
after hanging knocks back vehicle: |
Has Player | when the damager or damaged entity is a player. Cannot be both. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Has NPC | when the damager or damaged entity is an NPC. Cannot be both. |
Switches | with:<item> to only process the event when the item used to cause damage (in the damager's hand) is a specified item. |
Contexts | <context.entity> returns the EntityTag that was knocked back.
<context.damager> returns the EntityTag of the one who knocked.
<context.acceleration> returns the knockback applied as a vector.
<context.cause> returns the cause of the knockback (only on MC 1.20+). Causes list: https://jd.papermc.io/paper/1.21.1/io/papermc/paper/event/entity/EntityKnockbackEvent.Cause.html
|
Determine | LocationTag as a vector to change the acceleration applied. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Paper |
Requires | Paper |
Warning(s) | this event may in some cases double-fire, requiring usage of the 'ratelimit' command (like 'ratelimit <player> 1t') to prevent doubling actions. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/EntityKnocksbackEntityScriptEvent.java#L17 |
Name | gamerule changes in world |
Event Lines | gamerule changes (in <world>) |
Triggers | when a gamerule changes. |
Generated Examples | after gamerule changes:
after gamerule changes in world_nether: |
Has Player | when the sender of the command is a player. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Switches | gamerule:<gamerule> to only process the event if the gamerule matches a specific gamerule. |
Contexts | <context.gamerule> returns the name of the GameRule which was changed. Refer to https://jd.papermc.io/paper/1.19/org/bukkit/GameRule.html.
<context.value> returns the new value of the GameRule.
<context.world> returns the world where the GameRule is applied.
<context.source_type> returns type of source. Can be: PLAYER, COMMAND_BLOCK, COMMAND_MINECART, SERVER.
<context.command_block_location> returns the command block's location (if the command was run from one).
<context.command_minecart> returns the EntityTag of the command minecart (if the command was run from one).
|
Determine | "VALUE:<ElementTag(Number)>" or ElementTag(Boolean) to set the value of the GameRule. |
Group | Paper |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/WorldGameRuleChangeScriptEvent.java#L25 |
Name | mcmmo player skill level changes |
Event Lines | mcmmo player <skill> level changes |
Triggers | when a player's mcmmo skill level changes. |
Generated Examples | after mcmmo player skill level changes:
on mcmmo player skill level changes: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.skill> returns the name of the skill that changed level. (Based on the mcMMO language file).
<context.level> returns the level the skill changed to.
<context.cause> returns the cause of the level change.
Will be one of: 'PVP', 'PVE', 'VAMPIRISM', 'SHARED_PVP', 'SHARED_PVE', 'COMMAND', 'UNKNOWN'.
|
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Depenizen |
Requires | Depenizen, mcMMO |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/events/mcmmo/mcMMOPlayerLevelChangeScriptEvent.java#L17 |
Name | mcmmo player gains xp for skill |
Event Lines | mcmmo player gains xp for <skill> |
Triggers | when a player gains mcMMO xp. |
Generated Examples | on mcmmo player gains xp for skill:
after mcmmo player gains xp for skill: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.skill> returns the name of the skill that the player gained xp for.
(Based on the mcMMO language file).
<context.xp> returns the amount of xp gained.
<context.cause> returns the cause of the xp gain.
Will be one of: 'PVP', 'PVE', 'VAMPIRISM', 'SHARED_PVP', 'SHARED_PVE', 'COMMAND', 'UNKNOWN'.
|
Determine | ElementTag(Decimal) to set the XP gained. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Depenizen |
Requires | Depenizen, mcMMO |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/events/mcmmo/mcMMOPlayerGainsXPScriptEvent.java#L17 |
Name | mcmmo player levels down skill |
Event Lines | mcmmo player levels down <skill> |
Triggers | when a player loses levels for an mcMMO skill. |
Generated Examples | after mcmmo player levels down skill: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.skill> returns the name of the skill that lost levels. (Based on the mcMMO language file).
<context.levels_lost> returns the number of levels lost.
<context.old_level> returns the old level of the skill.
<context.new_level> returns the new level of the skill.
<context.cause> returns the cause of the level loss.
Will be one of: 'PVP', 'PVE', 'VAMPIRISM', 'SHARED_PVP', 'SHARED_PVE', 'COMMAND', 'UNKNOWN'.
|
Determine | ElementTag(Number) to set the number of levels to gain. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Depenizen |
Requires | Depenizen, mcMMO |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/events/mcmmo/mcMMOPlayerLevelDownScriptEvent.java#L17 |
Name | mcmmo player levels up skill |
Event Lines | mcmmo player levels up <skill> |
Triggers | when a player levels up an mcMMO skill. |
Generated Examples | after mcmmo player levels up skill:
on mcmmo player levels up skill: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.skill> returns the name of the skill that levelled up. (Based on the mcMMO language file).
<context.levels_gained> returns the number of levels gained.
<context.old_level> returns the old level of the skill.
<context.new_level> returns the new level of the skill.
<context.cause> returns the cause of the level gain.
Will be one of: 'PVP', 'PVE', 'VAMPIRISM', 'SHARED_PVP', 'SHARED_PVE', 'COMMAND', 'UNKNOWN'.
|
Determine | ElementTag(Number) to set the number of levels to gain. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Depenizen |
Requires | Depenizen, mcMMO |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/events/mcmmo/mcMMOPlayerLevelUpScriptEvent.java#L17 |
Name | noteblock plays note |
Event Lines | noteblock plays note |
Triggers | when a NoteBlock plays a note. |
Generated Examples | after noteblock plays note: |
Switches | instrument:<instrument> to only process the event if a specific instrument was played. |
Contexts | <context.location> returns the LocationTag of the note block.
<context.instrument> returns the name of the instrument played, see list at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Instrument.html.
<context.sound> returns the name of the sound (that fits into playsound) represented by the instrument.
<context.tone> returns the note tone played (A to G).
<context.octave> returns the octave the note is played at (as a number).
<context.sharp> returns a boolean indicating whether the note is sharp.
<context.pitch> returns the computed pitch value (that fits into playsound). Note that volume is always 3.
|
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Block |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/block/NoteBlockPlaysNoteScriptEvent.java#L17 |
Name | player right|left clicks block |
Event Lines | player (right|left) clicks <block> |
Triggers | when a player clicks on a block or in the air. |
Generated Examples | after player clicks end_gateway:
after player clicks crimson_sign: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Switches | with:<item> to only process the event if a specified item was held.
using:hand/off_hand/either_hand to only process the event if the specified hand was used to click. type:<material> to only run if the block clicked matches the material input. |
Contexts | <context.item> returns the ItemTag the player is clicking with.
<context.location> returns the LocationTag the player is clicking on.
<context.relative> returns a LocationTag of the air block in front of the clicked block.
<context.click_type> returns an ElementTag of the Spigot API click type https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/block/Action.html.
<context.hand> returns an ElementTag of the used hand.
|
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Player |
Warning(s) | this event may in some cases double-fire, requiring usage of the 'ratelimit' command (like 'ratelimit <player> 1t') to prevent doubling actions.
this sometimes fires at unexpected times, eg when dropping an item. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/player/PlayerClicksBlockScriptEvent.java#L22 |
Name | player right|left clicks fake entity |
Event Lines | player (right|left) clicks fake entity |
Triggers | when a player clicks a fake entity, one that is only shown to the player and not tracked by the server. |
Generated Examples | after player clicks fake entity: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Contexts | <context.entity> returns the EntityTag of the entity that was clicked. Note that this entity is not being tracked by the server, so many operations may not be possible on it.
This will return null if the player clicks a fake entity that was not spawned via fakespawn.
<context.hand> returns an ElementTag of the hand used to click.
<context.click_type> returns an ElementTag of the click type (left/right).
|
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Paper |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/PlayerClicksFakeEntityScriptEvent.java#L16 |
Name | player right clicks entity |
Event Lines | player right clicks <entity> |
Triggers | when a player right clicks on an entity. |
Generated Examples | after player right clicks entity:
after player right clicks projectile: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Switches | with:<item> to only process the event when the player is holding a specified item.
type:<entity> to only run if the entity clicked matches the entity input. |
Contexts | <context.entity> returns the EntityTag the player is clicking on.
<context.item> returns the ItemTag the player is clicking with.
<context.hand> returns "offhand" or "mainhand" to indicate which hand was used to fire the event. Some events fire twice - once for each hand.
<context.click_position> returns a LocationTag of the click position (as a world-less vector, relative to the entity's center). This is only available when clicking armor stands.
|
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Player |
Warning(s) | this event may in some cases double-fire, requiring usage of the 'ratelimit' command (like 'ratelimit <player> 1t') to prevent doubling actions. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/player/PlayerRightClicksEntityScriptEvent.java#L21 |
Name | player trades with merchant |
Event Lines | player trades with merchant |
Triggers | when a player trades with a merchant (villager). |
Generated Examples | after player trades with merchant:
on player trades with merchant: |
Has Player | Always. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Switches | result:<result> to only process the event if the player received a specific result item. |
Contexts | <context.merchant> returns the villager that was traded with, if any (may be null for example with 'opentrades' command usage).
<context.trade> returns a TradeTag of the trade that was done.
|
Determine | TradeTag to change the trade that should be processed. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Paper |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/events/PlayerTradesWithMerchantScriptEvent.java#L17 |
Name | sponge absorbs water |
Event Lines | sponge absorbs water |
Triggers | when a sponge block absorbs water. |
Generated Examples | after sponge absorbs water:
on sponge absorbs water: |
Contexts | <context.location> returns the location of the sponge.
<context.blocks> returns a ListTag(LocationTag) of blocks (of water) that are being removed.
|
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Has Location | True - This adds the switches 'in:<area>', 'location_flagged:<flag>', ... |
Group | Block |
Warning(s) | this event may in some cases double-fire, requiring usage of the 'ratelimit' command (like 'ratelimit <context.location> 1t') to prevent doubling actions. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/block/SpongeAbsorbsScriptEvent.java#L13 |
Name | tab complete |
Event Lines | tab complete |
Triggers | when a player or the console is sent a list of available tab completions. |
Generated Examples | after tab complete: |
Has Player | when the tab completion is done by a player. - this adds switches 'flagged:<flag name>' + 'permission:<node>', in addition to the '<player>' link. |
Switches | command:<command_name> to only process the event if the command matches the input name. |
Contexts | <context.buffer> returns the full raw command buffer.
<context.command> returns the command name.
<context.current_arg> returns the current argument for completion.
<context.completions> returns a list of available tab completions.
<context.server> returns true if the tab completion was triggered from the console.
|
Determine | ListTag to set the list of available tab completions. |
Cancellable | True - This adds <context.cancelled> and determine 'cancelled' or 'cancelled:false' |
Group | Server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/server/TabCompleteScriptEvent.java#L18 |
Name | Advanced Object Matching |
Description | Script event lines often include specific 'matchable' keywords.
For example, while you can write "on player breaks block:" as a script event line, you can also instead write "on player breaks stone:" to listen to a much more specific event. This is general in-line matching. This is made available to avoid needing to do things like "- if <context.material.name> == stone" just to validate whether an event is even relevant to you. Of course, there are times when you want to more than one specific thing to be handled by the event, so what do you do? The Denizen script event system provides a few 'advanced' options to get more detailed matching. One option is to use wildcards. For example, there are several 'log' materials, such as 'oak_log', 'birch_log', and more for the rest of the tree types. So how can you match a player breaking any of these? Use "on player breaks *_log:" The asterisk is a generic wildcard, it means any text at all will match. So an asterisk followed by '_log' means any material at all that has a name ending with '_log', including 'birch_log' and the rest. Note that you can also use multiple wildcards at once, like "on player breaks block with:my_*_script_*:" That example will work for item scripts named "my_item_script_1" and "my_first_script_of_items" or any similar name. Note also that wildcards still match for blanks, so "my_item_script_" would still work for that example. You can also specify lists. For example, if you want an event to work with certain tool types, the 'on player breaks block:' event supports a switch named 'with', like 'on player breaks block with:iron_pickaxe:' So lets match multiple tools for our event... 'on player breaks block with:iron_pickaxe|gold_pickaxe|diamond_axe|wooden_shovel:' You can also combine wildcards and lists... note that lists are the 'wider' option. That is, if you have wildcards and lists together, you will have a list of possible matches, where each entry may contain wildcards, you will not have a wildcard match with a list. As a specific example, '*_pickaxe|*_axe' will match any pickaxe or any axe. '*_pickaxe|stone' will match any pickaxe or specifically stone. It will NOT match other types of stone, as it interprets the match to be a list of "*_pickaxe" and "stone", NOT "*" followed by a list of "pickaxe" or "stone". Additionally, when you're really desperate for a good matcher, you may use 'regex:' For example, "on player breaks regex:(?i)\d+_customitem:" Note that generally regex should be avoided whenever you can, as it's inherently hard to track exactly what it's doing at-a-glance, and may have unexpected edge case errors. If you want to match anything *except* a specific value, just prefix the matcher with '!' For example, on player breaks !stone:" will fire for a player breaking any block type OTHER THAN stone. This can be combined with other match modes, like "on player breaks !*wood|*planks|*log:" will fire for any block break other than any wood variant. Object types have their own special supported matchable inputs, refer to Advanced Object Matchables. These advanced matchers are also used in some commands and tags, such as ObjectTag.advanced_matches, or in if with the 'matches' operator. |
Group | Object System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/ScriptEvent.java#L900 |
Name | Chat Triggers |
Description | Chat Triggers are triggered when a player chats to the NPC (usually while standing close to the NPC and facing the NPC).
They can also be triggered by the command "/denizenclickable chat hello" (where 'hello' is replaced with the chat message). This is used for clickable triggers. This option enforces all the same limitations as chatting directly, but unlike real chat, won't display the message in global chat when there's no match. This requires players have the permission "denizen.clickable". Interact scripts are allowed to define a list of possible messages a player may type and the scripts triggered in response. Within any given step, the format is then as follows:
|
Group | NPC Interact Scripts |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/triggers/core/ChatTrigger.java#L40 |
Name | Data Actions |
Description | Several commands function as a way to modify data values,
including flag, yaml, and define. These commands each allow for a set of generic data change operations. These operations can be used with a syntax like "<key>:<action>:<value>" For example "mykey:+:5" will add 5 to the value at 'mykey'. The following actions are available: Actions that take no input value: Increment: '++': raises the value numerically up by 1. Example: - define x:++ Decrement: '--': lowers the value numerically down by 1. Example: - define x:-- Remove: '!': removes the value entirely. Example: - define x:! Actions that take an input value: Add: '+': adds the input value to the value at the key. Example: - define x:+:5 Subtract: '-': subtracts the input value from the value at the key. Example: - define x:-:5 Multiply: '*': multiplies the value at the key by the input value. Example: - define x:*:5 Divide: '/': divides the value at the key by the input value. Example: - define x:/:5 List insert: '->': adds the input value as a single new entry in the list (see also 'List split'). Example: - define x:->:new_value List remove: '<-': removes the input value from the list. Example: - define x:<-:old_value List split: '|': splits the input list and adds each value into an existing list at the key. Example: - define x:|:a|b|c Special cases: In some commands, specifying no action or input value will automatically set the key's value to 'true'. Setting a '<key>:<value>' without an action will set the key to the exact value. Be careful to not input a list like this, use 'split to new' instead. Note that the <key> input may take an index input as well, for example "mykey[3]:value". This also works with most actions. That is, for example: "mykey[3]:--" will decrement the third item in the list at 'mykey'. This syntax may also be used to remove the entry at a specified index, for example "mykey[3]:<-" The index can also be "last" to automatically use the last entry in the list as the target. |
Group | Useful Lists |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/utilities/data/DataActionType.java#L5 |
Name | Data Script Containers |
Description | Data script containers are generic script containers for information that will be referenced by other scripts.
No part of a 'data' script container is ever run as commands. There are no required keys. Generally, data is read using the ScriptTag.data_key tag.
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/containers/core/DataScriptContainer.java#L9 |
Name | Economy Script Containers |
Description | Economy script containers
Economy script containers provide a Vault economy, which can be used in scripts by PlayerTag.money and money and as well by any other plugin that relies on economy functionality (such as shop plugins). Note that vault economy bank systems are not currently supported. Per-world economies are also not currently supported. Note that in most cases, you do not want to have multiple economy providers, as only one will actually be in use. ALL SCRIPT KEYS ARE REQUIRED. Economy scripts can be automatically disabled by adding "enabled: false" as a root key (supports any load-time-parseable tags).
|
Group | Script Container System |
Requires | Vault |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/EconomyScriptContainer.java#L32 |
Name | Enchantment Script Containers |
Description | Enchantment script containers allow you to register custom item enchantments.
For the most part, they work similarly to vanilla enchantments, albeit with some limitations. These can be attached to enchanted books and used in anvils, and can be generated by the enchanting table (requires discoverable: true and treasure_only: false). In current implementation, custom enchantments do not appear in lore on their own, and will need fake lore added in their place. This might be fixed in the future. It may be beneficial in some cases to restart your server after making changes to enchantments, rather than just reloading scripts. Rarity, Category, and Slots do not apply changes to an already-loaded script until the next restart (except when the script is newly added). Using these may cause unpredictable compatibility issues with external plugins. Enchantment scripts can be automatically disabled by adding "enabled: false" as a root key (supports any load-time-parseable tags).
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/EnchantmentScriptContainer.java#L33 |
Name | Flag System |
Description | The flag system is a core feature of Denizen, that allows for persistent data storage linked to objects.
"Persistent" means the data is still around even after a server restart or anything else, and is only removed when you choose for it to be removed. "Linked to objects" means rather than purely global values, flags are associated with a player, or an NPC, or a block, or whatever else. See also the guide page at https://guide.denizenscript.com/guides/basics/flags.html. For non-persistent temporary memory, see instead define. For more generic memory options, see yaml or sql. Flags can be sub-mapped with the '.' character, meaning a flag named 'x.y.z' is actually a flag 'x' as a MapTag with key 'y' as a MapTag with key 'z' as the final flag value. In other words, "<server.flag[a.b.c]>" is equivalent to "<server.flag[a].get[b].get[c]>" Server flags can be set by specifying 'server' as the object, essentially a global flag target, that will store data in the file "plugins/Denizen/server_flags.dat" Most unique object types are flaggable - refer to any given object type's language documentation for details. Most flag sets are handled by flag, however items are primarily flagged via inventory with the 'flag' argument. Any supported object type, including the 'server' base tag, can use the tags FlaggableObject.flag, FlaggableObject.has_flag, FlaggableObject.flag_expiration, FlaggableObject.list_flags. Additionally, flags be searched for with tags like server.online_players_flagged, server.players_flagged, server.spawned_npcs_flagged, server.npcs_flagged, ... Flags can also be required by script event lines, as explained at Script Event Switches. Item flags can also be used as a requirement in take. Note that some internal flags exist, and are prefixed with '__' to avoid conflict with normal user flags. This includes: - '__raw' and '__clear' which are part of a fake-flag system used for forcibly setting raw data to a flaggable object, - '__scripts', '__time', etc. which is where some object-type flags are stored inside of server flags, - '__interact_step' which is used for interact script steps, related to zap, - '__interact_cooldown' which is used for interact script cooldowns, related to cooldown. Flags have an expiration system, which is used by specifying a time at which they should expire (or via a duration which internally calculates the date/time of expiration by adding the duration input to the current date/time). Expirations are then *checked for* in flag tags - meaning, the flag tags will internally compare a stored date/time against the real current date/time, and if the flag's expiration time is in the past, the flag tag will return values equivalent to if the flag doesn't exist. There is no system actively monitoring for flag expirations or applying them. There is no event for expirations occurring, as they don't "occur" per se. In other words, it is correct to say a flag "is expired" or a flag "is not expired", but it is incorrect to say a flag "expires", as it is not an active action (though this wording can be convenient when speaking informally). Expired flags are sometimes 'cleaned up' (meaning, any expired flags get actually removed from internal storage), usually when a flag save file is loaded into the server. As a bonus feature-combo, it is possible to transmit sets of flags exactly in-place and reapply them, this is particular useful for example to synchronize player data across Bungee servers. To do this, you can read raw flag data with the tag FlaggableObject.flag_map and the '__raw' prefix in a flag command. For example:
|
Group | Denizen Scripting Language |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/FlagCommand.java#L34 |
Name | Format Script Containers |
Description | Format script containers are very simple script containers used for formatting messages, usually with the 'narrate' command.
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/FormatScriptContainer.java#L19 |
Name | Health Trait |
Description | By default, NPCs are invulnerable, unable to be damaged. If you want your NPC
to be able to take damage, or use the left click as an interaction, it must have the health trait. The Health trait is automatically enabled if you set the damage trigger state to true. You can use the denizen vulnerable command to make your NPCs react to left click, but not take damage. - vulnerable state:false Enable Damage trigger via dScript: - trigger name:damage state:true Enable Health trait via dScript: - trait state:true health Enable Health trait via npc command: /npc health --set # (-r) Enable automatic respawn (default delay 300t): /npc health --respawndelay [delay as a duration] Set respawn location: - flag <npc> respawn_location:<location> Related Tags EntityTag.health EntityTag.formatted_health EntityTag.health_max EntityTag.health_percentage NPCTag.has_trait[health] Related Mechanisms EntityTag.health EntityTag.max_health Related Commands heal health vulnerable Related Actions on damage on damaged on no damage trigger |
Group | NPC Traits |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/HealthTrait.java#L29 |
Name | Interact Script Containers |
Description | Interact script containers are used to handle NPC triggers.
Interact scripts must be referenced from an assignment script container to be of any use. See assignment script containers. The only required key on an interact script container is the 'steps:' key. Within the steps key is a list of steps, where the first step is '1', 'default', or any step that contains a '*' symbol. After that, any steps must be 'zapped' to via the zap command: zap. Each step contains a list of trigger types that it handles, and the relevant handling that the given trigger makes available. Refer to interact script triggers for documentation about the triggers available. Any triggers used must be enabled in assignment by trigger. Note that script commands ran in interact scripts by default have a delay between each command. To override this delay, set 'speed: 0' on the container or change the relevant config setting. Interact scripts can be automatically disabled by adding "enabled: false" as a root key (supports any load-time-parseable tags).
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/InteractScriptContainer.java#L19 |
Name | Interact Script Triggers |
Description | Interact script triggers are the most basic components of standard NPC scripting.
They're very useful for NPCs that give quests or have other very basic interactions with players. While less powerful that other tools that Denizen provides, they can be very straightforward and clear to use in many simpler cases. Note that triggers have a default cooldown system built in to prevent users from clicking too rapidly. However these are very short cooldowns by default - when you need a longer cooldown, use cooldown or engage. Triggers go in interact script containers. The available default trigger types are click triggers, damage triggers, chat triggers, and proximity triggers. |
Group | NPC Interact Scripts |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/InteractScriptContainer.java#L67 |
Name | Invisible Trait |
Description | The invisible trait will allow a NPC to remain invisible, even after a server restart.
It permanently applies the invisible potion effect. Use '/npc invisible' or the 'invisible' script command to toggle this trait. Note that player-type NPCs must have '/npc playerlist' toggled to be turned invisible. Once invisible, the player-type NPCs can be taken off the playerlist. This only applies specifically to player-type NPCs. Playerlist will be enabled automatically if not set in advance, but not automatically removed. |
Group | NPC Traits |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/InvisibleTrait.java#L19 |
Name | Map Script Containers |
Description | Map scripts allow you define custom in-game map items, for usage with the map command.
The following is the format for the container.
A list of cursor types is available through server.map_cursor_types. |
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/containers/core/MapScriptContainer.java#L23 |
Name | MythicMobs Bridge |
Description | In addition to the tags, commands, and events found by searching for "mythicmobs" throughout the meta documentation,
Depenizen adds 4 new Denizen matchers, and additional features to Mythic Mobs: 2 Targeters, and a Condition. Depenizen provides additional EntityTag and ItemTag matchers to match MythicMobs mobs/items: - "mythic_mob" plaintext EntityTag matcher, matches if the entity is a mythic mob. - "mythic_mob:<MythicMobID>" EntityTag matcher, matches if the entity is a mythic mob, and its ID matches the advanced matcher specified. - "mythic_item" plaintext ItemTag matcher, matches if the item is a mythic item. - "mythic_item:<MythicItemID>" ItemTag matcher, matches if the item is a mythic item, and its ID matches the advanced matcher specified. Depenizen provides two additional targeters via the MythicMobs API: @DenizenEntity is an entity-based targeter, @DenizenLocation is a location-based targeter. Both targeters can parse tags; they accept input of either an EntityTag or LocationTag respectively. Both targeters also support returning ListTags containing their respective tag types. Both targeters provide <context.entity> as an EntityTag of the caster. Conditions provide different contexts depending on their usage. The syntax for calling a Denizen tag as a condition is DenizenCondition. The tag should return an ElementTag of a boolean value (true or false). <context.location> is available for location-based checks, <context.entity> is available for entity-based and caster-based checks, and <context.target> is available for target-based checks. NOTE: TriggerConditions are NOT currently supported. Note as well that many parts of MythicMobs configurations allow usage of PlaceholderAPI, which means you can use the "denizen_" placeholder to read tags in any such parts, refer to PlaceholderAPI Bridge for more information. Usage Examples Example 1: @DenizenEntity{tag=<context.entity.location.find_players_within[30].filter[has_flag[marked]]>} Example 2: @DenizenLocation{tag=<context.entity.location.find.surface_blocks.within[30].random[5]>} Example 3: @DenizenEntity{tag=<proc[SomeProcScript]>} Conditions: - denizencondition{tag=<context.entity.location.find_players_within[30].is_empty.not>} |
Group | Depenizen Bridges |
Requires | Depenizen, MythicMobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/utilities/mythicmobs/MythicMobsLoaders.java#L20 |
Name | ObjectTags |
Description | ObjectTags are a system put into place by Denizen that make working with things, or 'objects',
in Minecraft and Denizen easier. Many parts of scripts will require some kind of object as an argument, identifier/type, or such as in world events, part of an event name. The ObjectTags notation system helps both you and Denizen know what type of objects are being referenced and worked with. So when should you use ObjectTags? In arguments, event names, replaceable tags, configs, flags, and more! If you're just a beginner, you've probably been using them without even realizing it! ObjectTag is a broader term for a 'type' of object that more specifically represents something, such as a LocationTag or ScriptTag, often times just referred to as a 'location' or 'script'. Denizen employs many object types that you should be familiar with. You'll notice that many times objects are referenced with their 'ObjectTag notation' which is in the format of 'x@', the x being the specific notation of an object type. Example: player objects use the p@ notation, and locations use l@. This notation is automatically generated when directly displaying objects, or saving them into data files. It should never be manually typed into a script. Let's take the tag system, for example. It uses the ObjectTags system pretty heavily. For instance, every time you use <player.name> or <npc.id>, you're using a ObjectTag, which brings us to a simple clarification: Why <player.name> and not <PlayerTag.name>? That's because Denizen allows Players, NPCs and other 'in-context objects' to be linked to certain scripts. In short, <player> already contains a reference to a specific player, such as the player that died in a world event 'on player dies'. <PlayerTag.name> is instead the format for documentation, with "PlayerTag" simply indicating 'any player object here'. ObjectTags can be used to CREATE new instances of objects, too! Though not all types allow 'new' objects to be created, many do, such as ItemTags. With the use of tags, it's easy to reference a specific item, say -- an item in the Player's hand -- items are also able to use a constructor to make a new item, and say, drop it in the world. Take the case of the command/usage '- drop diamond_ore'. The item object used is a brand new diamond_ore, which is then dropped by the command to a location of your choice -- just specify an additional location argument. There's a great deal more to learn about ObjectTags, so be sure to check out each object type for more specific information. While all ObjectTags share some features, many contain goodies on top of that! |
Group | Object System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/CommonRegistries.java#L29 |
Name | Operator |
Description | An operator is a tool for comparing values, used by commands like if, while, waituntil, ... and tags like ObjectTag.is.than
Available Operators include: "Equals" is written as "==" or "equals". "Does not equal" is written as "!=". "Is more than" is written as ">" or "more". "Is less than" is written as "<" or "less". "Is more than or equal to" is written as ">=" or "or_more". "Is less than or equal to" is written as "<=" or "or_less". "does this list or map contain" is written as "contains". For example, "- if a|b|c contains b:" or "- if [a=1;b=2] contains b:" "is this in the list or map" is written as "in". For example, "- if b in a|b|c:", or "- if [a=1;b=2] contains b:" "does this object or text match an advanced matcher" is written as "matches". For example, "- if <player.location.below> matches stone:" Note: When using an operator in a tag, keep in mind that < and >, and even >= and <= must be either escaped, or referred to by name. Example: "<player.health.is[<<>].than[10]>" or "<player.health.is[less].than[10]>", but <player.health.is[<].than[10]> will produce undesired results. <>'s must be escaped or replaced since they are normally notation for a replaceable tag. Escaping is not necessary when the argument contains no replaceable tags. There are also special boolean operators (&&, ||, ...) documented at: if |
Group | Comparables |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/Comparable.java#L14 |
Name | Particle Effects |
Description | All the effects listed here can be used by PlayEffect to display visual effects or play sounds
Effects: - Everything on https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Particle.html - Everything on https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Effect.html - RANDOM (chooses a random visual effect from the Particle list) |
Group | Useful Lists |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/PlayEffectCommand.java#L43 |
Name | Procedure Script Containers |
Description | Procedure script containers are used to define a script that can be ran through a tag.
Generally called via proc or proc.context. The only required key is 'script:'. Note that procedure scripts must NEVER change external state. That is, a procedure script cannot change anything at all, ONLY determine a value. Setting a flag, loading a YAML document, placing a block, etc. are all examples of external changes that are NOT allowed. This restriction comes from two main reasons: - Tags run in arbitrary conditions. They may be read asynchronously or in other weird circumstances that can result in applied changes crashing your server or other unexpected side effects. - Tags can run for a variety of reasons. If you were to make a proc script 'spawn_entity' that actually spawns an entity into the world, you would likely end up with a *lot* of unintentional entity spawns. Some tags will be read multiple times when theoretically ran once, in some circumstances a tag read might even be based on user input! (Particularly if you ever make use of the '.parsed' tag, or the list.parse/filter/sort_by_number tags). Imagine if for example, a tag can be read when users input a specific custom command, and a clever user finds out they can type "/testcommand 32 <proc[spawn_entity].context[creeper]>" to spawn a creeper ... that would be a major problem! In general, maximum caution is the best for situations like this... simply *never* make a procedure that executes external changes.
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/containers/core/ProcedureScriptContainer.java#L9 |
Name | Proximity Triggers |
Description | Proximity Triggers are triggered when when a player moves in the area around the NPC.
Proximity triggers must have a sub-key identifying what type of proximity trigger to use. The three types are "entry", "exit", and "move". Entry and exit do exactly as the names imply: Entry fires when the player walks into range of the NPC, and exit fires when the player walks out of range. Move is a bit more subtle: it fires very rapidly so long as a player remains within range of the NPC. This is useful for eg script logic that needs to be constantly updating whenever a player is nearby (eg a combat NPC script needs to constantly update its aim). The radius that the proximity trigger detects at is set by trigger. |
Group | NPC Interact Scripts |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/triggers/core/ProximityTrigger.java#L23 |
Name | Pushable Trait |
Description | By default, NPCs created will allow players to 'noclip' them, or go right through. This is to
avoid NPCs moving from their set location, but often times, this behavior may be undesired. The pushable trait allows NPCs to move when collided with, and optionally return to their original location after a specified amount of time. To enable the trait, use the '/npc pushable' command on any selected NPC. Once the trait is enabled, the '-r' option can be used to toggle returnable, and the '--delay #' option can be used to specify the number of seconds before the npc returns. Care should be taken when allowing NPCs to be pushable. Allowing NPCs to be pushed around complex structures can result in stuck NPCs. If the NPC is stuck, it may not return. Keeping a small delay, in situations like this, can be a good trade-off. Typically the lower the delay, the shorter distance a Player is able to push the NPC. The default delay is 2 seconds. The pushable trait also implements some actions that can be used in assignment scripts. This includes 'on push' and 'on push return'. |
Group | NPC Traits |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/npc/traits/PushableTrait.java#L19 |
Name | Safety In Events |
Description | One of the more common issues in Denizen scripts (particularly ones relating to inventories) is
*event safety*. That is, using commands inside an event that don't get along with the event. The most common example of this is editing a player's inventory, within an inventory-related event. Generally speaking, this problem becomes relevant any time an edit is made to something involved with an event, within the firing of that event. Take the following examples:
In both examples above, something related to the event (the player's inventory, and the entity being damaged) is being modified within the event itself. These break due a rather important reason: The event is firing before and/or during the change to the object. Most events operate this way. A series of changes *to the object* are pending, and will run immediately after your script does... the problems resultant can range from your changes being lost to situational issues (eg an inventory suddenly being emptied entirely) to even server crashes! The second example event also is a good example of another way this can go wrong: Many scripts and plugins will listen to the entity damage event, in ways that are simply unable to handle the damaged entity just being gone now (when the event fires, it's *guaranteed* the entity is still present but that remove command breaks the guarantee!). The solution to this problem is simple: Use "after" instead of "on".
This will delay the script until *after* the event is complete, and thus outside of the problem area. And thus should be fine. One limitation you should note is demonstrated in the second example event: The normal guarantees of the event are no longer present (eg that the entity is still valid) and as such you should validate these expectations remain true after the event (as seen with the 'if is_spawned' check). (See also Script Event After vs On) If you need determine changes to the event, you can instead use 'on' but add a 'wait 1t' after the determine but before other script logic. This allows the risky parts to be after the event and outside the problem area, but still determine changes to the event. Be sure to use 'passively' to allow the script to run in full.
|
Group | Script Events |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/BukkitScriptEvent.java#L934 |
Name | Script Event After vs On |
Description | Modern ScriptEvents let you choose between "on" and "after".
An "on" event looks like "on player breaks block:" while an "after" event looks like "after player breaks block:". An "on" event fires *before* the event actually happens in the world. This means some relevant data won't be updated (for example, "<context.location.material>" would still show the block type that is going to be broken) and the result of the event can be changed (eg the event can be cancelled to stop it from actually going through). An "after" event, as the name implies, fires *after* the event actually happens. This means data will be already updated to the new state (so "<context.location.material>" would now show air) but could potentially contain an arbitrary new state from unrelated changes (for example "<context.location.material>" might now show a different block type, or the original one, if the event was changed, or another thing happened right after the event but before the 'after' event ran). This also means you cannot affect the outcome of the event at all (you can't cancel it or anything else - the "determine" command does nothing). See also Safety In Events |
Group | Script Events |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/events/ScriptEvent.java#L361 |
Name | Script Syntax |
Description | The syntax of Denizen is broken into multiple abstraction layers.
At the highest level, Denizen scripts are stored in script files, which use the '.dsc' suffix Denizen script syntax is approximately based on YAML configuration files, and is intended to seem generally as easy to edit as a YAML configuration. However, several key differences exist between the Denizen script syntax and YAML syntax. In particular, there are several changes made to support looser syntax rules and avoid some of the issues that would result from writing code directly into a plain YAML file. Within those 'script files' are 'script containers', which are the actual unit of separating individual 'scripts' apart. (Whereas putting containers across different files results in no actual difference: file and folder separation is purely for your own organization, and doesn't matter to the Denizen parser). Each script container has a 'type' such as 'task' or 'world' that defines how it functions. Within a script container are individual script paths, such as 'script:' in a 'task' script container, or 'on player breaks block:' which might be found within the 'events:' section of a 'world' script container. These paths are the points that might actually be executed at any given time. When a path is executed, a 'script queue' is formed to process the contents of that script path. Within any script path is a list of 'script entries', which are the commands to be executed. These can be raw commands themselves (like 'narrate') with their arguments, or commands that contain additional commands within their entry (as 'if' and 'foreach' for example both do). |
Group | Denizen Scripting Language |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ScriptTag.java#L54 |
Name | Slot Inputs |
Description | Whenever a script component requires a slot ID (such as the take command, when using '- take slot:#')
you can give the slot ID input as either a number of the 1-based index (where the first slot is 1, the second is 2, etc.) If the slot given is 'hand', for a player the held item slot will be used, for any other entity the slot will be 1. OR you can give the following names (valid for player inventories only): BOOTS: equivalent to 37 LEGGINGS: equivalent to 38 CHESTPLATE: equivalent to 39 HELMET: equivalent to 40 OFFHAND: equivalent to 41 Note that some common alternate spellings may be automatically accepted as well. |
Group | Useful Lists |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/utilities/inventory/SlotHelper.java#L72 |
Name | Structure lookups |
Description | Structures can be located using LocationTag.find_structure.
It works similarly to the '/locate' command, and has several side effects/edge cases: - The radius is in chunks, but isn't always a set square radius around the origin; certain structures may modify the amounts of chunks checked. For example, woodland mansions can potentially check up to 20,000 blocks away (or more) regardless of the radius used. - Lookups can take a long amount of time (several seconds, over 10 in some cases), especially when looking for unexplored structures, which will cause the server to freeze while searching. - They will not load/generate chunks (but can search not-yet-generated chunks and return a location in them). - They can lead to situations where the server hangs and crashes when trying to find unexplored structures (if there aren't any/any nearby), as it keeps looking further and further out. - The returned location only contains the X and Z values, and will always have a Y value of 0. Tags like LocationTag.highest are available, but note that they require the chunk to be loaded. |
Group | Useful Lists |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L4298 |
Name | Tag Fallbacks |
Description | Tag fallbacks (AKA "tag alternatives") are a system designed to allow scripters to automatically handle tag errors.
Fallbacks are implemented as special "magic tags" that look like any other tag-part, but override the error handler. These are "if_null", "exists", and "is_truthy". A tag without a fallback might look like "<player.name>". This tag works fine as long as there's a linked player, but what if a player isn't always available? Normally, this situation would display an error in the console debug logs, and return plaintext "player.name" in the script. A fallback can help us handle the problem more gracefully. That same tag with a fallback would look like "<player.name.if_null[Steve]>". Now, when there isn't a player available, there will not be an error, and the tag will simply return "Steve". This format is the same for basically all tags. "<main.tag.here.if_null[Fallback here]>". For another example, "<player.flag[myflag].if_null[0]>" returns either the value of the flag, or "0" if the flag is not present (or if there's no player). The "exists" fallback-tag is available for checking whether an object exists and is valid. What if we want to check if there even is a linked player? We don't have a "<has_player>" tag to do that, so what can we do?
The above example demonstrates using a fallback to check if a player is valid. The if block will run only if there is not a player valid (you might, for example, place the "stop" command inside). "Exists" is useful when you *only* need a check, however you often need to grab a value and verify it after. Consider the following example, often found in command scripts:
We use the word "null" in the above example, as well as in the tag name itself. This is a common programming term that means "no object is present". "if_null" is the actual tag name, however the input value of "null" isn't actually a functionality of Denizen, it's just a word we choose for clarity. You could just as easily do "- if <player.if_null[nothing]> == nothing:", or for that matter "- if <player.if_null[cheese]> == cheese:". A player object takes the form "p@uuid", so it will therefore never exactly match any simple word, so there's no coincidental match edge-case to worry about. Note that this won't work so perfect for things like a user input or fully dynamic value, so in those cases you may want to use the "exists" tag explicitly to guarantee no potential conflict. Fallbacks can be tags themselves. So, for example, if we want either a custom flag-based display name, or if not available, the player's base name, we can do: "<player.flag[display_name].if_null[<player.name>]>". You can as well chain these: "<player.flag[good_name].if_null[<player.flag[bad_name].if_null[<player.name>]>]>". Note that fallbacks will *hide errors*. Generally, the only errors you should ever hide are ones you're expecting that are fine. Don't use a fallback on a "<player.name>" tag, for example, if there should always be a player present when the script runs. That tag should only ever have a fallback when the script is meant to still work without a player attached. If you carelessly apply fallbacks to all tags, you might end up not realizing there's a problem in your script until it's affecting real players. You want to solve errors in testing, not ten months later when a player mentions to you "that shop NPC let me buy things even when I had $0"! Prior to Denizen 1.2.0, fallbacks exclusively worked with a special "||" syntax, like "- if <player||null> == null:" This syntax is still fully supported at time of writing, however the newer tag-based format is considered clearer and easier to learn. |
Group | Tag System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/Attribute.java#L471 |
Name | Task Script Containers |
Description | Task script containers are generic script containers for commands that can be run at
any time by command. Generally tasks will be ran by run or inject. The only required key on a task script container is the 'script:' key.
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/containers/core/TaskScriptContainer.java#L15 |
Name | Teleport Cause |
Description | Possible player teleport causes: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/player/PlayerTeleportEvent.TeleportCause.html
These are used in entity teleports, server.teleport_causes, teleport, ... Note that these causes will only work for player entities. Additionally, Denizen provides two basic teleport causes for non-player entity teleport events: ENTITY_PORTAL and ENTITY_TELEPORT. These additional causes are only for entity teleports, and thus not usable in teleport, and will not show in server.teleport_causes. |
Group | Useful Lists |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/events/entity/EntityTeleportScriptEvent.java#L20 |
Name | Virtual Inventories |
Description | Virtual inventories are inventories that have no attachment to anything within the world of Minecraft.
They can be used for a wide range of purposes - from looting fallen enemies to serving as interactive menus with item 'buttons'. In Denizen, all noted inventories (saved by the Note command) are automatically converted into a virtual copy of the saved inventory. This enables you to open and edit the items inside freely, with automatic saving, as if it were a normal inventory. Noting is not the only way to create virtual inventories, however. Using 'generic' along with inventory properties will allow you to create temporary custom inventories to do with as you please. The properties that can be used like this are: size=<size> contents=<item>|... title=<title> holder=<inventory type> For example, the following task script opens a virtual inventory with 18 slots, where the second slot is a snowball, all the rest are empty, and the title is "My Awesome Inventory" with some colors in it.
|
Group | Inventory System |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/item/InventoryCommand.java#L65 |
Name | World Script Containers |
Description | World script containers are generic script containers for commands that are automatically
ran when some given event happens in the server. The only required key is 'events:', within which you can list any events to handle. World scripts can be automatically disabled by adding "enabled: false" as a root key (supports any load-time-parseable tags).
|
Group | Script Container System |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/containers/core/WorldScriptContainer.java#L9 |
Name | force_loaded |
Object | ChunkTag |
Input | ElementTag(Boolean) |
Related Tags | <ChunkTag.force_loaded> Returns whether the chunk is forced to stay loaded at all times.
|
Description | Sets whether this plugin is force-loaded or not.
Unless you have a specific reason to use this, prefer chunkload. |
Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/ChunkTag.java#L839 |
Name | charged |
Object | EntityTag |
Input | ElementTag(Boolean) |
Related Tags | <EntityTag.charged> (Property) If the entity is wither_skull, controls whether the skull is charged. Charged skulls are blue. (...)
|
Description | (Property) If the entity is wither_skull, controls whether the skull is charged. Charged skulls are blue.
If the entity is a vex, controls whether the vex is charging. Charging vexes have red lines. This is a visual effect, and does not cause the vex to actually charge at anyone. If the entity is a guardian, controls whether the guardian's laser is active. Note that guardians also require a target to use their laser, see attack. |
Generated Example |
|
Group | Properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/entity/EntityCharged.java#L10 |
Name | collidable |
Object | EntityTag |
Input | ElementTag(Boolean) |
Related Tags | <EntityTag.is_collidable> Returns whether the entity is collidable. (...)
|
Description | Sets whether the entity is collidable.
For NPCs, Sets the persistent collidable value. NOTE: To disable collision between two entities, set this mechanism to false on both entities. NOTE: For players, to fully remove collision you need to use team and set "option:collision_rule status:never" |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L3771 |
Name | head_angle |
Object | EntityTag |
Input | ElementTag(Decimal) |
Description | Sets the raw head angle of a living entity.
This will not rotate the body at all. Most users should prefer look. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L4124 |
Name | is_sneaking |
Object | EntityTag |
Input | ElementTag(Boolean) |
Related Tags | <EntityTag.is_sneaking> (Property) Whether an entity is sneaking. (...)
|
Description | (Property) Whether an entity is sneaking.
For most entities this just makes the name tag less visible, and doesn't actually update the pose. Note that sneak is also available. |
Generated Example |
|
Group | Properties |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/properties/EntitySneaking.java#L12 |
Name | play_hurt_animation |
Object | EntityTag |
Input | ElementTag(Decimal) |
Description | Plays a hurt animation that makes the living entity flash red. When the entity is a player, you can change the direction the camera rotates.
Damage direction is relative to the player, where 0 is in front, 90 is to the right, 180 is behind, and 270 is to the left. For versions 1.19 or below, use animate. |
Example |
|
Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L3220 |
Name | visual_fire |
Object | EntityTag |
Input | ElementTag(Boolean) |
Related Tags | <EntityTag.visual_fire> (Property) Whether an entity has a fake fire effect. For actual fire, see burn and EntityTag.on_fire.
|
Description | (Property) Whether an entity has a fake fire effect. For actual fire, see burn and EntityTag.on_fire. |
Generated Example |
|
Group | Properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/entity/EntityVisualFire.java#L9 |
Name | flag |
Object | ItemTag |
Input | ObjectTag |
Related Tags | <FlaggableObject.flag[<flag_name>]> Returns the specified flag from the flaggable object. (...)
<FlaggableObject.has_flag[<flag_name>]> Returns true if the flaggable object has the specified flag, otherwise returns false. (...)
<FlaggableObject.flag_expiration[<flag_name>]> Returns a TimeTag indicating when the specified flag will expire. (...)
<FlaggableObject.list_flags> Returns a list of the flaggable object's flags. (...)
|
Description | Modifies a flag on this item, using syntax similar to flag.
For example, 'flag:myflagname:!' will remove flag 'myflagname', or 'flag:myflagname:3' sets flag 'myflagname' to value '3'. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/item/ItemFlags.java#L119 |
Name | mode |
Object | MaterialTag |
Input | ElementTag |
Related Tags | <MaterialTag.mode> Returns a block's mode. (...)
|
Description | Set a block's mode.
For comparators, input is COMPARE or SUBTRACT. For piston_heads, input is NORMAL or SHORT. For bubble_columns, input is NORMAL or DRAG. For structure_blocks, input is CORNER, DATA, LOAD, or SAVE. For sculk_sensors, input is ACTIVE, COOLDOWN, or INACTIVE. For daylight_detectors, input is INVERTED or NORMAL. For command_blocks, input is CONDITIONAL or NORMAL. For big_dripleafs, input is FULL, NONE, PARTIAL, or UNSTABLE. For sculk_catalysts, input is BLOOM or NORMAL. For sculk_shriekers, input is SHRIEKING or NORMAL. For tripwires, input is ARMED or DISARMED. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/material/MaterialMode.java#L218 |
Name | banner_update |
Object | PlayerTag |
Input | ElementTag |
Description | Shows the player fake patterns on a banner. Input must be in the form: "LOCATION|COLOR/PATTERN|..."
As of Minecraft 1.13, the base color is unique material types, and so showfake must be used for base color changes. For the list of possible patterns, see https://hub.spigotmc.org/javadocs/spigot/org/bukkit/block/banner/PatternType.html. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L3898 |
Name | edit_sign |
Object | PlayerTag |
Input | LocationTag |
Description | Allows the player to edit an existing sign. To create a sign, see Sign.
Give no input to make a fake edit interface. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L3823 |
Name | fake_equipment |
Object | PlayerTag |
Input | EntityTag(|ElementTag|ItemTag) |
Description | Shows the player fake equipment on the specified living entity, which has no real non-visual effects.
Input is in the form Entity|Slot|Item, where the slot can be one of the following: HAND, OFF_HAND, BOOTS, LEGS, CHEST, HEAD Optionally, exclude the slot and item to stop showing the fake equipment, if any, on the specified entity. For example: - adjust <player> fake_equipment:<[some_entity]>|chest|diamond_chestplate - adjust <player> fake_equipment:<player>|head|jack_o_lantern Consider instead using fakeequip. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L3571 |
Name | noclip |
Object | PlayerTag |
Input | ElementTag(Boolean) |
Description | When true, causes the server to allow the player to noclip (ie, walk through blocks without being prevented).
This is purely serverside. The client will still not walk through blocks. This is useful alongside showfake. Note that this may sometimes be imperfect / sometimes momentarily continue to clip block. Note that this may also prevent other collisions (eg projectile impact) but is not guaranteed to. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2800 |
Name | resource_pack |
Object | PlayerTag |
Input | ElementTag(|ElementTag) |
Description | Deprecated, use resourcepack. |
Deprecated | Use the "resourcepack" command instead of this old mechanism. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L3020 |
Name | restart |
Object | server |
Input | None |
Description | Immediately stops the server entirely (Plugins will still finalize, and the shutdown event will fire), then starts it again.
Requires config file setting "Commands.Restart.Allow server restart"! Note that if your server is not configured to restart, this mechanism will simply stop the server without starting it again! |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L1936 |
Name | shutdown |
Object | server |
Input | None |
Description | Immediately stops the server entirely (Plugins will still finalize, and the shutdown event will fire).
The server will remain shutdown until externally started again. Requires config file setting "Commands.Restart.Allow server stop"! |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L1966 |
Name | cancel_runlater |
Object | system |
Input | ElementTag |
Description | Cancels a task scheduled in runlater by its specified unique ID.
If the ID isn't in use, will silently do nothing. Use util.runlater_ids to check whether there is already a scheduled task with the given ID. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L1030 |
Name | delete_file |
Object | system |
Input | ElementTag |
Related Tags | <util.has_file[<file>]> Returns true if the specified file exists. The starting path is /plugins/Denizen.
|
Description | Deletes the given file from the server.
File path starts in the Denizen folder. Require config file setting "Commands.Delete.Allow file deletion". |
Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L1079 |
Name | destroy |
Object | WorldTag |
Input | None |
Description | Unloads the world from the server without saving chunks, then destroys all data that is part of the world.
Require config setting 'Commands.Delete.Allow file deletion'. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/WorldTag.java#L1216 |
Name | DurationTag |
Prefix | d@ |
Base Type | ElementTag |
Identity Format | The identity format for DurationTags is the number of seconds, followed by an 's'. |
Description | Durations are a unified and convenient way to get a 'unit of time' throughout Denizen.
Many commands and features that require a duration can be satisfied by specifying a number and unit of time, especially command arguments that are prefixed 'duration:', etc. The unit of time can be specified by using one of the following: t=ticks (0.05 seconds), s=seconds, m=minutes (60 seconds), h=hours (60 minutes), d=days (24 hours), w=weeks (7 days), y=years (365 days). Not using a unit will imply seconds. Examples: 10s, 50m, 1d, 20. Specifying a range of duration will result in a randomly selected duration that is in between the range specified. The smaller value should be first. Examples: '10s-25s', '1m-2m'. The input of 'instant' or 'infinite' will be interpreted as 0 (for use with commands where instant/infinite logic applies). |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/DurationTag.java#L19 |
Name | FlaggableObject |
Prefix | None |
Identity Format | N/A |
Description | "FlaggableObject" is a pseudo-ObjectType that represents any type of object that can hold flags,
for use with flag or any other flag related tags and mechanisms. Just because an ObjectType implements FlaggableObject, does not mean a specific instance of that object type is flaggable. For example, LocationTag implements FlaggableObject, but a LocationTag-Vector (a location without a world) cannot hold a flag. |
Extended By | GriefPreventionClaimTag, NationTag, TownTag, DiscordBotTag, DiscordChannelTag, DiscordCommandTag, DiscordGroupTag, DiscordInteractionTag, DiscordMessageTag, DiscordReactionTag, DiscordRoleTag, DiscordUserTag, BiomeTag, ChunkTag, CuboidTag, EllipsoidTag, EnchantmentTag, EntityTag, InventoryTag, ItemTag, LocationTag, MaterialTag, NPCTag, PlayerTag, PluginTag, PolygonTag, WorldTag, QueueTag, ScriptTag, TimeTag |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/flags/FlaggableObject.java#L7 |
Name | InventoryTag |
Prefix | in@ |
Base Type | ElementTag |
Implements | FlaggableObject, PropertyHolderObject |
Identity Format | The identity format for inventories is the classification type of inventory to use. All other data is specified through properties. |
Description | An InventoryTag represents an inventory, generically or attached to some in-the-world object.
Inventories can be generically designed using inventory script containers, and can be modified using the inventory command. Valid inventory type classifications: "npc", "player", "crafting", "enderchest", "workbench", "entity", "location", "generic" This object type can be noted. This object type is flaggable when it is noted. Flags on this object type will be stored in the notables.yml file. |
Matchable | InventoryTag matchers, sometimes identified as "<inventory>":
"inventory" plaintext: always matches. "note" plaintext: matches if the inventory is noted. Inventory script name: matches if the inventory comes from an inventory script of the given name, using advanced matchers. Inventory note name: matches if the inventory is noted with the given name, using advanced matchers. Inventory type: matches if the inventory is of a given type, using advanced matchers. "inventory_flagged:<flag>": a Flag Matchable for InventoryTag flags. "gui" plaintext: matches if the inventory is a GUI (see inventory script containers). |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/InventoryTag.java#L59 |
Name | QueueTag |
Prefix | q@ |
Base Type | ElementTag |
Implements | FlaggableObject |
Identity Format | The identity format for queues is simply the queue ID. |
Description | A QueueTag is a single currently running set of script commands.
This is not to be confused with a script path, which is a single set of script commands that can be run. There can be one, multiple, or zero queues running at any time for any given path. This object type is flaggable. Flags on this object type will be reinterpreted as definitions. Flags on queues should just not be used. Use definitions directly. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/QueueTag.java#L21 |
Name | ScriptTag |
Prefix | s@ |
Base Type | ElementTag |
Implements | FlaggableObject |
Identity Format | The identity format for scripts is simply the script name. |
Description | An ObjectTag that represents a script container. ScriptTags contain all information inside the script,
and can be used in a variety of commands that require script arguments. For example, run and inject will 'execute' script entries inside of a script container when given a matching ScriptTag object. ScriptTags also provide a way to access attributes accessed by the replaceable tag system by using the object fetcher or any other entry point to a ScriptTag object. This object type is flaggable. Flags on this object type will be stored in the server saves file, under special sub-key "__scripts" |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ScriptTag.java#L84 |
Name | SecretTag |
Prefix | secret@ |
Base Type | ElementTag |
Identity Format | The identity format for secrets is simply the secret key (as defined by the file 'secrets.secret' in the Denizen folder). |
Description | A SecretTag represents a value that should never be exposed to logs or tags.
For example: authorization tokens, API keys, etc. A SecretTag is made of a 'key', and a 'value'. The key is a simple name, like 'my_bot_token', that is safe to show in logs/etc. The value is the actual internal data that must be kept secret, often a generated code. The keys and values must be defined in the 'secrets.secret' file inside the Denizen folder. The contents of that file would look something like: !SECRETS_FILE my_bot_token: abc123.123abc my_api_key: 1a2b3c4d5e6f The above example defines SecretTag 'my_bot_token' as 'abc123.123abc', meaning you could then use '<secret[my_bot_token]>' in the input to a command that parses secrets to have it understand the real value to input should be 'abc123.123abc' However if you use the same tag in for example a narrate command, it would just narrate 'secret@my_bot_token', keeping your real value safe. Note that the "!SECRETS_FILE" prefix cannot be removed, but comments can be added/removed/altered freely with a "#" prefix. Commands that accept SecretTag inputs will document that information in the command meta. For example, see webget. There is intentionally no tag that can read the value of a secret. You can reload the secrets file via "/ex reload config" |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/SecretTag.java#L48 |
Name | TradeTag |
Prefix | trade@ |
Base Type | ElementTag |
Implements | PropertyHolderObject |
Identity Format | The identity format for trades is just the text 'trade'. All other data is specified through properties. |
Description | Merchant trades are the parts of a special merchant inventory that is typically viewed by right clicking
a villager entity. Any number of trades can fit in a single merchant inventory. Trades are represented by TradeTags. The properties that can be used to customize a merchant trade are: result=<item> inputs=<item>(|<item>) uses=<number of uses> max_uses=<maximum number of uses> has_xp=true/false For example, the following command opens a virtual merchant inventory with two merchant trades. The first trade offers a sponge for two emeralds, can be used up to 10 times, and offers XP upon a successful transaction. The second trade has zero maximum uses and displays a barrier in the input and output slots.
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/TradeTag.java#L17 |
Name | <ChunkTag.plugin_tickets> |
Returns | ListTag(PluginTag) |
Mechanism | ChunkTag.clear_plugin_tickets |
Description | Returns a list of plugins that are keeping this chunk loaded.
This is related to the chunkload command. |
Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/ChunkTag.java#L368 |
Name | <ColorTag.to_particle_offset> |
Returns | LocationTag |
Description | Returns the color as a particle offset, for use with playeffect. |
Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitColorExtensions.java#L29 |
Name | <ElementTag.and[<element>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether both the element and the second element are true.
You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | element checking |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L1056 |
Name | <ElementTag.click_chat[<message>]> |
Returns | ElementTag |
Description | Adds a click command to the element, which makes the element pseudo-chat the input message when clicked, for activating interact script chat triggers (Chat Triggers).
This internally uses the command "/denizenclickable chat SOME MESSAGE HERE" (requires players have permission "denizen.clickable") Note that this is a magic Denizen tool - refer to Denizen Text Formatting. |
Example |
|
Group | text manipulation |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitElementExtensions.java#L525 |
Name | <ElementTag.click_url[<url>]> |
Returns | ElementTag |
Description | Adds a click command to the element, which makes the element open the given URL when clicked.
Note that this is a magic Denizen tool - refer to Denizen Text Formatting. |
Example |
|
Group | text manipulation |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitElementExtensions.java#L511 |
Name | <ElementTag.equals[<element>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether the element is equal to another element.
Equivalent to if comparison: == You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | comparison |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L443 |
Name | <ElementTag.is_less_than_or_equal_to[<number>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether this decimal number is less than or equal to the input decimal number.
Equivalent to if comparison: <= You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | comparison |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L495 |
Name | <ElementTag.is_less_than[<number>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether this decimal number is less than the input decimal number.
Equivalent to if comparison: < You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | comparison |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L469 |
Name | <ElementTag.is_more_than_or_equal_to[<number>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether this decimal number is greater than or equal to the input decimal number.
Equivalent to if comparison: >= You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | comparison |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L482 |
Name | <ElementTag.is_more_than[<number>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether this decimal number is greater than the input decimal number.
Equivalent to if comparison: > You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | comparison |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L456 |
Name | <ElementTag.not> |
Returns | ElementTag(Boolean) |
Description | Returns the opposite of the element
IE, true returns false and false returns true. You should never ever use this tag inside any 'if', 'while', etc. command (instead, use the '!' negation prefix). |
Generated Example |
|
Group | element checking |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L1033 |
Name | <ElementTag.on_click[<message>].type[<type>]> |
Returns | ElementTag |
Description | Adds a click command to the element, which makes the element execute the input command when clicked.
Available command types: OPEN_URL, OPEN_FILE, RUN_COMMAND, SUGGEST_COMMAND, COPY_TO_CLIPBOARD, or CHANGE_PAGE. For example: - narrate "You can <element[click here].on_click[https://denizenscript.com].type[OPEN_URL]> to learn about Denizen!" Note that this is a magic Denizen tool - refer to Denizen Text Formatting. For run_command, prefer ElementTag.on_click For chat, prefer ElementTag.click_chat For URLs, prefer ElementTag.click_url |
Group | text manipulation |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitElementExtensions.java#L558 |
Name | <ElementTag.or[<element>]> |
Returns | ElementTag(Boolean) |
Description | Returns whether either the element or the second element are true.
You should never ever use this tag inside any 'if', 'while', etc. command. |
Group | element checking |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L1068 |
Name | <ElementTag.split_args> |
Returns | ListTag |
Description | Returns a list of portions of this element, split the same way command arguments are split.
That is, split by spaces but respecting the use of "quotes" to contain spaces within a single argument. |
Generated Example |
|
Group | element manipulation |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ElementTag.java#L1550 |
Name | <EntityTag.attached_entities[(<player>)]> |
Returns | ListTag(EntityTag) |
Description | Returns the entities attached to this entity by attach.
Optionally, specify a player. If specified, will return entities attached visible to that player. If not specified, returns entities globally attached. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2762 |
Name | <EntityTag.attached_offset[(<player>)]> |
Returns | LocationTag |
Description | Returns the offset of an attachment for this entity to another that was attached by attach.
Optionally, specify a player. If specified, will return entity attachment visible to that player. If not specified, returns any entity global attachment. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2804 |
Name | <EntityTag.attached_to[(<player>)]> |
Returns | EntityTag |
Description | Returns the entity that this entity was attached to by attach.
Optionally, specify a player. If specified, will return entity attachment visible to that player. If not specified, returns any entity global attachment. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2784 |
Name | <EntityTag.charged> |
Returns | ElementTag(Boolean) |
Mechanism | EntityTag.charged |
Description | (Property) If the entity is wither_skull, controls whether the skull is charged. Charged skulls are blue.
If the entity is a vex, controls whether the vex is charging. Charging vexes have red lines. This is a visual effect, and does not cause the vex to actually charge at anyone. If the entity is a guardian, controls whether the guardian's laser is active. Note that guardians also require a target to use their laser, see attack. |
Generated Example |
|
Group | Properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/entity/EntityCharged.java#L10 |
Name | <EntityTag.disguise_to_others[(<player>)]> |
Returns | EntityTag |
Description | Returns the fake entity used to disguise the entity in other's views, either globally (if no context input given), or to the specified player.
Relates to disguise. |
Generated Example |
|
Group | properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2567 |
Name | <EntityTag.disguised_type[(<player>)]> |
Returns | EntityTag |
Description | Returns the entity type the entity is disguised as, either globally (if no context input given), or to the specified player.
Relates to disguise. |
Generated Example |
|
Group | properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2533 |
Name | <EntityTag.is_disguised[(<player>)]> |
Returns | ElementTag(Boolean) |
Description | Returns whether the entity is currently disguised, either globally (if no context input given), or to the specified player.
Relates to disguise. |
Generated Example |
|
Group | properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/EntityTag.java#L2507 |
Name | <EntityTag.is_sneaking> |
Returns | ElementTag(Boolean) |
Mechanism | EntityTag.is_sneaking |
Description | (Property) Whether an entity is sneaking.
For most entities this just makes the name tag less visible, and doesn't actually update the pose. Note that sneak is also available. |
Generated Example |
|
Group | Properties |
Requires | Paper |
Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/properties/EntitySneaking.java#L12 |
Name | <EntityTag.visual_fire> |
Returns | ElementTag(Boolean) |
Mechanism | EntityTag.visual_fire |
Description | (Property) Whether an entity has a fake fire effect. For actual fire, see burn and EntityTag.on_fire. |
Generated Example |
|
Group | Properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/entity/EntityVisualFire.java#L9 |
Name | <ImageTag.copy> |
Returns | ImageTag |
Description | Returns a copy of the image, useful for getting normal images from id-based ones (see Image). |
Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ImageTag.java#L204 |
Name | <ListTag.closest_to[<text>]> |
Returns | ElementTag |
Description | Returns the raw text of the item in the list that seems closest to the given value.
Particularly useful for command handlers, "<list[c1|c2|c3|...].closest_to[<argument>]>" to get the best option as "did you mean" suggestion. Be warned that this will always return /something/, excluding the case of an empty list, which will return an empty element. Uses the logic of tag "ElementTag.difference"! You can use that tag to add an upper limit on how different the text can be. |
Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ListTag.java#L2734 |
Name | <LocationTag.formatted.citizens> |
Returns | ElementTag |
Description | Returns the location formatted for a Citizens command.
In the format: x.x:y.y:z.z:world For example: 1.0:2.0:3.0:world_nether |
Group | identity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L3188 |
Name | <LocationTag.switched> |
Returns | ElementTag(Boolean) |
Description | Returns whether the block at the location is considered to be switched on.
(For buttons, levers, etc.) To change this, see Switch |
Generated Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/LocationTag.java#L1232 |
Name | <MapTag.to_json[(native_types=<true/false>);(indent=<#>)]> |
Returns | ElementTag |
Description | Returns a JSON encoding of this map. Primarily useful with interop with other software, such as when use webget or webserver.
Optionally specify configuration input with: 'native_types' (defaults to false) if 'true' will attempt to convert 'true' or 'false' to booleans, and numbers to raw numbers. 'indent' (defaults to 0) to specify the indentation level of the JSON text output. 0 means no spacing or newlines at all. |
Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/MapTag.java#L951 |
Name | <MaterialTag.mode> |
Returns | ElementTag |
Mechanism | MaterialTag.mode |
Description | Returns a block's mode.
For comparators, output is COMPARE or SUBTRACT. For piston_heads, output is NORMAL or SHORT. For bubble_columns, output is NORMAL or DRAG. For structure_blocks, output is CORNER, DATA, LOAD, or SAVE. For sculk_sensors, output is ACTIVE, COOLDOWN, or INACTIVE. For daylight_detectors, output is INVERTED or NORMAL. For command_blocks, output is CONDITIONAL or NORMAL. For big_dripleafs, output is FULL, NONE, PARTIAL, or UNSTABLE. For sculk_catalysts, output is BLOOM or NORMAL. For sculk_shriekers, output is SHRIEKING or NORMAL. For tripwires, output is ARMED or DISARMED. |
Generated Example |
|
Group | properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/material/MaterialMode.java#L60 |
Name | <NPCTag.engaged[(<player>)]> |
Returns | ElementTag(Boolean) |
Description | Returns whether the NPC is currently engaged.
See engage |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/NPCTag.java#L789 |
Name | <NPCTag.invulnerable> |
Returns | ElementTag(Boolean) |
Description | Returns whether the NPC is currently invulnerable.
See vulnerable |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/NPCTag.java#L800 |
Name | <NPCTag.is_sitting> |
Returns | ElementTag(Boolean) |
Description | Returns true if the NPC is sitting. Relates to sit. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/NPCTag.java#L474 |
Name | <NPCTag.is_sleeping> |
Returns | ElementTag(Boolean) |
Description | Returns true if the NPC is sleeping. Relates to sleep. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/NPCTag.java#L485 |
Name | <ObjectTag.prefix> |
Returns | ElementTag |
Description | Returns the prefix of the tag type that is processing this tag, like 'List'.
Prefixes are generally only used for debugging (for example, command execution reports show them). This tag should not be relied on or expected to return any specific value. It may change arbitrarily or even be removed at any time. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/CoreObjectTags.java#L23 |
Name | <PlayerTag.bossbar_ids> |
Returns | ListTag |
Description | Returns a list of all bossbars from bossbar that this player can see.
Does not list bossbars created by any other source. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2510 |
Name | <PlayerTag.disguise_to_self[(<player>)]> |
Returns | EntityTag |
Description | Returns the fake entity used to disguise the entity in the player's self-view (only relevant to players), either globally (if no context input given), or to the specified player.
Relates to disguise. |
Generated Example |
|
Group | properties |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2361 |
Name | <PlayerTag.fake_block_locations> |
Returns | ListTag(LocationTag) |
Description | Returns a list of locations that the player will see a fake block at, as set by showfake or connected commands. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2303 |
Name | <PlayerTag.fake_block[<location>]> |
Returns | MaterialTag |
Description | Returns the fake material that the player will see at the input location, as set by showfake or connected commands.
Works best alongside PlayerTag.fake_block_locations. Returns null if the player doesn't have a fake block at the location. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2320 |
Name | <PlayerTag.fake_entities> |
Returns | ListTag(EntityTag) |
Description | Returns a list of fake entities the player can see, as set by fakespawn.
Note that these entities are not being tracked by the server, so many operations may not be possible on them. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2343 |
Name | <PlayerTag.scoreboard_id> |
Returns | ElementTag |
Description | Returns the ID of the scoreboard from scoreboard that a player is currently viewing, if any. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2480 |
Name | <PlayerTag.sidebar_lines> |
Returns | ListTag |
Description | Returns the current lines set on the player's Sidebar via sidebar. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L1619 |
Name | <PlayerTag.sidebar_scores> |
Returns | ListTag |
Description | Returns the current scores set on the player's Sidebar via sidebar,
in the same order as PlayerTag.sidebar_lines. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L1647 |
Name | <PlayerTag.sidebar_title> |
Returns | ElementTag |
Description | Returns the current title set on the player's Sidebar via sidebar. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L1633 |
Name | <PlayerTag.time> |
Returns | ElementTag(Number) |
Description | Returns the time the player is currently experiencing.
This time could differ from the time that the rest of the world is currently experiencing if time is being used on the player. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/PlayerTag.java#L2154 |
Name | <QueueTag.determination> |
Returns | ListTag |
Description | Returns the values that have been determined via Determine
for this queue, or null if there is none. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/QueueTag.java#L317 |
Name | <ScriptTag.step_expiration[(<player>)]> |
Returns | TimeTag |
Description | Returns the time that an interact script step expires at, if applied by zap with a duration limit. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/properties/bukkit/BukkitScriptExtensions.java#L65 |
Name | <server.bossbar_viewers[<bossbar_id>]> |
Returns | ListTag(PlayerTag) |
Description | Returns a list of players that should be able to see the given bossbar ID from bossbar. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L1634 |
Name | <server.current_bossbars> |
Returns | ListTag |
Description | Returns a list of all currently active boss bar IDs from bossbar. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L1624 |
Name | <server.effect_types> |
Returns | ListTag |
Description | Returns a list of all 'effect' types known to the server.
Generally used with playeffect. This is only their Bukkit enum names, as seen at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Effect.html. Refer also to server.particle_types. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L860 |
Name | <server.map_cursor_types> |
Returns | ListTag |
Description | Returns a list of all map cursor types known to the server.
Generally used with map and Map Script Containers. This is only their Bukkit enum names, as seen at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/map/MapCursor.Type.html. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L925 |
Name | <server.particle_types> |
Returns | ListTag |
Description | Returns a list of all particle effect types known to the server.
Generally used with playeffect. This is only their Bukkit enum names, as seen at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Particle.html. Refer also to server.effect_types. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L849 |
Name | <server.potion_effect_types> |
Returns | ListTag |
Description | Returns a list of all potion effects known to the server.
Can be used with cast. This is only their Bukkit enum names, as seen at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html. Refer also to server.potion_types. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L881 |
Name | <server.world_types> |
Returns | ListTag |
Description | Returns a list of all world types known to the server.
Generally used with createworld. This is only their Bukkit enum names, as seen at https://hub.spigotmc.org/javadocs/spigot/org/bukkit/WorldType.html. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/tags/core/ServerTagBase.java#L944 |
Name | <util.list_numbers_to[<#>]> |
Returns | ListTag |
Description | Returns a list of integer numbers from 1 to the specified input number (inclusive).
Note that you should NEVER use this as the input to a "foreach" command. Instead, use repeat. In most cases, there's a better way to do what you're trying to accomplish than using this tag. Consider instead using util.list_numbers |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L297 |
Name | <util.list_numbers[to=<#>;(from=<#>/{1});(every=<#>/{1})]> |
Returns | ListTag |
Description | Returns a list of integer numbers in the specified range.
You must specify at least the 'to' input, you can optionally specify 'from' (default 1), and 'every' (default 1). Note that this generally should not be used as input to the 'foreach' command. Instead, use repeat. |
Example |
|
Example |
|
Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L265 |
Name | <util.mongo_connections> |
Returns | ElementTag |
Description | Returns a list of all Mongo connections opened by mongo. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L902 |
Name | <util.redis_connections> |
Returns | ListTag |
Description | Returns a list of all Redis connections opened by redis. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L890 |
Name | <util.runlater_ids> |
Returns | ListTag |
Description | Returns a list of all scheduled task IDs for runlater.
Note that usages of runlater that didn't specify an ID will not show up here. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L621 |
Name | <util.sql_connections> |
Returns | ListTag |
Description | Returns a list of all SQL connections opened by sql. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/tags/core/UtilTagBase.java#L866 |
Name | ActionBar |
Syntax | actionbar [<text>] (targets:<player>|...) (format:<script>) (per_player) |
Short Description | Sends a message to a player's action bar. |
Full Description | Sends a message to the target's action bar area.
If no target is specified it will default to the attached player. Accepts the 'format:<name>' argument, which will reformat the text according to the specified format script. See Format Script Containers. Optionally use 'per_player' with a list of player targets, to have the tags in the text input be reparsed for each and every player. So, for example, "- actionbar 'hello <player.name>' targets:<server.online_players>" would normally show "hello bob" to every player (every player sees the exact same name in the text, ie bob sees "hello bob", steve also sees "hello bob", etc) but if you use "per_player", each player online would see their own name (so bob sees "hello bob", steve sees "hello steve", etc). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ActionBarCommand.java#L35 |
Name | Announce |
Syntax | announce [<text>] (to_ops/to_console/to_flagged:<flag_name>/to_permission:<node>) (format:<script>) |
Short Description | Announces a message for everyone online to read. |
Full Description | Announce sends a raw message to players.
Simply using announce with text will send the message to all online players using the Spigot broadcast system. Specifying the 'to_ops' argument will narrow down the players in which the message is sent to ops only. Alternatively, using the 'to_permission' argument will send the message to only players that have the specified permission node. Or, using the 'to_flagged' argument will send the message to only players that have the specified flag. You can also use the 'to_console' argument to make it so it only shows in the server console. Announce can also utilize a format script with the 'format' argument. See Format Script Containers. Note that the default announce mode (that shows for all players) relies on the Spigot broadcast system, which requires the permission "bukkit.broadcast.user" to see broadcasts. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/AnnounceCommand.java#L27 |
Name | Ban |
Syntax | ban ({add}/remove) [<player>|.../addresses:<address>|.../names:<name>|...] (reason:<text>) (expire:<time>) (source:<text>) |
Short Description | Ban or un-ban players or ip addresses. |
Full Description | Add or remove player or ip address bans from the server. Banning a player will also kick them from the server.
You may specify a list of player names instead of PlayerTags, which should only ever be used for special cases (such as banning players that haven't joined the server yet). You may optionally specify both a list of players and list of addresses. Additional options are: reason: Sets the ban reason. expire: Sets the expire time of the temporary ban, as a TimeTag or a DurationTag. This will be a permanent ban if not specified. source: Sets the source of the ban. |
Related Tags | <PlayerTag.is_banned> Returns whether the player is banned.
<PlayerTag.ban_reason> Returns the reason for the player's ban, if they are banned.
<PlayerTag.ban_expiration_time> Returns the expiration of the player's ban, if they are banned. (...)
<PlayerTag.ban_created_time> Returns when the player's ban was created, if they are banned.
<PlayerTag.ban_source> Returns the source of the player's ban, if they are banned.
<server.is_banned[<address>]> Returns whether the given ip address is banned.
<server.ban_info[<address>].expiration_time> Returns the expiration of the ip address's ban, if it is banned. (...)
<server.ban_info[<address>].reason> Returns the reason for the ip address's ban, if it is banned.
<server.ban_info[<address>].created_time> Returns when the ip address's ban was created, if it is banned.
<server.ban_info[<address>].source> Returns the source of the ip address's ban, if it is banned.
<server.banned_addresses> Returns a list of all banned ip addresses.
<server.banned_players> Returns a list of all banned players.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/BanCommand.java#L31 |
Name | BlockCrack |
Syntax | blockcrack [<location>] [progress:<#>] (stack) (players:<player>|...) (duration:<duration>) |
Short Description | Shows the player(s) a block cracking animation. |
Full Description | You must specify a progress number between 1 and 10, where 1 is the first stage and 10 is the last.
To remove the animation, you must specify any number outside of that range. For example, 0. Optionally, you can stack multiple effects or set a duration for how long the effect should be shown. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/BlockCrackCommand.java#L32 |
Name | BossBar |
Syntax | bossbar ({auto}/create/update/remove) [<id>] (players:<player>|...) (title:<title>) (progress:<#.#>) (color:<color>) (style:<style>) (options:<option>|...) (uuid:<uuid>) |
Short Description | Shows players a boss bar. |
Full Description | Displays a boss bar at the top of the screen of the specified player(s).
You can also update the values and remove the bar. You can CREATE a new bossbar, UPDATE an existing one, or REMOVE an existing one. The default 'auto' will either 'create' or 'update' depending on whether it already exists. Requires an ID. Progress must be between 0 and 1. Valid colors: BLUE, GREEN, PINK, PURPLE, RED, WHITE, YELLOW. Valid styles: SEGMENTED_10, SEGMENTED_12, SEGMENTED_20, SEGMENTED_6, SOLID. Valid options: CREATE_FOG, DARKEN_SKY, PLAY_BOSS_MUSIC. The UUID can optionally be specified, and will be sent to the client. Be careful to not overlap multiple bars with the same UUID. If not specified, it will be random. |
Related Tags | <server.current_bossbars> Returns a list of all currently active boss bar IDs from bossbar.
<server.bossbar_viewers[<bossbar_id>]> Returns a list of players that should be able to see the given bossbar ID from bossbar.
<PlayerTag.bossbar_ids> Returns a list of all bossbars from bossbar that this player can see. (...)
<entry[saveName].bar_uuid> returns the bossbar's UUID.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/BossBarCommand.java#L34 |
Name | bossshop |
Syntax | bossshop [<shop name>] |
Short Description | Opens a BossShop inventory for a player. |
Full Description | Use to open up a BossShop inventory for the linked player.
Useful for rewarding players using the BossShop plugin. Shops are made with the BossShop system. |
Related Tags | <InventoryTag.is_bossshop> Returns whether the inventory is a BossShop.
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, BossShopPro |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/bossshop/BossShopCommand.java#L23 |
Name | ChunkLoad |
Syntax | chunkload ({add}/remove/removeall) [<chunk>|...] (duration:<value>) |
Short Description | Keeps a chunk actively loaded and allowing activity. |
Full Description | Forces a chunk to load and stay loaded in the world for the duration specified or until removed.
This will not persist over server restarts. If no duration is specified it defaults to 0 (forever). While a chunk is loaded all normal activity such as crop growth and npc activity continues, other than activity that requires a nearby player. |
Related Tags | <WorldTag.loaded_chunks> Returns a list of all the currently loaded chunks.
<ChunkTag.is_loaded> Returns true if the chunk is currently loaded into memory.
<ChunkTag.force_loaded> Returns whether the chunk is forced to stay loaded at all times.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/ChunkLoadCommand.java#L41 |
Name | ClientRun |
Syntax | clientrun [<script>] (path:<name>) (def.<name>:<value>) (defmap:<map>) |
Short Description | Runs a client script on a Clientizen client. |
Full Description | Runs a client script on the linked player's client, if they are using Clientizen.
You must specify a client script name to run. Optionally, use the "path:" argument to choose a specific sub-path within a script. Optionally, use "def.<name>:<value>" to pass one or more definitions to the client. Alternately, use "defmap:<map>" to specify definitions to pass as a MapTag, where the keys will be definition names and the values will of course be definition values. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, Clientizen |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/clientizen/commands/ClientRunCommand.java#L24 |
Name | CopyBlock |
Syntax | copyblock [<location>] [to:<location>] (remove_original) |
Short Description | Copies a block to another location, keeping metadata when possible. |
Full Description | Copies a block to another location.
You may also use the 'remove_original' argument to delete the original block. This effectively moves the block to the target location. |
Related Tags | <LocationTag.material> Returns the material of the block at the location.
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/CopyBlockCommand.java#L29 |
Name | Create |
Syntax | create [<entity>] [<name>] (<location>) (traits:<trait>|...) (registry:<name>) |
Short Description | Creates a new NPC, and optionally spawns it at a location. |
Full Description | Creates an npc which the entity type specified, or specify an existing npc to create a copy.
If no location is specified the npc is created despawned. Use the 'save:<savename>' argument to return the npc for later use in a script. Optionally specify a list of traits to immediately apply when creating the NPC. Optionally specify a custom registry to create the NPC into. (Most users, leave this option off). Will generate a new registry if needed. |
Related Tags | <server.npcs> Returns a list of all NPCs.
<entry[saveName].created_npc> returns the NPC that was created.
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/CreateCommand.java#L29 |
Name | CustomEvent |
Syntax | customevent [id:<id>] (context:<map>) |
Short Description | Fires a custom world script event. |
Full Description | Fires a custom world script event.
Input is an ID (the name of your custom event, choose a constant name to use), and an optional MapTag of context data. Linked data (player, npc, ...) is automatically sent across to the event. Use with custom event |
Related Tags | <entry[saveName].any_ran> returns a boolean indicating whether any events ran as a result of this command.
<entry[saveName].was_cancelled> returns a boolean indicating whether the event was cancelled.
<entry[saveName].determination_list> returns a ListTag of determinations to this event. Will be an empty list if 'determine output:' is never used.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/CustomEventCommand.java#L23 |
Name | DebugBlock |
Syntax | debugblock [<location>|.../clear] (color:<color>) (name:<name>) (players:<player>|...) (d:<duration>{10s}) |
Short Description | Shows or clears minecraft debug blocks. |
Full Description | Shows or clears minecraft debug blocks, AKA "Game Test Markers".
These are block-grid-aligned markers that are a perfect cube of a single (specifiable) transparent color, and stay for a specified duration of time or until cleared. Markers can optionally also have simple text names. If arguments are unspecified, the default color is white, the default player is the linked player, the default name is none, and the default duration is 10 seconds. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | gametestmarker |
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/DebugBlockCommand.java#L30 |
Name | DefineMap |
Related Guide Page | https://guide.denizenscript.com/guides/basics/definitions.html |
Syntax | definemap [<name>] [<key>:<value> ...] |
Short Description | Creates a MapTag definition with key/value pairs constructed from the input arguments. |
Full Description | Creates a MapTag definition with key/value pairs constructed from the input arguments. |
Related Tags | <[<id>]> to get the value assigned to an ID
|
Usage Example |
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/DefineMapCommand.java#L26 |
Name | Drop |
Syntax | drop [<entity_type>/xp/<item>|...] (<location>) (quantity:<#>) (speed:<#.#>) (delay:<duration>) |
Short Description | Drops an item, entity, or experience orb on a location. |
Full Description | To drop an item, just specify a valid item object. To drop an entity, specify a generic entity object.
Drop can also reward players with experience orbs by using the 'xp' argument. For all three usages, you can optionally specify an integer with 'quantity:' prefix to drop multiple items/entities/xp. For items, you can add 'speed:' to modify the launch velocity. You can also add 'delay:' to set the pickup delay of the item. |
Related Tags | <entry[saveName].dropped_entities> returns a list of entities that were dropped.
<entry[saveName].dropped_entity> returns a single entity that was dropped (if only one).
<EntityTag.item> (Property) An entity's item, which can be: (...)
<EntityTag.experience> Returns the experience value of this experience orb entity.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/DropCommand.java#L34 |
Name | FakeInternalData |
Syntax | fakeinternaldata [entity:<entity>] [data:<map>|...] (for:<player>|...) (speed:<duration>) |
Short Description | Sends fake entity data updates, optionally animating them with sub-tick precision. |
Full Description | Sends fake internal entity data updates, optionally sending multiple over time.
This supports sub-tick precision, allowing smooth/high FPS animations. The input to 'data:' is a list of MapTags, with each map being a frame to send; see Internal Entity Data for more information. Optionally specify a list of players to fake the data for, defaults to the linked player. 'speed:' is the amount of time between each frame getting sent, supporting sub-tick delays. Note that this is the delay between each frame, regardless of their content (see examples). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FakeInternalDataCommand.java#L46 |
Name | Feed |
Syntax | feed (<entity>) (amount:<#>) (saturation:<#.#>) |
Short Description | Feed the player or npc. |
Full Description | Feeds the player or npc specified.
By default targets the player attached to the script queue and feeds a full amount. Accepts the 'amount:' argument, which is in half bar increments, up to a total of 20 food points. The amount may be negative, to cause hunger instead of satiating it. You can optionally also specify an amount to change the saturation by. By default, the saturation change will be the same as the food level change. This is also up to a total of 20 points. This value may also be negative. Also accepts the 'target:<entity>' argument to specify the entity which will be fed the amount. |
Related Tags | <PlayerTag.food_level> Returns the current food level (aka hunger) of the player.
<PlayerTag.formatted_food_level> Returns a 'formatted' value of the player's current food level. (...)
<PlayerTag.saturation> Returns the current food saturation of the player. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FeedCommand.java#L24 |
Name | Fish |
Syntax | fish [<location>/stop] (catch:{none}/default/junk/treasure/fish) (chance:<#>) |
Short Description | Causes an NPC to begin fishing around a specified location. |
Full Description | Causes an NPC to begin fishing at the specified location.
Setting catch determines what items the NPC may fish up, and the chance is the odds of the NPC fishing up an item. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/FishCommand.java#L27 |
Name | Fly |
Syntax | fly (cancel) [<entity>|...] (controller:<player>) (origin:<location>) (destinations:<location>|...) (speed:<#.#>) (rotationthreshold:<#.#>) |
Short Description | Make an entity fly where its controller is looking or fly to waypoints. |
Full Description | Make an entity fly where its controller is looking or fly to waypoints.
This is particularly useful as a way to make flying entities rideable (or make a non-flying entity start flying). Optionally specify a list of "destinations" to make it move through a series of checkpoints (disabling the "controller" functionality). Optionally specify an "origin" location where the entities should teleport to at the start. Optionally specify the "speed" argument to set how fast the entity should fly. Optionally specify the "rotationthreshold" to set the minimum threshold (in degrees) before the entity should forcibly rotate to the correct direction. Use the "cancel" argument to stop an existing flight. |
Related Tags | <PlayerTag.can_fly> Returns whether the player is allowed to fly. (...)
<PlayerTag.fly_speed> Returns the speed the player can fly at. (...)
<PlayerTag.is_flying> Returns whether the player is currently flying.
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FlyCommand.java#L36 |
Name | Follow |
Syntax | follow (followers:<entity>|...) (stop/target:<entity>) (lead:<#.#>) (max:<#.#>) (speed:<#.#>) (allow_wander) (no_teleport) |
Short Description | Causes a list of entities to follow a target. |
Full Description | Causes a list of entities to follow a target.
Specify the list of followers or just one. If no follower is specified, will use the linked NPC. Specify either the target to follow, or 'stop'. If no target is specified, will use the linked player. Use 'speed' to set the movement speed multiplier. Use 'lead' to set how far away the follower will remain from the target (ie, it won't try to get closer than the 'lead' distance). Use 'max' to set the maximum distance between the follower and the target before the follower will automatically start teleporting to keep up. Use 'no_teleport' to disable teleporting when the entity is out of range (instead, the entity will simply give up). Use 'allow_wander' to allow the entity to wander randomly. The 'max' and 'allow_wander' arguments can only be used on non-NPC entities. |
Related Tags | <NPCTag.navigator.target_entity> returns the entity the npc is following.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FollowCommand.java#L24 |
Name | Gamerule |
Syntax | gamerule [<world>] [<rule>] [<value>] |
Short Description | Sets a gamerule on the world. |
Full Description | Sets a gamerule on the world. A list of valid gamerules can be found here: https://minecraft.wiki/w/Game_rule
Note: Be careful, gamerules are CASE SENSITIVE. |
Related Tags | <WorldTag.gamerule[<gamerule>]> Returns the current value of the specified gamerule in the world. (...)
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/GameRuleCommand.java#L24 |
Name | Glow |
Syntax | glow (<entity>|...) ({true}/false/toggle/reset) (for:<player>|...) |
Short Description | Sets whether an NPC or entity is glowing. |
Full Description | Sets whether the specified entities glow, defaults to the linked player/NPC if none were specified.
Optionally specify 'for:' with a list of players to fake the entities' glow state for these players. When using 'toggle' with the 'for:' argument, the glow state will be toggled for each player separately. If unspecified, will be set globally. 'for:' players remain tracked even when offline/reconnecting, but are forgotten after server restart. When not using 'for:', the glow is global / on the real entity, which will persist in that entity's data until changed. To reset an entity's fake glow use the 'reset' state. A reset is global by default, use the 'for:' argument to reset specific players. |
Related Tags | <EntityTag.glowing> Returns whether this entity is glowing.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/GlowCommand.java#L26 |
Name | Inject |
Related Guide Page | https://guide.denizenscript.com/guides/basics/run-options.html |
Syntax | inject [<script>] (path:<name>) (instantly) |
Short Description | Runs a script in the current queue. |
Full Description | Injects a script into the current queue.
This means this task will run with all of the original queue's definitions and tags. It will also now be part of the queue, so any delays or definitions used in the injected script will be accessible in the original queue. |
Related Tags | None
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/InjectCommand.java#L25 |
Name | Invisible |
Syntax | invisible (<entity>|...) ({true}/false/toggle/reset) (for:<player>|...) |
Short Description | Sets whether an NPC or entity are invisible. |
Full Description | Sets whether the specified entities are invisible (equivalent to an invisibility potion), defaults to the linked player/NPC if none were specified.
If an NPC was specified, the 'invisible' trait is applied. Optionally specify 'for:' with a list of players to fake the entities' visibility state for these players. When using 'toggle' with the 'for:' argument, the visibility state will be toggled for each player separately. If unspecified, will be set globally. 'for:' players remain tracked even when offline/reconnecting, but are forgotten after server restart. Note that using the 'for:' argument won't apply the 'invisible' trait to NPCs. When not using 'for:', the effect is global / on the real entity, which will persist in that entity's data until changed. To reset an entity's fake visibility use the 'reset' state. A reset is global by default, use the 'for:' argument to reset specific players. NPCs can't be made invisible if not added to the playerlist (the invisible trait adds the NPC to the playerlist when set). See invisible trait |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/InvisibleCommand.java#L32 |
Name | ItemCooldown |
Syntax | itemcooldown [<material>|...] (duration:<duration>) |
Short Description | Places a cooldown on a material in a player's inventory. |
Full Description | Places a cooldown on a material in a player's inventory. |
Related Tags | <PlayerTag.item_cooldown[<material>]> Returns the cooldown duration remaining on player's material.
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ItemCooldownCommand.java#L26 |
Name | Jobs |
Syntax | jobs [promote/demote/join/quit] [<job>] (<#>) |
Short Description | Modifies the specified job of a player. |
Full Description | This allows you to promote or demote a player's job level.
This also allows you to force a player to join or quit a job. |
Related Tags | <PlayerTag.job[<job>]> Returns the job specified with the player's information attached.
<PlayerTag.current_jobs> Returns a list of all jobs that the player is in.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, Jobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/jobs/JobsCommand.java#L28 |
Name | kick |
Syntax | kick [<player>|...] (reason:<text>) |
Short Description | Kicks a player from the server. |
Full Description | Kick a player or a list of players from the server and optionally specify a reason.
If no reason is specified it defaults to "Kicked." |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/KickCommand.java#L20 |
Name | Leash |
Syntax | leash (cancel) [<entity>|...] (holder:<entity>/<location>) |
Short Description | Sticks a leash on target entity, held by a fence or another entity. |
Full Description | Attaches a leash to the specified entity.
The leash may be attached to a fence, or another entity. Players and Player NPCs may not be leashed. Note that releasing a mob from a fence post may leave the leash attached to that fence post. Non-player NPCs can be leashed if '/npc leashable' is enabled. |
Related Tags | <EntityTag.is_leashed> Returns whether the entity is leashed.
<EntityTag.leash_holder> Returns the leash holder of entity.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/LeashCommand.java#L27 |
Name | libsdisguise |
Syntax | libsdisguise [remove/player/mob/misc] (type:<entity type>) (target:<entity>) (name:<text>) (display_name:<text>) (baby) (id:<item>) (self) (hide_name) |
Short Description | Disguises an entity as a different entity. |
Full Description | Disguises an entity using Lib's Disguises.
This hides the true entity and replaces it with a fake entity as a disguise. The entity mimics the same actions and movement as the entity in a disguise. The required argument depends on the first argument: For 'mob': Specify an entity type. Optionally, specify if the mob is a baby or not (defaults to false). For 'player': Specify the player name. For 'misc': Specify a misc disguise type. Optionally, specify id as an ItemTag. Removing a disguise shows the true entity again for all players. Only one disguise can be set per target, if another one is set, the previous disguise is removed. Optionally specify 'self' to hide the disguise from the target player, so they still see their normal player. Optionally specify 'baby' to make the disguised mob a baby (where applicable). Optionally specifiy 'hide_name' to hide the nameplate of a player disguise. Optionally specify 'display_name' to set the display name of the disguise. |
Related Tags | <EntityTag.libsdisguise_is_disguised> Returns whether the entity is in a disguise.
<EntityTag.libsdisguise_disguise> Returns the disguise of the entity.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, LibsDisguises |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/libsdisguises/LibsDisguiseCommand.java#L25 |
Name | Look |
Syntax | look (<entity>|...) [<location>/cancel/yaw:<yaw> pitch:<pitch>] (duration:<duration>) (offthread_repeat:<#>) |
Short Description | Causes the NPC or other entity to look at a target location. |
Full Description | Makes the entity look towards the location.
You can specify either a target location, or a yaw and pitch. Can be used on players. If a duration is set, the entity cannot look away from the location until the duration has expired. Use the cancel argument to end the duration earlier. Optionally, you can use the "offthread_repeat:" option alongside "yaw:" and "pitch:" to cause a player's rotation to be smoothed out with a specified number of extra async rotation packets within a single tick. |
Related Tags | <LocationTag.yaw> Returns the normalized yaw of the object at the location.
<LocationTag.pitch> Returns the pitch of the object at the location.
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | turn, face |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/LookCommand.java#L46 |
Name | Money |
Syntax | money [give/take/set] (quantity:<#.#>) (players:<player>|...) |
Short Description | Manage a player's money. |
Full Description | Give money to, take money from, and set the balance of a player.
If no quantity is specified it defaults to '1'. You can specify a list of players to give to or take from. If no player(s) are specified, defaults to the attached player. NOTE: This requires an economy plugin or script, and Vault. May work for offline players depending on economy plugin. |
Related Tags | <PlayerTag.money> Returns the amount of money the player has with the registered Economy system. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Requires | Vault |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/MoneyCommand.java#L28 |
Name | Mount |
Syntax | mount (cancel) [<entity>|...] (<location>) |
Short Description | Mounts one entity onto another. |
Full Description | Mounts an entity onto another as though in a vehicle.
Can be used to force a player into a vehicle or to mount an entity onto another entity, for example a player onto an NPC. If the entity(s) don't exist they will be spawned. Accepts a location, which the entities will be teleported to on mounting. |
Related Tags | <EntityTag.vehicle> If the entity is in a vehicle, returns the vehicle as a EntityTag.
<EntityTag.is_inside_vehicle> Returns whether the entity is inside a vehicle.
<entry[saveName].mounted_entities> returns a list of entities that were mounted.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/MountCommand.java#L27 |
Name | MythicSignal |
Syntax | mythicsignal [<mythicmob>|...] [<signal>] [source:<entity>] |
Short Description | Sends a signal trigger to the target MythicMobs. |
Full Description | This allows you to send a signal trigger to multiple MythicMobs.
If those mobs have any triggers configured for that signal, they will fire. You must specify an entity that acts as the sender. NOTE: signals are case sensitive. |
Related Tags | None
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, MythicMobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mythicmobs/MythicSignalCommand.java#L24 |
Name | MythicSkill |
Syntax | mythicskill [<skillname>] [<location>|.../<entity>|...] (power:<#.#>) (casters:<entity>|...) |
Short Description | Cast a MythicMob skill from an entity. |
Full Description | This will cast a MythicMob skill from any specified entity.
Optionally, you can have multiple entities cast the skill. You may also specify multiple EntityTag(s) or LocationTag(s) for targets. You may not have both the Entity and Location targets, one or the other. The MythicMob configuration must be configured to account for this. |
Related Tags | None
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, MythicMobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mythicmobs/MythicSkillCommand.java#L28 |
Name | MythicSpawn |
Syntax | mythicspawn [<name>] [<location>] (level:<#>) |
Short Description | Spawns a MythicMob at a location. |
Full Description | This allows you to spawn a MythicMob at a location using the mob's internal name. |
Related Tags | <entry[saveName].spawned_mythicmob> returns the spawned MythicMobsMob.
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, MythicMobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mythicmobs/MythicSpawnCommand.java#L24 |
Name | MythicThreat |
Syntax | mythicthreat [<mythicmob>] [add/subtract/set] [<#.#>] (for:<entity>|...) |
Short Description | Modifies the threat table of a Mythic Mob. |
Full Description | This allows you to modify a threat table for an active MythicMob.
Optionally, set a list of entities to apply the threat modification to. |
Related Tags | None
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, MythicMobs |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/mythicmobs/MythicThreatCommand.java#L26 |
Name | Narrate |
Syntax | narrate [<text>] (targets:<player>|...) (format:<script>) (per_player) (from:<uuid>) |
Short Description | Shows some text to the player. |
Full Description | Prints some text into the target's chat area. If no target is specified it will default to the attached player or the console.
Accepts the 'format:<script>' argument, which will reformat the text according to the specified format script. See Format Script Containers. Optionally use 'per_player' with a list of player targets, to have the tags in the text input be reparsed for each and every player. So, for example, "- narrate 'hello <player.name>' targets:<server.online_players>" would normally say "hello bob" to every player (every player sees the exact same name in the text, ie bob sees "hello bob", steve also sees "hello bob", etc) but if you use "per_player", each player online would see their own name (so bob sees "hello bob", steve sees "hello steve", etc). Optionally, specify 'from:<uuid>' to indicate that message came from a specific UUID (used for things like the vanilla client social interaction block option). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/NarrateCommand.java#L38 |
Name | Note |
Related Guide Page | https://guide.denizenscript.com/guides/advanced/notables.html |
Syntax | note [<object>/remove] [as:<name>] |
Short Description | Adds or removes a named note of an object to the server. |
Full Description | Add or remove a 'note' to the server, persistently naming an object that can be referenced in events or scripts.
Only works for object types that are 'notable'. Noted objects are "permanent" versions of other ObjectTags. (See: ObjectTags) Noted objects keep their properties when added. Notable object types: CuboidTag, EllipsoidTag, PolygonTag, LocationTag, InventoryTag |
Related Tags | <server.notes[<type>]> Deprecated in favor of util.notes
<CuboidTag.note_name> Gets the name of a noted CuboidTag. If the cuboid isn't noted, this is null.
<EllipsoidTag.note_name> Gets the name of a noted EllipsoidTag. If the ellipsoid isn't noted, this is null.
<PolygonTag.note_name> Gets the name of a noted PolygonTag. If the polygon isn't noted, this is null.
<InventoryTag.note_name> Gets the name of a noted InventoryTag. If the inventory isn't noted, this is null.
<LocationTag.note_name> Gets the name of a noted LocationTag. If the location isn't noted, this is null.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | notable |
Group | core |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/NoteCommand.java#L26 |
Name | npcbossbar |
Syntax | npcbossbar (remove) (color:<color>) (options:<option>|...) (range:<#>) (style:<style>) (title:<title>) (progress:<progress>) (view_permission:<permission>) (visible:<true/false>) |
Short Description | Controls or removes the linked NPC's bossbar. |
Full Description | Controls or removes the linked NPC's bossbar.
Progress can be a number between 1 and 100 or 'health' to make it track the NPC's health. Placeholder API/Citizens placeholders are supported. Optionally specify a range around the NPC where the bossbar is visible, and/or a permission required to view it. Input an empty view permission to remove it ('view_permission:'). Valid colors: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/boss/BarColor.html. Valid styles: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/boss/BarStyle.html. Valid options: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/boss/BarFlag.html. |
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/NPCBossBarCommand.java#L29 |
Name | OpenTrades |
Syntax | opentrades [<entity>/<trade>|...] (title:<title>) (players:<player>|...) |
Short Description | Opens the specified villager entity's trading inventory or a list of trades. |
Full Description | Forces a player to open a villager's trading inventory or a virtual trading inventory.
If an entity is specified, only one player can be specified. Otherwise, if a list of trades is specified, more than one player can be specified. If the title is not specified, no title will be applied to the virtual trading inventory. If no player is specified, by default the attached player will be forced to trade. |
Related Tags | <PlayerTag.selected_trade_index> Returns the index of the trade the player is currently viewing, if any.
<EntityTag.is_trading> Returns whether the villager entity is trading.
<EntityTag.trades> Returns a list of the Villager's trade recipes.
<EntityTag.trading_with> Returns the player who is trading with the villager entity, or null if it is not trading.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/OpenTradesCommand.java#L31 |
Name | Oxygen |
Syntax | oxygen [<#>] (type:{remaining}/maximum) (mode:{set}/add/remove) |
Short Description | Gives or takes breath from the player. |
Full Description | Used to add to, remove from or set the amount of current oxygen of a player.
Also allows for the changing of the player's maximum oxygen level. Value is in ticks, so 30 equals 1 bubble. |
Related Tags | <PlayerTag.oxygen> Returns the duration of oxygen the entity has left. (...)
<PlayerTag.max_oxygen> Returns the maximum duration of oxygen the entity can have. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/OxygenCommand.java#L21 |
Name | Permission |
Syntax | permission [add/remove] [permission] (group:<name>) (<world>) |
Short Description | Gives or takes a permission node to/from the player or group. |
Full Description | Adds or removes a permission node from a player or group.
Accepts a world for world-based permissions plugins. By default changes the attached player's permissions. Accepts the 'group:<name>' argument to change a group's permission nodes rather than a player's. Note: This requires a permissions plugin and Vault. |
Related Tags | <PlayerTag.has_permission[permission.node]> Returns whether the player has the specified node. (...)
<PlayerTag.has_permission[permission.node].global> Returns whether the player has the specified node, regardless of world. (...)
<PlayerTag.has_permission[permission.node].world[<world>]> Returns whether the player has the specified node in regards to the (...)
<server.has_permissions> Returns whether the server has a known permission plugin loaded. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Requires | Vault |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/PermissionCommand.java#L24 |
Name | playerpoints |
Syntax | playerpoints [set/give/take] [<#>] |
Short Description | Adjusts the amount of points the player has. |
Full Description | Take, give or set the amount of points a player has.
This is useful for plugins supporting this kind of economy which uses the points instead of money as an alternative system. This works for offline players. |
Related Tags | <PlayerTag.playerpoints_points> Returns the amount of points the player has. Only works on online players.
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, PlayerPoints |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/playerpoints/PlayerPointsCommand.java#L22 |
Name | PlaySound |
Syntax | playsound (<location>|...) (<player>|...) [sound:<name>] (volume:<#.#>) (pitch:<#.#>) (custom) (sound_category:<category_name>) |
Short Description | Plays a sound at the location or to a list of players. |
Full Description | Plays a sound to a player or nearby players at a location.
The sound is played through the player's client just like any other sounds in Minecraft. For a list of all sounds, check https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html Sounds are by default played under their normal sound type (eg zombie sounds are under the type Mobs/Animals). You can optionally instead specify an alternate sound category to use. For a list of all valid sound categories, check https://hub.spigotmc.org/javadocs/spigot/org/bukkit/SoundCategory.html Specifying a player or list of players will only play the sound for each player, from their own location (but will not follow them if they move). If a location is specified, it will play the sound for any players that are near the location specified. If both players and locations are specified, will play the sound for only those players at those locations. Optionally, specify 'custom' to play a custom sound added by a resource pack, changing the sound name to something like 'random.click' Optionally specify a pitch value (defaults to 1.0). A pitch from 0.0 to 1.0 will be deeper (sounds like a demon), and above 1.0 will be higher pitched (sounds like a fairy). Optionally specify a volume value (defaults to 1.0). A volume from 0.0 to 1.0 will be quieter than normal. A volume above 1.0 however will not be louder - instead it will be audible from farther (approximately 1 extra chunk of distance per value, eg 2.0 is 2 more chunks, 5.0 is 5 more chunks, etc.). |
Related Tags | <server.sound_types> Deprecated in favor of server.sound_keys on MC 1.21+.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | noise |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/PlaySoundCommand.java#L32 |
Name | Pose |
Syntax | pose (add/remove/{assume}) [id:<name>] (player/{npc}) (<location>) |
Short Description | Rotates the player or NPC to match a pose, or adds/removes an NPC's poses. |
Full Description | Makes a player or NPC assume the position of a pose saved on an NPC, removes a
pose with a specified ID from the current linked NPC, or adds a pose to the NPC with an ID and a location, although the only thing that matters in the location is the pitch and yaw. |
Related Tags | <NPCTag.has_pose[<name>]> Returns true if the NPC has the specified pose, otherwise returns false.
<NPCTag.pose[<name>]> Returns the pose as a LocationTag with x, y, and z set to 0, and the world set to the first (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/PoseCommand.java#L25 |
Name | Pushable |
Syntax | pushable (state:true/false/{toggle}) (delay:<duration>) (returnable:true/false) |
Short Description | Edits the pushable trait for NPCs. |
Full Description | Enables, disables, toggles, or edits the Pushable trait on the attached NPC. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/PushableCommand.java#L23 |
Name | RateLimit |
Syntax | ratelimit [<object>] [<duration>] |
Short Description | Limits the rate that queues may process a script at. |
Full Description | Limits the rate that queues may process a script at.
If another queue tries to run the same script faster than the duration, that second queue will be stopped. Note that the rate limiting is tracked based on two unique factors: the object input, and the specific script line. That is to say: if you have a 'ratelimit <player> 10s', and then a few lines down a 'ratelimit <player> 10s', those are two separate rate limiters. Additionally, if you have a 'ratelimit <player> 10s' and two different players run it, they each have a separate rate limit applied. Note that this uses game delta tick time, not system realtime. |
Related Tags | None
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/RateLimitCommand.java#L24 |
Name | Sign |
Syntax | sign (type:{automatic}/sign_post/wall_sign) (material:<material>) [<line>|...] [<location>] (direction:north/east/south/west) |
Short Description | Modifies a sign. |
Full Description | Modifies a sign that replaces the text shown on it. If no sign is at the location, it replaces the location with the modified sign.
Specify 'automatic' as a type to use whatever sign type and direction is already placed there. If there is not already a sign there, defaults to a sign_post. Optionally specify a material to use. If not specified, will use an oak sign (unless the block is already a sign, and 'type' is 'automatic'). The direction argument specifies which direction the sign should face. If a direction is not specified, and there is not already a sign there for 'automatic', the direction defaults to south. If a sign_post is placed, you can specify any specific blockface value as the direction, eg "SOUTH_WEST". See also MaterialTag.valid_directions (test in-game for example via "/ex narrate <material[oak_sign].valid_directions>"). |
Related Tags | <LocationTag.sign_contents> Returns a list of lines on a sign.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SignCommand.java#L29 |
Name | Spawn |
Syntax | spawn [<entity>|...] (<location>) (target:<entity>) (persistent) (reason:<reason>) |
Short Description | Spawns a list of entities at a certain location. |
Full Description | Spawn an entity or list of entities at the specified location.
Accepts the 'target:<entity>' argument which will cause all spawned entities to follow and attack the targeted entity. If the persistent argument is present, the entity will not despawn when no players are within range, causing the entity to remain until killed. Optionally specify 'reason:<reason>' (Paper only) to specify the reason an entity is spawning for the 'entity spawns' event, using any reason from https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/CreatureSpawnEvent.SpawnReason.html If the location isn't specified, will use either the linked NPC's location, or the linked player's location. |
Related Tags | <EntityTag.is_spawned> Returns whether the entity is spawned.
<server.entity_types> Returns a list of all entity types known to the server. (...)
<entry[saveName].spawned_entities> returns a list of entities that were spawned.
<entry[saveName].spawned_entity> returns the entity that was spawned (if you only spawned one).
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | summon |
Group | entity |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/SpawnCommand.java#L32 |
Name | Statistic |
Syntax | statistic [<statistic>] [add/take/set] (<#>) (qualifier:<material>/<entity>) |
Short Description | Changes the specified statistic value for a player. |
Full Description | Changes the specified statistic for the player.
For more info on statistics, see https://minecraft.wiki/w/Statistics For statistic names, see https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Statistic.html You can add, take, or set a numeric value to the statistic for the linked player. Works with offline players. Some statistics are unique per a material or entity - for those, use the "qualifier" argument. |
Related Tags | <PlayerTag.statistic[<statistic>]> Returns the player's current value for the specified statistic. (...)
<PlayerTag.statistic[<statistic>].qualifier[<material>/<entity>]> Returns the player's current value for the specified statistic, with the (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/StatisticCommand.java#L27 |
Name | Stop |
Syntax | stop |
Short Description | Stops the current queue. |
Full Description | This will immediately stop the current queue, preventing it from processing any further. |
Related Tags | <queue> to get the current queue.
|
Usage Example |
|
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/StopCommand.java#L16 |
Name | Switch |
Syntax | switch [<location>|...] (state:{toggle}/on/off) (duration:<value>) (no_physics) |
Short Description | Switches state of the block. |
Full Description | Changes the state of a block at the given location, or list of blocks at the given locations.
Optionally specify "state:on" to turn a block on (or open it, or whatever as applicable) or "state:off" to turn it off (or close it, etc). By default, will toggle the state (on to off, or off to on). Optionally specify the "duration" argument to set a length of time after which the block will return to the original state. Works on any interactable blocks, including: - the standard toggling levers, doors, gates... - Single-use interactables like buttons, note blocks, dispensers, droppers, ... - Redstone interactables like repeaters, ... - Special interactables like tripwires, ... - Bells as a special case will ring when you use 'switch' on them, ... - Almost any other block with an interaction handler. This will generally (but not always) function equivalently to a user right-clicking the block (so it will open and close doors, flip levers on and off, press and depress buttons, ...). Optionally specify 'no_physics' to not apply a physics update after switching. |
Related Tags | <LocationTag.switched> Returns whether the block at the location is considered to be switched on. (...)
<MaterialTag.switched> Returns whether a material is 'switched on', which has different semantic meaning depending on the material type. (...)
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | toggle, lever, activate, power, redstone |
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SwitchCommand.java#L37 |
Name | TabList |
Syntax | tablist [add/remove/update] (name:<name>) (display:<display>) (uuid:<uuid>) (skin_blob:<blob>) (latency:<#>) (gamemode:creative/survival/adventure/spectator) (listed:true/false) |
Short Description | Modifies values in the player's tablist. |
Full Description | Adds, removes, or updates a player profile entry in the player's tab-list view.
Using 'add' will add a new entry to the client's player list. 'name' must be specified. 'display' if unspecified will be the same as the name. 'uuid' if unspecified will be randomly generated. 'skin_blob' if unspecified will be a default Minecraft skin. Skin blob should be in format "texture;signature" (separated by semicolon). 'latency' is a number representing the players ping, if unspecified will be 0. 0 renders as full ping, -1 renders an "X", 500 renders orange (3 bars), 1000 renders red (1 bar). 'gamemode' if unspecified will be creative. 'spectator' renders as faded and is pushed below all non-spectator entries. 'listed' determines whether the entry will show up in the tab list, defaults to 'true'. Using 'remove' will remove an entry from the tab list. 'uuid' must be specified. Using 'update' will update an existing entry in the tab list. 'uuid' must be specified. Only 'display', 'latency', 'gamemode', and 'listed' can be updated. Usage of display names that are not empty requires enabling Denizen/config.yml option "Allow restricted actions". Using this tool to add entries that look like real players (but aren't) is forbidden. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/TablistCommand.java#L32 |
Name | Time |
Syntax | time ({global}/player) [<time-duration>/reset] (<world>) (reset:<duration>) (freeze) |
Short Description | Changes the current time in the minecraft world. |
Full Description | Changes the current time in a world or the time that a player sees the world in.
If no world is specified, defaults to the NPCs world. If no NPC is available, defaults to the player's world. If no player is available, an error will be thrown. If 'player' is specified, this will change their personal time. This is separate from the global time, and does not affect other players. When that player logs off, their time will be reset to the global time. Additionally, you may instead specify 'reset' to return the player's time back to global time. If you specify a custom time, optionally specify 'reset:<duration>' to set a time after which the player's time will reset (if not manually changed again before then). Optionally specify 'freeze' to lock a player's time in at the specified time value. |
Related Tags | <WorldTag.time> Returns the relative in-game time of this world.
<WorldTag.time.period> Returns the time as 'day', 'night', 'dawn', or 'dusk'.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/TimeCommand.java#L28 |
Name | Title |
Syntax | title (title:<text>) (subtitle:<text>) (fade_in:<duration>/{1s}) (stay:<duration>/{3s}) (fade_out:<duration>/{1s}) (targets:<player>|...) (per_player) |
Short Description | Displays a title to specified players. |
Full Description | Shows the players a large, noticeable wall of text in the center of the screen.
You can also show a "subtitle" below that title. You may add timings for fading in, staying there, and fading out. The defaults for these are: 1 second, 3 seconds, and 1 second, respectively. Optionally use 'per_player' with a list of player targets, to have the tags in the text input be reparsed for each and every player. So, for example, "- title 'title:hello <player.name>' targets:<server.online_players>" would normally say "hello bob" to every player (every player sees the exact same name in the text, ie bob sees "hello bob", steve also sees "hello bob", etc) but if you use "per_player", each player online would see their own name (so bob sees "hello bob", steve sees "hello steve", etc). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/TitleCommand.java#L30 |
Name | Toast |
Syntax | toast [<text>] (targets:<player>|...) (icon:<item>) (frame:{task}/challenge/goal) |
Short Description | Shows the player a custom advancement toast. |
Full Description | Displays a client-side custom advancement "toast" notification popup to the player(s).
If no target is specified it will default to the attached player. The icon argument changes the icon displayed in the toast pop-up notification. The frame argument changes the type of advancement. As of MC 1.20, an icon is required. Dirt will be used if it is missing. |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | player |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/player/ToastCommand.java#L34 |
Name | ViveMirror |
Syntax | vivemirror [<npc>] [mirror:<vivecraftplayer>] (targets:{player}/<player>|...) |
Short Description | Mirrors a ViveCraftPlayers pose to the npc, once. |
Full Description | Mirrors a ViveCraftPlayers pose to the npc, once.
Ideally should run every tick. Specify a vivecraftplayer that will be mirrored to the NPC. Optionally, specify a list of targets to show the NPCs pose to (targets must be in VR to see the effect). |
Related Tags | None
|
Usage Example |
|
Usage Example |
|
Group | Depenizen |
Requires | Depenizen, ViveCraft |
Source | https://github.com/DenizenScript/Depenizen/blob/master/src/main/java/com/denizenscript/depenizen/bukkit/commands/vivecraft/ViveMirrorCommand.java#L28 |
Name | Vulnerable |
Syntax | vulnerable (state:{true}/false/toggle) |
Short Description | Sets whether an NPC is vulnerable. |
Full Description | Toggles whether an NPC can be hurt or not. |
Related Tags | <NPCTag.invulnerable> Returns whether the NPC is currently invulnerable. (...)
|
Usage Example |
|
Usage Example |
|
Group | npc |
Requires | Citizens |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/VulnerableCommand.java#L21 |
Name | Wait |
Syntax | wait (<duration>) (queue:<name>) (system/{delta}) |
Short Description | Delays a script for a specified amount of time. |
Full Description | Pauses the script queue for the duration specified. If no duration is specified it defaults to 3 seconds.
Accepts the 'queue:<name>' argument which allows the delay of a different queue. Accepts a 'system' argument to delay based on system time (real-world time on a clock). When that argument is not used, waits based on delta time (in-game time tracking, which tends to vary by small amounts, especially when the server is lagging). Generally, do not use the 'system' argument unless you have a specific good reason you need it. |
Related Tags | <QueueTag.speed> Returns the speed of the queue as a Duration. A return of '0' implies it is 'instant'. (...)
|
Usage Example |
|
Usage Example |
|
Synonyms (Search Aid) | delay |
Group | queue |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/queue/WaitCommand.java#L22 |
Name | Weather |
Syntax | weather ({global}/player) [sunny/storm/thunder/reset] (<world>) (reset:<duration>) |
Short Description | Changes the current weather in the minecraft world. |
Full Description | By default, changes the weather in the specified world.
If you specify 'player', this will change the weather in that player's view. This is separate from the global weather, and does not affect other players. When that player logs off, their weather will be reset to the global weather. Additionally, you may instead specify 'reset' to return the player's weather back to global weather. If you specify a custom weather, optionally specify 'reset:<duration>' to set a time after which the player's weather will reset (if not manually changed again before then). Note that 'thunder' is no different from 'storm' when used on a single player. |
Related Tags | <BiomeTag.downfall_type> Deprecated in favor of BiomeTag.downfall_at on 1.19+, as downfall is block-specific now. (...)
<PlayerTag.weather> Returns the type of weather the player is experiencing. This will be different (...)
<WorldTag.has_storm> Returns whether there is currently a storm in this world. (...)
<WorldTag.weather_duration> Returns the duration of storms.
<WorldTag.thundering> Returns whether it is currently thundering in this world.
<WorldTag.thunder_duration> Returns the duration of thunder.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/WeatherCommand.java#L28 |
Name | WorldBorder |
Syntax | worldborder [<world>/<player>|...] (center:<location>) (size:<#.#>) (current_size:<#.#>) (damage:<#.#>) (damagebuffer:<#.#>) (warningdistance:<#>) (warningtime:<duration>) (duration:<duration>) (reset) |
Short Description | Modifies a world border. |
Full Description | Modifies the world border of a specified world or a list of players.
NOTE: Modifying player world borders is client-side and will reset on death, relog, or other actions. Options are: center: Sets the center of the world border. size: Sets the new size of the world border. current_size: Sets the initial size of the world border when resizing it over a duration. damage: Sets the amount of damage a player takes when outside the world border buffer radius. damagebuffer: Sets the radius a player may safely be outside the world border before taking damage. warningdistance: Causes the screen to be tinted red when the player is within the specified radius from the world border. warningtime: Causes the screen to be tinted red when a contracting world border will reach the player within the specified time. duration: Causes the world border to grow or shrink from its current size to its new size over the specified duration. reset: Resets the world border to its vanilla defaults for a world, or to the current world border for players. |
Related Tags | <LocationTag.is_within_border> Returns whether the location is within the world border.
<WorldTag.border_size> Returns the size of the world border in this world.
<WorldTag.border_center> Returns the center of the world border in this world.
<WorldTag.border_damage> Returns the amount of damage caused by crossing the world border in this world.
<WorldTag.border_damage_buffer> Returns the damage buffer of the world border in this world.
<WorldTag.border_warning_distance> Returns the warning distance of the world border in this world.
<WorldTag.border_warning_time> Returns warning time of the world border in this world as a duration.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | world |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/WorldBorderCommand.java#L28 |
Name | Image positions |
Description | Some image-related features take in x and y values, which represent a point on the image.
The values are relative to the upper left corner of the image, which acts as 0,0. If the values are meant to represent the position of a larger object (a shape, an image being drawn onto another image, etc.), they represent the position of that object's upper left corner. |
Group | image |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/core/DrawCommand.java#L57 |
Name | Internal Entity Data |
Description | Each entity in Minecraft has a set of data values that get sent to the client, with each data value being a number id -> value pair.
Denizen allows direct control over that data, as it can be useful for things like setting values that would usually be blocked. Because this is such a direct control that's meant to impose less restriction, there's no limitations/verification on the values being set other than basic type checking. Note as well that as these are raw internal values, they are liable to change between minecraft version updates, especially the numeric IDs. For all possible internal entity data values and their respective ids, see https://github.com/DenizenScript/Denizen/blob/dev/v1_20/src/main/java/com/denizenscript/denizen/nms/v1_20/helpers/EntityDataNameMapper.java#L50. Alternatively, you can use the number id directly instead of the names listed there. For a list of all entity data ids and their values, see https://wiki.vg/Entity_metadata (note that it documents the values that eventually get sent to the client, so the input this expects might be slightly different in some cases). You can input the equivalent denizen objects to have them be auto-converted to the internal types. |
Group | Minecraft Logic |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/entity/FakeInternalDataCommand.java#L24 |
Name | DiscordBotTag |
Prefix | discord@ |
Base Type | ElementTag |
Implements | FlaggableObject |
Identity Format | The identity format for Discord bots is the bot ID (as chosen in discord).
For example: mybot |
Description | A DiscordBotTag is an object that represents a Discord bot powered by dDiscordBot.
This object type is flaggable. Flags on this object type will be stored in: plugins/dDiscordBot/flags/bot_(botname).dat |
Requires | dDiscordBot |
Source | https://github.com/DenizenScript/dDiscordBot/blob/master/src/main/java/com/denizenscript/ddiscordbot/objects/DiscordBotTag.java#L19 |
Name | ImageTag |
Prefix | image@ |
Base Type | ElementTag |
Identity Format | The identity format for ImageTag is a hex encoding of the image's raw bytes, in order.
Each byte is encoded as an individual big-endian hexadecimal pair, like "FF" for byte=255, "00" for byte=0, "0F" for 15, "F0" for 240, ... etc. Alternatively, an image's identity format can be an image id (from images loaded in with Image), see description for more information. |
Description | ImageTags represent an image of any supported format.
They are represented by either a hex encoding of their bytes or their image id, but new images can also be created by providing a MapTag with the following keys: - "width": the new image's width, required. - "height": the new image's height, required. - "background": a ColorTag for the new image's background, optional. For id-based images, the image will directly reference the image loaded in under that id, so for example:
See ImageTag.copy for getting normal image objects from id-based ones. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/objects/core/ImageTag.java#L30 |
Name | <schematic.list> |
Returns | ListTag |
Description | Returns a list of all loaded schematics. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L609 |
Name | <schematic[<name>].block[<location>]> |
Returns | MaterialTag |
Description | Returns the material for the block at the location in the schematic.
An input location of 0,0,0 corresponds to the minimum corner of the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L681 |
Name | <schematic[<name>].blocks> |
Returns | ElementTag(Number) |
Description | Returns the number of blocks in the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L710 |
Name | <schematic[<name>].cuboid[<origin_location>]> |
Returns | CuboidTag |
Description | Returns a cuboid of where the schematic would be if it was pasted at an origin. |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L722 |
Name | <schematic[<name>].exists> |
Returns | ElementTag(Boolean) |
Description | Returns whether the schematic exists. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L633 |
Name | <schematic[<name>].height> |
Returns | ElementTag(Number) |
Description | Returns the height (Y) of the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L645 |
Name | <schematic[<name>].length> |
Returns | ElementTag(Number) |
Description | Returns the length (Z) of the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L657 |
Name | <schematic[<name>].origin> |
Returns | LocationTag |
Description | Returns the origin location of the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L698 |
Name | <schematic[<name>].width> |
Returns | ElementTag(Number) |
Description | Returns the width (X) of the schematic. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/world/SchematicCommand.java#L669 |
Name | <yaml.list> |
Returns | ListTag |
Description | Returns a list of all currently loaded YAML ID's. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L703 |
Name | <yaml[<id>].contains[<path>]> |
Returns | ElementTag(Boolean) |
Description | Returns true if the file has the specified path.
Otherwise, returns false. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L722 |
Name | <yaml[<id>].has_changes> |
Returns | ElementTag(Boolean) |
Description | Returns whether this YAML object has had changes since the last save or load. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L832 |
Name | <yaml[<id>].is_list[<path>]> |
Returns | ElementTag(Boolean) |
Description | Returns true if the specified path results in a list. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L733 |
Name | <yaml[<id>].list_deep_keys[<path>]> |
Returns | ListTag |
Description | Returns a ListTag of all the keys at the path and all subpaths.
Use empty path input to represent the root of the yaml document tree. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L774 |
Name | <yaml[<id>].list_keys[<path>]> |
Returns | ListTag |
Description | Returns a ListTag of all the keys at the path (and not sub-keys).
Use empty path input to represent the root of the yaml document tree. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L803 |
Name | <yaml[<id>].parsed_key[<path>]> |
Returns | ElementTag |
Description | Returns the value from a data key on the YAML document as an ElementTag, ListTag, or MapTag.
Will automatically parse any tags contained within the value of the key, preserving key data structure (meaning, a tag that returns a ListTag, inside a data list, will insert a ListTag inside the returned ListTag, as you would expect). Generally, prefer to use yaml.read. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L743 |
Name | <yaml[<id>].read[<path>]> |
Returns | ObjectTag |
Description | Returns the value from a data key on the YAML document as an ElementTag, ListTag, or MapTag. |
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L760 |
Name | <yaml[<id>].to_json> |
Returns | ElementTag |
Description | Converts the YAML container to a JSON array. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L842 |
Name | <yaml[<id>].to_text> |
Returns | ElementTag |
Description | Converts the YAML container to raw YAML text. |
Generated Example |
|
Source | https://github.com/DenizenScript/Denizen-Core/blob/master/src/main/java/com/denizenscript/denizencore/scripts/commands/file/YamlCommand.java#L852 |