Sends an action bar message to the given player(s).
Examples:
send action bar "Hello player!" to player
Patterns: | |
Since: | 1.4, 2.1.1 (ban reason), 2.5 (timespan) |
Bans or unbans a player or an IP address. If a reason is given, it will be shown to the player when they try to join the server while banned. A length of ban may also be given to apply a temporary ban. If it is absent for any reason, a permanent ban will be used instead. We recommend that you test your scripts so that no accidental permanent bans are applied.
Note that banning people does not kick them from the server. Consider using the kick effect after applying a ban.
Examples:
unban player
ban "127.0.0.1"
IP-ban the player because "he is an idiot"
ban player due to "inappropriate language" for 2 days
Breaks the block and spawns items as if a player had mined it
You can add a tool, which will spawn items based on how that tool would break the block (ie: When using a hand to break stone, it drops nothing, whereas with a pickaxe it drops cobblestone)
Examples:
on right click:
break clicked block naturally
loop blocks in radius 10 around player:
break loop-block using player's tool
loop blocks in radius 10 around player:
break loop-block naturally using diamond pickaxe
Broadcasts a message to the server. Only formatting options supported by console (i.e. colors) are supported. If you need to use advanced chat formatting, send the message to all players instead of broadcasting it.
Examples:
broadcast "Welcome %player% to the server!"
broadcast "Woah! It's a message!"
Cancel Command Cooldown
🔗 Patterns: | - (cancel|ignore) [the] [current] [command] cooldown
- un(cancel|ignore) [the] [current] [command] cooldown
|
Since: | 2.2-dev34 |
Only usable in commands. Makes it so the current command usage isn't counted towards the cooldown.
Examples:
command /nick :
executable by: players
cooldown: 10 seconds
trigger:
if length of arg-1 is more than 16:
# Makes it so that invalid arguments don't make you wait for the cooldown again
cancel the cooldown
send "Your nickname may be at most 16 characters."
stop
set the player's display name to arg-1
Patterns: | - (cancel|clear|delete) [the] drops [of (items|[e]xp[erience][s])]
- (cancel|clear|delete) [the] (item|[e]xp[erience]) drops
|
Since: | 2.4 |
Usable in events: | death, break / mine |
Requirements: | 1.12.2 or newer (cancelling item drops of blocks) |
Cancels drops of items or experiences in a death or block break event. Please note that this doesn't keep items or experiences of a dead player. If you want to do that, use the
Keep Inventory / Experience effect.
Examples:
on death of a zombie:
if name of the entity is "&cSpecial":
cancel drops of items
on break of a coal ore:
cancel the experience drops
Patterns: | - cancel [the] event
- uncancel [the] event
|
Since: | 1.0 |
Cancels the event (e.g. prevent blocks from being placed, or damage being taken).
Examples:
on damage:
victim is a player
victim has the permission "skript.god"
cancel the event
Change: Set/Add/Remove/Delete/Reset
🔗 Patterns: | |
Since: | 1.0 (set, add, remove, delete), 2.0 (remove all) |
A very general effect that can change many
expressions. Many expressions can only be set and/or deleted, while some can have things added to or removed from them.
Examples:
# set:
Set the player's display name to "
%name of player%"
set the block above the victim to lava
# add:
add 2 to the player's health # preferably use 'heal' for this
add argument to {blacklist::*}
give a diamond pickaxe of efficiency 5 to the player
increase the data value of the clicked block by 1
# remove:
remove 2 pickaxes from the victim
subtract 2.5 from {points::%uuid of player%}
# remove all:
remove every iron tool from the player
remove all minecarts from {entitylist::*}
# delete:
delete the block below the player
clear drops
delete {variable}
# reset:
reset walk speed of player
reset chunk at the targeted block Patterns: | - make %living entities% [a[n]] (charged|powered|((un|non[-])charged|(un|non[-])powered)) [creeper[s]]
- (charge|power|(uncharge|unpower)) %living entities%
|
Since: | 2.5 |
Charges or uncharges a creeper. A creeper is charged when it has been struck by lightning.
Examples:
on spawn of creeper:
charge the event-entity
Patterns: | |
Since: | 2.0, 2.2-dev26 (maps and potions) |
Colours items in a given
colour. You can also use RGB codes if you feel limited with the 16 default colours. RGB codes are three numbers from 0 to 255 in the order
(red, green, blue)
, where
(0,0,0)
is black and
(255,255,255)
is white. Armor is colourable for all Minecraft versions. With Minecraft 1.11 or newer you can also colour potions and maps. Note that the colours might not look exactly how you'd expect.
Examples:
dye player's helmet blue
colour the player's tool red
Executes a command. This can be useful to use other plugins in triggers.
Examples:
make player execute command "/suicide"
execute console command "/say Hello everyone!"
Connects a player to another bungeecord server
Examples:
connect all players to "hub"
Patterns: | |
Since: | 2.2-dev37 |
Skips the value currently being looped, moving on to the next value if it exists.
Examples:
loop all players:
if loop-value does not have permission "moderator":
continue # filter out non moderators
broadcast "%loop-player% is a moderator!" # Only moderators get broadcast
Damage/Heal/Repair an entity, or item.
Examples:
damage player by 5 hearts
heal the player
repair tool of player
Delays the script's execution by a given timespan. Please note that delays are not persistent, e.g. trying to create a tempban script with ban player → wait 7 days → unban player
will not work if you restart your server anytime within these 7 days. You also have to be careful even when using small delays!
Examples:
wait 2 minutes
halt for 5 minecraft hours
wait a tick
Execute an effect if a condition is true.
Examples:
on join:
give a diamond to the player if the player has permission "rank.vip"
Drops one or more items.
Examples:
on death of creeper:
drop 1 TNT
Enable/Disable/Reload Script File
🔗 Patterns: | - (enable|load|reload|disable|unload) s(c|k)ript [file] %text%
|
Since: | 2.4 |
Enables, disables, or reloads a script file.
Examples:
reload script "test"
enable script file "testing"
unload script file "script.sk"
Enchant or disenchant an existing item.
Examples:
enchant the player's tool with sharpness 5
disenchant the player's tool
Equips an entity with some given armor. This will replace any armor that the entity is wearing.
Examples:
equip player with diamond helmet
equip player with all diamond armor
Patterns: | - (exit|stop) [trigger]
- (exit|stop) [(1|a|the|this)] (section|loop|conditional)
- (exit|stop) <\d+> (section|loop|conditional)s
- (exit|stop) all (section|loop|conditional)s
|
Since: | unknown (before 2.1) |
Exits a given amount of loops and conditionals, or the entire trigger.
Examples:
if player has any ore:
stop
message "%player% has no ores!"
loop blocks above the player:
loop-block is not air:
exit 2 sections
set loop-block to water
Patterns: | |
Since: | 2.5 |
Requirements: | Paper 1.13 or newer/Spigot 1.14 or newer. Ignition can be stopped on Paper 1.13 or newer. |
Starts the explosion process of a creeper or instantly explodes it.
Examples:
start explosion of the last spawned creeper
stop ignition of the last spawned creeper
Creates an explosion of a given force. The Minecraft Wiki has an
article on explosions which lists the explosion forces of TNT, creepers, etc. Hint: use a force of 0 to create a fake explosion that does no damage whatsoever, or use the explosion effect introduced in Skript 2.0. Starting with Bukkit 1.4.5 and Skript 2.0 you can use safe explosions which will damage entities but won't destroy any blocks.
Examples:
create an explosion of force 10 at the player
create an explosion of force 0 at the victim
Patterns: | |
Since: | 2.2-dev34 |
Feeds the specified players.
Examples:
feed all players
feed the player by 5 beefs
Patterns: | |
Since: | 2.5.1 |
Requirements: | Minecraft 1.15.2+ |
Makes a living entity attack an entity with a melee attack.
Examples:
spawn a wolf at player's location
make last spawned wolf attack player
Patterns: | |
Since: | 2.2-dev21 |
Forces player(s) to respawn if they are dead. If this is called without delay from death event, one tick is waited before respawn attempt.
Examples:
on death of player:
force event-player to respawn
Hide Player from Server List
🔗 Patterns: | - hide %players% (in|on|from) [the] server list
- hide %players%'[s] info[rmation] (in|on|from) [the] server list
|
Since: | 2.3 |
Examples:
on server list ping:
hide {vanished::*} from the server list
Lights entities on fire or extinguishes them.
Examples:
ignite the player
extinguish the player
Keep Inventory / Experience
🔗 Patterns: | - keep [the] (inventory|items) [(and [e]xp[erience][s] [point[s]])]
- keep [the] [e]xp[erience][s] [point[s]] [(and (inventory|items))]
|
Since: | 2.4 |
Usable in events: | death |
Keeps the inventory or/and experiences of the dead player in a death event.
Examples:
on death of a player:
if the victim is an op:
keep the inventory and experiences
Patterns: | - kick %players% [(by reason of|because [of]|on account of|due to) %text%]
|
Since: | 1.0 |
Kicks a player from the server.
Examples:
on place of TNT, lava, or obsidian:
kick the player due to "You may not place %block%!"
cancel the event
Kills an entity. Note: This effect does not set the entity's health to 0 (which causes issues), but damages the entity by 100 times its maximum health.
Examples:
kill the player
kill all creepers in the player's world
kill all endermen, witches and bats
Launch firework effects at the given location(s).
Examples:
launch ball large coloured red, purple and white fading to light green and black at player's location with duration 1
Leash living entities to other entities.
Examples:
leash the player to the target entity
Strike lightning at a given location. Can use 'ligning effect' to create a lightning that does not harm entities or start fires.
Examples:
strike lightning at the player
strike lightning effect at the victim
Patterns: | - load [the] server icon (from|of) [the] [image] [file] %text%
|
Since: | 2.3 |
Requirements: | Paper 1.12.2 or newer |
Loads server icons from the given files. You can get the loaded icon using the
last loaded server icon expression. Please note that the image must be 64x64 and the file path starts from the server folder.
Examples:
on load:
clear {server-icons::*}
loop 5 times:
load server icon from file "icons/%loop-number%.png"
add the last loaded server icon to {server-icons::*}
on server list ping:
set the icon to a random server icon out of {server-icons::*}
Locally Suppress Warning
🔗 Patterns: | - [local[ly]] suppress [the] (conflict|variable save|[missing] conjunction[s]|starting [with] expression[s]) warning[s]
|
Since: | 2.3 |
Suppresses target warnings from the current script.
Examples:
locally suppress conflict warnings
suppress the variable save warnings
Writes text into a .log file. Skript will write these files to /plugins/Skript/logs. NB: Using 'server.log' as the log file will write to the default server log. Omitting the log file altogether will log the message as '[Skript] [<script>.sk] <message>' in the server log.
Examples:
on place of TNT:
log "%player% placed TNT in %world% at %location of block%" to "tnt/placement.log"
Patterns: | - use[s] (old|new|2.1.2|2.2) loops
|
Since: | unknown (2.2) |
Changes loops to emulate given Skript version's behaviour.
Examples:
use old loops
use new loops
Patterns: | |
Since: | 2.2-dev34 |
Forces a player to start/stop flying.
Examples:
make player fly
force all players to stop flying
Patterns: | - make %entities% [(not)] incendiary
- make %entities%'[s] explosion [(not)] (incendiary|fiery)
- make [the] [event(-| )]explosion [(not)] (incendiary|fiery)
|
Since: | 2.5 |
Sets if an entity's explosion will leave behind fire. This effect is also usable in an explosion prime event.
Examples:
on explosion prime:
make the explosion fiery
Makes an entity invulnerable/not invulnerable.
Examples:
make target entity invulnerable
Forces a player to send a message to the chat. If the message starts with a slash it will force the player to use command.
Examples:
make the player say "Hello."
force all players to send the message "I love this server"
Patterns: | |
Since: | 1.0, 2.2-dev26 (advanced features), 2.5.2 (optional sender) |
Requirements: | Minecraft 1.16.4+ for optional sender |
Sends a message to the given player. Only styles written in given string or in
formatted expressions will be parsed. Adding an optional sender allows the messages to be sent as if a specific player sent them. This is useful with Minecraft 1.16.4's new chat ignore system, in which players can choose to ignore other players, but for this to work, the message needs to be sent from a player.
Examples:
message "A wild %player% appeared!"
message "This message is a distraction. Mwahaha!"
send "Your kill streak is %{kill streak::%uuid of player%}%." to player
if the targeted entity exists:
message "You're currently looking at a %type of the targeted entity%!"
on chat:
cancel event
send "[%player%] >> %message%" to all players from player
Patterns: | |
Since: | 2.5.1 |
Requirements: | Minecraft 1.14.2+ |
Opens a written book to a player.
Examples:
open book player's tool to player
Patterns: | |
Since: | 2.0, 2.1.1 (closing), INSERT VERSION (merchant) |
Opens an inventory to a player. The player can then access and modify the inventory as if it was a chest that he just opened.
Examples:
show the victim's inventory to the player
open the player's inventory for the player
Plays a
visual effect at a given location or on a given entity. Please note that some effects can only be played on entities, e.g. wolf hearts or the hurt effect, and that these are always visible to all players.
Examples:
play wolf hearts on the clicked wolf
show mob spawner flames at the targeted block to the player
Patterns: | |
Since: | 2.2-dev28, 2.4 (sound categories) |
Requirements: | Minecraft 1.11+ (sound categories) |
Plays a sound at given location for everyone or just for given players, or plays a sound to specified players. Both Minecraft sound names and
Spigot sound names are supported. Playing resource pack sounds are supported too. The sound category is 'master' by default.
Please note that sound names can get changed in any Minecraft or Spigot version, or even removed from Minecraft itself.
Examples:
play sound "block.note_block.pling" # It is block.note.pling in 1.12.2
play sound "entity.experience_orb.pickup" with volume 0.5 to the player
play sound "custom.music.1" in jukebox category at {speakerBlock}
Patterns: | - hide [all] player [related] info[rmation] [(in|on|from) [the] server list]
- (show|reveal) [all] player [related] info[rmation] [(in|to|on|from) [the] server list]
|
Since: | 2.3 |
Usable in events: | server list ping |
Requirements: | Paper 1.12.2 or newer |
Sets whether all player related information is hidden in the server list. The Vanilla Minecraft client will display ??? (dark gray) instead of player counts and will not show the
hover hist when hiding player info.
The version string can override the ???. Also the
Online Players Count and
Max Players expressions will return -1 when hiding player info.
Examples:
hide player info
hide player related information in the server list
reveal all player related info
Change visibility of a player for the given players. When reveal is used in combination of the
hidden players expression and the viewers are not specified, this will default it to the given player in the hidden players expression.
Note: if a player was hidden and relogs, this player will be visible again.
Examples:
on join:
if {vanished::%player's uuid%} is true:
hide the player from all players
reveal hidden players of {_player}
Poison or cure a creature.
Examples:
poison the player
poison the victim for 20 seconds
cure the player from poison
Patterns: | |
Since: | 2.0, 2.2-dev27 (ambient and particle-less potion effects), 2.5 (replacing existing effect), 2.5.2 (potion effects) |
Apply or remove potion effects to/from entities.
Examples:
apply swiftness 2 to the player
remove haste from the victim
on join:
apply potion of strength of tier {strength.%player%} to the player for 999 days
apply potion effects of player's tool to player
Push entities around.
Examples:
push the player upwards
push the victim downwards at speed 0.5
Set the PvP state for a given world.
Examples:
enable PvP #(current world only)
disable PvP in all worlds
Patterns: | |
Since: | 2.0, 2.2-dev24 (replace in muliple strings and replace items in inventory), 2.5 (replace first, case sensitivity) |
Replaces all occurrences of a given text with another text. Please note that you can only change variables and a few expressions, e.g. a
message or a line of a sign. Starting with 2.2-dev24, you can replace items in a inventory too.
Examples:
replace "- " in {textvar} with "%item%"
replace every "&" with "§" in line 1
# The following acts as a simple chat censor, but it will e.g. censor mass, hassle, assassin, etc. as well:
on chat:
replace all "kys", "idiot" and "noob" with "****" in the message
replace all stone and dirt in player's inventory and player's top inventory with diamond
Makes a function return a value
Examples:
function double(i: number) :: number:
return 2 * {_i}
Patterns: | |
Since: | 2.2-dev37c, 2.5.1 (block data support) |
Makes a player see a block as something it really isn't. BlockData support is only for MC 1.13+
Examples:
make player see block at player as dirt
make player see target block as campfire[facing=south]
Patterns: | - send [the] resource pack [from [[the] URL]] %text% to %players%
- send [the] resource pack [from [[the] URL]] %text% with hash %text% to %players%
|
Since: | 2.4 |
Request that the player's client download and switch resource packs. The client will download the resource pack in the background, and will automatically switch to it once the download is complete. The URL must be a direct download link.
The hash is used for caching, the player won't have to re-download the resource pack that way. The hash must be SHA-1, you can get SHA-1 hash of your resource pack using this online tool.
The resource pack request action can be used to check status of the sent resource pack request.
Examples:
on join:
send the resource pack from "URL" with hash "hash" to the player
Shears or 'un-shears' a sheep. Please note that no wool is dropped, this only sets the 'sheared' state of the sheep.
Examples:
on rightclick on a sheep holding a sword:
shear the clicked sheep
Shoots a projectile (or any other entity) from a given entity.
Examples:
shoot an arrow
make the player shoot a creeper at speed 10
shoot a pig from the creeper
Controls whether or not an entity is silent.
Examples:
make target entity silent
Spawn a creature.
Examples:
spawn 3 creepers at the targeted block
spawn a ghast 5 meters above the player
Patterns: | - (stop|shut[ ]down) [the] server
- restart [the] server
|
Since: | 2.5 |
Stops or restarts the server. If restart is used when the restart-script spigot.yml option isn't defined, the server will stop instead.
Examples:
stop the server
restart server
Patterns: | |
Since: | 2.4 |
Requirements: | Minecraft 1.10.2+, Minecraft 1.11+ (sound categories) |
Stops a sound from playing to the specified players. Both Minecraft sound names and
Spigot sound names are supported. Resource pack sounds are supported too. The sound category is 'master' by default. A sound can't be stopped from a different category.
Please note that sound names can get changed in any Minecraft or Spigot version, or even removed from Minecraft itself.
Examples:
stop sound "block.chest.open" for the player
stop playing sounds "ambient.underwater.loop" and "ambient.underwater.loop.additions" to the player
Patterns: | |
Since: | 2.5.1 |
Requirements: | Minecraft 1.15.2+ |
Makes an entity swing their hand. This does nothing if the entity does not have an animation for swinging their hand.
Examples:
make player swing their main hand
Teleport an entity to a specific location.
Examples:
teleport the player to {homes.%player%}
teleport the attacker to the victim
Patterns: | - reset [the] title[s] [of %players%]
- reset [the] %players%'[s] title[s]
|
Since: | 2.3 |
Resets the title of the player to the default values.
Examples:
reset the titles of all players
reset the title
Sends a title/subtitle to the given player(s) with optional fadein/stay/fadeout times for Minecraft versions 1.11 and above. Note: if no input is given for the title/subtitle or the times,it will keep the ones from the last title sent, use the
reset title effect to restore the default values.
Examples:
send title "Competition Started" with subtitle "Have fun, Stay safe!" to player for 5 seconds
send title "Hi %player%" to player
send title "Loot Drop" with subtitle "starts in 3 minutes" to all players
send title "Hello %player%!" with subtitle "Welcome to our server" to player for 5 seconds with fadein 1 second and fade out 1 second
send subtitle "Party!" to all players
Patterns: | - (close|turn off|de[-]activate) %blocks%
- (toggle|switch) [[the] state of] %blocks%
- (open|turn on|activate) %blocks%
|
Since: | 1.4 |
Toggle the state of a block.
Examples:
# use arrows to toggle switches, doors, etc.
on projectile hit:
projectile is arrow
toggle the block at the arrow
Patterns: | - (allow|enable) (fly|flight) (for|to) %players%
- (disallow|disable) (fly|flight) (for|to) %players%
|
Since: | 2.3 |
Examples:
allow flight to event-player
Creates a tree. This may require that there is enough space above the given location and that the block below is dirt/grass, but it is possible that the tree will just grow anyways, possibly replacing every block in its path.
Examples:
grow a tall redwood tree above the clicked block
Vectors - Rotate Around Vector
🔗 Patterns: | |
Since: | 2.2-dev28 |
Rotates a vector around another vector
Examples:
rotate {_v} around vector 1, 0, 0 by 90
Vectors - Rotate around XYZ
🔗 Patterns: | |
Since: | 2.2-dev28 |
Rotates a vector around x, y, or z axis by some degrees
Examples:
rotate {_v} around x-axis by 90
rotate {_v} around y-axis by 90
rotate {_v} around z-axis by 90 degrees
Patterns: | - (make|let|force) %entities% [to] (ride|mount) [(in|on)] %entities/entity types%
- [(make|let|force) %entities% [to] (dismount|(dismount|leave) (from|of)] [(any|the[ir]|his|her)] vehicle[s])
- [(eject|dismount) (any|the)] passenger[s] (of|from) %entities%
|
Since: | 2.0 |
Makes an entity ride another entity, e.g. a minecart, a saddled pig, an arrow, etc.
Examples:
make the player ride a saddled pig
make the attacker ride the victim
Grant/revoke a user operator state.
Examples:
op the player
deop all players