-
Notifications
You must be signed in to change notification settings - Fork 13
Command Reference: Add
Command | Aliases | Syntax | Description |
---|---|---|---|
add | a | /svs add [type] [params] <action> | Adds an action to a new or existing ServerSign |
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:
Type | Aliases | Description |
---|---|---|
<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. |
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:
ParamId | Values | Description |
---|---|---|
d | integer (append optional time values: s|m|h|d|w|mo) | Set a delay in seconds (or specified time value) for the command's execution |
p | permission 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 |
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:
Param | Replaced 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 |
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 Key | Parameters | Condition |
---|---|---|
hasPerm | permission node | The player must have the specified permission node |
isOp | none | The player must be a server operator |
loopIs | integer representing the loop number | The current loop must be as specified |
random | percentage in the format <number>% | The specified percentage chance |
usesTallyIs | integer representing the uses tally | The uses tally must be as specified |
isBefore | 13 character long date/time (*see below) | It must be before the specified date/time |
isAfter | 13 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:hasTeam | hasTeam=<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
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.
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.
/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
/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>
- Home
- Installation
- Configuration
- Permissions
- Frequently Asked Questions (FAQs)
- Tutorial Videos
-
Command Reference
- Add
- Cancel
- CancelPermission
- Confirmation
- Copy
- Create
- Edit
- Grant
- Hic
- Holding
- Import
- Insert
- List
- LongCommand
- Option
- Pic
- Price-Item
- Reload
- Reload-Config
- Reload-Signs
- Remove
- Reset-All-Cooldown
- Reset-Cooldown
- Reset-Cooldowns
- Select
- Set-Cooldown
- Set-Global-Cooldown
- Set-Loops
- Set-Permissions
- Set-Price
- Set-Uses
- Silent
- Time-Limit
- Void
- XP