Actions
When player accomplishes the conditions, you can execute a diverse list of actions. You can also use variables in the actions list.
Message
Sends a message to the player.
message: &aGreat %player%! You''ve just received $5000!
Centered Message
Sends a centered message to the player.
centered_message: &c&lWELCOME TO THE SERVER
Console Message
Sends a message to the console.
console_message: %player_name% left the server with IP %player_ip%
JSON Message
Sends a JSON message to the player. These messages allows you to add click and hover events. You can generate JSON messages on this link: https://minecraft.tools/en/json_text.php
json_message: {"text":"Welcome to the server","underlined":true,"color":"red"}
Mini Message
Sends a message in the Mini Message format https://docs.advntr.dev/minimessage/index.html
Only works on Paper 1.19.4+.
mini_message: Welcome to the <b><color:#91ff52>SERVER</color></b>!
Console Command
Executes a command from the console.
console_command: eco give %player% 5000
Player Command
Executes a command from the player.
player_command: warp survival
Player Command as Op
Executes a command from the player as OP. (Not recommended)
player_command_as_op: help
Player Send Chat
Sends a message in chat from the player. You can even execute a command that is not registered.
player_send_chat: &2Hello
player_send_chat: /rewards
Teleport
Teleports the player. Use this format: "teleport: world;x;y;z;yaw;pitch"
teleport: lobby;0;60;0;90;0
Give Potion Effect
Give a potion effect to the player. Use this format:
"give_potion_effect: effect;duration_in_ticks;level;show_particles"
You can find a list of potion effects here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html
give_potion_effect: POISON;120;1;false
Remove Potion Effect
Removes a potion effect from the player. Use "all" to remove all potion effects.
remove_potion_effect: POISON
remove_potion_effect: all
Cancel Event
Whether event should be cancelled or not. Use this format: "cancel_event: true/false"
cancel_event: true
Kick
Kicks the players from the server.
kick: &cWhat are you trying to do?
Play Sound
Plays a sound to the player. Use this format: "playsound: sound;volume;pitch;(optional, location)<x>,<y>,<z>,<world>"
You can find a list of sounds here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html
Use this list instead when using 1.8: https://helpch.at/docs/1.8.8/index.html?org/bukkit/Sound.html
playsound: BLOCK_NOTE_BLOCK_PLING;10;0.1
# Playsound on location
playsound: BLOCK_NOTE_BLOCK_PLING;10;2;100,60,-127,world
Play Sound Resource Pack
Plays a resource pack sound to the player. The format is the same as playsound
action.
playsound_resource_pack: my_custom_sound;10;1
# Playsound on location
playsound_resource_pack: my_custom_sound;10;2;100,60,-127,world
Stop Sound
Stops a sound for a player.
Use stopsound: <sound>
for specific sound. Only works on 1.10+.
Use stopsound: all
for stopping all sounds. Only works on 1.17+.
You can find a list of sounds here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html
stopsound: BLOCK_NOTE_BLOCK_PLING
stopsound: all
Gamemode
Sets a gamemode for the player. Possible gamemodes: CREATIVE, SURVIVAL, ADVENTURE, SPECTATOR
gamemode: CREATIVE
Send to Server
Sends the player to a bungee server.
send_to_server: lobby
Actionbar
Sends an actionbar message to the player. Use this format:
"actionbar: message;duration"
(The duration must be in ticks, 20ticks = 1second) On repetitive events, use a time of 0 for no flickering.
actionbar: &6Welcome to the server;120
Title
Sends a title and subtitle message to the player. Use this format:
"title: fadeIn;stay;fadeOut;title;subtitle"
(The duration of fadeIn, stay and fadeOut must be in ticks, 20ticks = 1second) If you want just a title, or just subtitle write "none"
title: 20;40;20;&6This is a title;none
Damage
Damages the player a specific amount.
damage: 5
Set On Fire
Sets the player on fire for a certain duration in ticks. (20ticks = 1 second)
set_on_fire: 60
Freeze
Freezes the player for a certain duration in ticks. (20ticks = 1 seconds). Only works on 1.17+.
freeze: 300
Heal
Heals the player a specific amount.
heal: 5
Set Food Level
Sets the current food level of the player with a specific amount. Should be between 0 and 20.
set_food_level: 20
Close Inventory
Closes the player opened inventory.
close_inventory
Clear Inventory
Clears the player inventory.
clear_inventory
Wait
Waits X amount of seconds before executing more actions.
- 'message: &a3'
- 'wait: 1'
- 'message: &a2'
- 'wait: 1'
- 'message: &a1'
- 'wait: 1'
- 'message: &aGo!'
Wait Ticks
Waits X amount of ticks before executing more actions. (20ticks = 1 second)
- 'message: &a3'
- 'wait_ticks: 20'
- 'message: &a2'
Remove Item
Removes X amount of items from the player inventory. Use this format:
remove_item: <type>;<amount>;datavalue: <datavalue>;name: <name>;lorecontains: <lore_line>
Datavalue, name and lorecontains attributes are OPTIONAL. Don't use color formatting.
You can also use the CheckItem expansion of PlaceholderAPI (https://github.com/PlaceholderAPI/PlaceholderAPI/wiki/Placeholders#checkitem) to remove items, following this format:
remove_item: %checkitem_remove_,,<...>%
# This will remove x5 Diamonds from the player inventory.
remove_item: DIAMOND;5
Remove Item Slot
Removes X amount of items from a certain slot of the player inventory. Use this format:
remove_item_slot: <slot>;<amount>
remove_item_slot: HAND;1
remove_item_slot: 0;1
Firework
Spawns a firework from the player location. Use this format:
firework: colors:<color1>,<color2> type:<type> fade:<color1>,<color2> <propertyN>:<valueN>
firework: colors:YELLOW,RED type:BALL fade:AQUA power:0
Lightning Strike
Generates a lightning strike effect that does no damage, at certain location. Use this format: lightning_strike: <world>;<x>;<y>;<z>
lightning_strike: %victim_block_world%;%victim_block_x%;%victim_block_y%;%victim_block_z%
Particle
Spawns a particle on the player location. Use this format:
particle: effect:<effect_name> offset:<x>;<y>;<z> speed:<speed> amount:<amount> force:<true/false> (optional)location:<x>;<y>;<z>;<world>
Only works on 1.9+
particle: effect:EXPLOSION_LARGE offset:0.1;0.1;0.1 speed:1 amount:5
Give Item
Gives an item to the player. Use this format: give_item: id:<id>;<property>:<value>;<propertyN>:<valueN>
give_item: id:IRON_HELMET;amount:1;name:&6Basic Helmet
Drop Item
Drops an item in a certain location. Use this format: drop_item: location:<x>,<y>,<z>,<world>;id:<id>;<property>:<value>;<propertyN>:<valueN>
drop_item: location:%block_x%,%block_y%,%block_z%,%block_world%;id:DIAMOND;name:&bUnique Diamond
Set Block
Places a block in a certain location. Use this format: set_block: location:<x>,<y>,<z>,<world>;id:<id>;block_data:<block_data>
. Only works on 1.13+.
set_block: location:50,50,-256,world;id:DIAMOND_BLOCK
Summon
Spawns an entity at a certain location. Use this format: summon: location:<x>,<y>,<z>,<world>;entity:<entity>;<property>:<value>;<propertyN>:<valueN>
summon: location:0,68,0,spawn;entity:SHEEP
Call Event
Executes a "call" event. Use this format:
call_event: <event_name>;%variable1%=<value1>;%variableN%=<valueN>
example:
type: player_command
conditions:
- "%main_command% == /test"
actions:
default:
- "cancel_event: true"
- "message: This is a test message from event 'example'"
- "call_event: example2;%example_variable%=Something"
example2:
type: call
conditions:
- "%example_variable% == Something"
actions:
default:
- "message: This message will be sent only when event 'example2' is called"
Execute Action Group
Executes another action group from the event, randomly. Use this format:
execute_action_group: <group1>:<prob1>;<groupN>:<probN>
where <group>
is the name of a created action group of the event, and <probability>
is the chance of selecting the event (The probabilities don't need to sum 100%).
example:
type: player_command
conditions:
- "%main_command% == /randomfirework"
actions:
default:
- "cancel_event: true"
- "execute_action_group: firework1:70;firework2:30;firework3:30"
firework1:
- "firework: colors:YELLOW,RED type:BALL fade:AQUA power:0"
firework2:
- "firework: colors:BLACK,WHITE type:BURST power:1"
firework3:
- "firework: colors:GREEN,BLUE type:BURST power:1"
Last updated
Was this helpful?