Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Add copy buttons to all
 blocks\n(function() {\n function addCopyButtons() {\n document.querySelectorAll('pre code').forEach(function(codeBlock) {\n if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;\n codeBlock.parentElement.setAttribute('data-copy-added', 'true');\n \n var btn = document.createElement('button');\n btn.textContent = 'Copy';\n btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';\n btn.onmouseover = function() { this.style.opacity = '1'; };\n btn.onmouseout = function() { this.style.opacity = '0.7'; };\n btn.onclick = function() {\n navigator.clipboard.writeText(codeBlock.textContent).then(function() {\n btn.textContent = 'Copied!';\n setTimeout(function() { btn.textContent = 'Copy'; }, 1500);\n });\n };\n codeBlock.parentElement.style.position = 'relative';\n codeBlock.parentElement.appendChild(btn);\n });\n }\n \n addCopyButtons();\n \n // Re-run on dynamic content\n var observer = new MutationObserver(addCopyButtons);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Add Copy Buttons to Code Blocks");
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Force GitHub README to respect dark mode\n(function() {\n var style = document.createElement('style');\n style.textContent = '\n .markdown-body {\n color-scheme: dark light;\n }\n .markdown-body pre { background: #161b22 !important; }\n .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; }\n .markdown-body table th, .markdown-body table td { border-color: #30363d !important; }\n .markdown-body img { background: #0d1117; }\n .markdown-body blockquote { border-left-color: #8b949e; }\n .markdown-body hr { border-color: #30363d; }\n ';\n document.head.appendChild(style);\n})();", "GitHub Dark Mode README Fix"); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Highlight search terms from Google/DuckDuckGo/Bing referrer\n(function() {\n var ref = document.referrer;\n var terms = [];\n \n if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) {\n var url = new URL(ref);\n var q = url.searchParams.get('q') || url.searchParams.get('p');\n if (q) {\n terms = q.split(/\\s+/).filter(function(t) { return t.length > 2; });\n }\n }\n \n if (terms.length === 0) return;\n \n var style = document.createElement('style');\n style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }';\n document.head.appendChild(style);\n \n function highlight(node) {\n if (node.nodeType === 3) { // text node\n var text = node.textContent;\n var found = false;\n terms.forEach(function(term) {\n var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\') + ')', 'gi');\n if (regex.test(text)) {\n found = true;\n var frag = document.createDocumentFragment();\n var parts = text.split(regex);\n parts.forEach(function(part, i) {\n if (i % 2 === 0) {\n frag.appendChild(document.createTextNode(part));\n } else {\n var span = document.createElement('span');\n span.className = 'userscript-highlight';\n span.textContent = part;\n frag.appendChild(span);\n }\n });\n node.parentNode.replaceChild(frag, node);\n }\n });\n } else if (node.nodeType === 1 && node.childNodes) { // element\n var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT'];\n if (!skipTags.includes(node.tagName)) {\n Array.from(node.childNodes).forEach(highlight);\n }\n }\n }\n \n highlight(document.body);\n \n // Re-highlight on dynamic content\n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1 || node.nodeType === 3) highlight(node);\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Highlight Search Terms"); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Strip utm_, fbclid, gclid, etc. from all links on page\n(function() {\n var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content',\n 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid',\n 'ref', 'ref_src', 'source', 'medium', 'campaign'];\n \n function cleanUrl(url) {\n try {\n var u = new URL(url, window.location.origin);\n var changed = false;\n trackingParams.forEach(function(p) {\n if (u.searchParams.has(p)) {\n u.searchParams.delete(p);\n changed = true;\n }\n });\n return changed ? u.toString() : url;\n } catch (e) {\n return url;\n }\n }\n \n function cleanLinks() {\n document.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n \n cleanLinks();\n \n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1) {\n if (node.tagName === 'A') cleanLinks();\n node.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Remove Tracking Parameters from Links"); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Auto-enable theater mode on YouTube\n(function() {\n function tryTheater() {\n var btn = document.querySelector('button[aria-label=\"Theater mode\"], ytd-player #player button[title=\"Theater mode\"]');\n if (btn && !btn.classList.contains('activated')) {\n btn.click();\n }\n }\n \n // Try immediately\n tryTheater();\n \n // Try after navigation (SPA)\n var lastUrl = location.href;\n setInterval(function() {\n if (location.href !== lastUrl) {\n lastUrl = location.href;\n setTimeout(tryTheater, 500);\n }\n }, 1000);\n \n // Also try on player load\n var observer = new MutationObserver(tryTheater);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "YouTube Theater Mode Default"); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Remove or un-stick sticky/fixed headers that block content\n(function() {\n function unstick() {\n document.querySelectorAll('header, nav, [role=\"banner\"], .header, .navbar, .sticky, .fixed-top, [style*=\"position: fixed\"], [style*=\"position:sticky\"]').forEach(function(el) {\n if (el.style.position === 'fixed' || el.style.position === 'sticky' || \n getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') {\n el.style.position = 'static';\n el.style.top = 'auto';\n el.style.zIndex = 'auto';\n }\n });\n }\n \n unstick();\n \n var observer = new MutationObserver(unstick);\n observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] });\n})();", "Kill Sticky Headers"); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally

, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Universal Dark Mode - works on any site\n(function() {\n var enabled = true;\n \n function applyDarkMode() {\n if (!enabled) return;\n \n // Create style element if it doesn't exist\n var style = document.getElementById('universal-dark-mode-style');\n if (!style) {\n style = document.createElement('style');\n style.id = 'universal-dark-mode-style';\n document.head.appendChild(style);\n }\n \n // Dark mode CSS - inverts colors but preserves images/video\n style.textContent = '\n /* Invert everything except media */\n html {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #1a1a2e !important;\n }\n \n /* Restore images, videos, iframes, canvas */\n img, video, iframe, canvas, svg, picture, [style*=\"background-image\"] {\n filter: invert(1) hue-rotate(180deg) !important;\n }\n \n /* Preserve specific elements that should not be inverted */\n .no-dark-mode, .no-dark-mode *,\n [data-theme=\"light\"], [data-theme=\"light\"],\n .ace_editor, .ace_editor *,\n .CodeMirror, .CodeMirror *,\n .monaco-editor, .monaco-editor *,\n .markdown-body pre, .markdown-body pre *,\n .highlight, .highlight *,\n pre code, pre code * {\n filter: none !important;\n }\n \n /* Fix common UI elements */\n .modal, .popup, .dropdown-menu, .tooltip, .popover {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #2d2d44 !important;\n border-color: #444 !important;\n }\n \n /* Scrollbars */\n ::-webkit-scrollbar { background: #1a1a2e !important; }\n ::-webkit-scrollbar-thumb { background: #444 !important; }\n ::-webkit-scrollbar-thumb:hover { background: #555 !important; }\n \n /* Selection */\n ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ';\n }\n \n function removeDarkMode() {\n var style = document.getElementById('universal-dark-mode-style');\n if (style) style.remove();\n }\n \n // Toggle with Alt+Shift+D\n document.addEventListener('keydown', function(e) {\n if (e.altKey && e.shiftKey && e.key === 'D') {\n e.preventDefault();\n enabled = !enabled;\n if (enabled) {\n applyDarkMode();\n console.log('[Universal Dark Mode] Enabled');\n } else {\n removeDarkMode();\n console.log('[Universal Dark Mode] Disabled');\n }\n }\n });\n \n // Apply on load\n applyDarkMode();\n \n // Re-apply on dynamic content\n var observer = new MutationObserver(function(mutations) {\n if (enabled && !document.getElementById('universal-dark-mode-style')) {\n applyDarkMode();\n }\n });\n observer.observe(document.head, { childList: true });\n \n console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle');\n})();", "Universal Dark Mode"); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content

Command Reference: Add

EpiCanard edited this page Mar 31, 2022 · 6 revisions
CommandAliasesSyntaxDescription
adda/svs add [type] [params] <action>Adds an action to a new or existing ServerSign

Parameters

Type

A type is defined in this format: <type>
Only 1 type should be defined per command

Info: If you have PlaceholderApi on your server you can use PAPI variables inside messages

Available types:

TypeAliasesDescription
<server><srv>, <s>The server executes the action as a command
<message><msg>, <m>Player is sent the action as a formatted message
<broadcast><bcast>Action is broadcast as is (with colour codes translated) to the server as a message
<blank><bl>Player is sent the action as an unformatted message
<chat><say>Spoofs the player typing the action as a message in chat
<addgroup><addg>The player is added to the server group action
<removegroup><remg>, <remgroup>The player is removed from the server group action
<addpermission><addperm>, <addp>The player is permanently given the permission action
<removepermission><remperm>, <remp>The player has the permission action permanently revoked
<canceltasks><ctasks>, <canceltask>Removes all queued ServerSigns tasks for the player that MATCH the regular expression pattern action
The regex pattern action can be empty, in which case all queued tasks for the player are removed.

Params

A parameter (param) is defined in this format: [<ParamId>:<Value>]
Multiple different parameters can be defined in 1 command, but only 1 of each parameter type can be provided.

Available params:

ParamIdValuesDescription
dinteger (append optional time values: s|m|h|d|w|mo)Set a delay in seconds (or specified time value) for the command's execution
ppermission string(s), separated by |Set permission(s) to be temporarily granted to the player during command execution
ap"true" or "false"Set whether this task should be immediately persisted to the disk (set to true for important tasks that should never be lost)
click"left", "right", or "both"Set which type clicks will trigger this command's execution

Action

The string value that is used in the execution of this task.

If the action is a player command, and the first character is an asterisk (*), then the player will execute the command as if they are a server operator.

The following special parameters are replaced in the action string:

ParamReplaced by
<player>username of the player that clicked the sign
<name>username of the player that clicked the sign
<nick>the player's Essentials nickname
<group>name of the player's group
<uuid>the player's uuid
<r:x-y >a random number between x and y
<signLoc>the sign's location in the format world,x,y,z
Requires the ServerSign to be looped
<loopCount>the current loop count
<loopsLeft>number of loops remaining
Requires the ServerSign to have a use limit of >0
<usesLimit>the uses limit of the ServerSign
<usesTally>the tally of current uses
<usesLeft>number of uses remaining

IF Statements

A conditional IF statement is defined in this format: <if> [!]conditional operator key:parameters

Only 1 operator key & parameter pair can be defined per statement; an operator key must always be given, parameters may be required (depending on the operator)

Even if no parameters are provided, the ':' separator must be present at the end of the operator key.

Prefixing an operator key with ! will make that conditional check negative, so it will execute its block if the condition is FALSE rather than TRUE.

This statement should be concluded with an <endif> statement, although it is not strictly required.

Available Conditional Operators:

Operator KeyParametersCondition
hasPermpermission nodeThe player must have the specified permission node
isOpnoneThe player must be a server operator
loopIsinteger representing the loop numberThe current loop must be as specified
randompercentage in the format <number>%The specified percentage chance
usesTallyIsinteger representing the uses tallyThe uses tally must be as specified
isBefore13 character long date/time (*see below)It must be before the specified date/time
isAfter13 character long date/time (*see below)It must be after the specified date/time
checkOption<ID>=<value>[|<value>|...] (^see below)The player must have chosen one of the specified answers
onlinePlayers<operator><amount> (~see below)The number of players on the server must match the statement
nearbyPlayers<radius><operator><amount> (~see below)There must be <amount> players within <radius> blocks
placeholder%<placeholder_key>%=<value>[|<value>|...]
or %<placeholder_key>%[<|>]<value> ($see below)
The comparison of %<placeholder_key>% with <value> must be valid
(More info see PlaceholderApi)
scoreboard:hasTeamhasTeam=<value>[|<value>|...]Verify that the player has joined one of the teams that match <value>
  • * Please see the "timelimit" command reference further down for a detailed explanation of the date & time format
  • ^ An 'option menu' must be present on the ServerSign, where 'ID' is the menu's identifier & 'value'(s) are answer labels
  • ~ The <operator> parameter can be either '>' '<' or '=' and should be an integer
  • $ The operator can be either '>' '<' or '='. If operator is '>' or '<' should be a number else can be any value

ENDIF Statements

A conditional ENDIF statement is defined in this format: <endif>

This statement should follow an <if> statement, and defines the scope of the aforementioned IF statement.

RETURN Statements

A conditional RETURN statement is defined in this format: <return>

This statement should be used within the scope of an <if> statement

Once this statement is reached, the ServerSign will stop executing commands until the next interaction.

Examples

Standard Examples

/svs add \<server> say This command is executed by console
/svs add *say This command is executed by the player as if they're an op
/svs add \[p:bukkit.command.say\] say This command is executed by the player with bukkit.command.say granted
/svs add say This command is executed by the player as if they typed it themselves
/svs add \<msg> This message is sent to the player with the plugin prefix
/svs add \<m> This message is sent to the player, with a random number here: \<r:1-100>
/svs add \<bcast> This message is broadcast to the whole server, and was executed by \<player>
/svs add \<blank> This message is sent to the player without any prefixes pre-applied formatting
/svs add \[d:10\] *say This command is executed by the player as if they're an op, 10 seconds after activation
/svs add \[d:5m\] \[p:bukkit.command.say\] say This command is executed by the player with perms granted, 5 minutes after activation
/svs add \[click:left\] say This command is only executed when the ServerSign is left clicked
/svs add \[ap:true\] say This command is immediately persisted to disk (entirely unnecessary for this command!)
/svs add \<addGroup> group_name
/svs add \<remPermission> permission.node
/svs add \<remGroup> \<group>
/svs add \<server> pex user \<uuid> group set group_name
/svs add \[p:bukkit.command.say|bukkit.command.stop\] say This command grants the player 2 permissions during execution
/svs add \[d:15s\] \[click:left\] \[ap:true\] *say This command has a 15s delay, is left-click activated, and is always persisted
/svs add \[d:5m\] \[ap:true\] \<addGroup> group_name
/svs add \[click:both\] \<addPermission> permission.node

Conditional Examples

/svs add \<if> hasPerm:permission.node.example
/svs add \<msg> This message is only sent if the player has the permission permission.node.example
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above condition
/svs add \<if> random:15%
/svs add \<msg> This message is only sent 15% of the time
/svs add \<return>
/svs add \<endif>
/svs add \<msg> This message is sent the remaining 85% of the time
/svs add \<if> usesTallyIs:99
/svs add \<msg> This message is sent to the 100th user of this ServerSign
/svs add \<endif>
/svs add \<if> usesTallyIs:499
/svs add \<msg> This message is sent to the 500th user of this ServerSign
/svs add \<endif>
/svs add \<msg> This message is always sent to the player regardless of the above conditions
/svs add \<if> checkOption:question1=answer1
/svs add \<msg> This message is sent to the player if their answer for 'question1' is 'answer1'
/svs add \<endif>
/svs add \<if> checkOption:question2=answer1|answer2
/svs add \<msg> This message is sent to the player if their answer for 'question2' is 'answer1' or 'answer2'
/svs add \<endif>
/svs add \<if> placeholder:%player_name%=Exloki|Caliber50|EpiCanard
/svs add \<msg> Hello, your name is %player_name% !
/svs add \<endif>
/svs add \<if> placeholder:%player_level%>10
/svs add \<msg> Your level is higher than 10
/svs add \<endif>
/svs add \<if> scoreboard:hasTeam=Blue|Green
/svs add \<msg> This message is sent to the player if he is in team Blue or Green
/svs add \<endif>

Clone this wiki locally