方块事件
2024年11月12日小于 1 分钟
方块事件
BLOCK INTERACT 方块交互
当玩家与方块交互时调用的事件
example:
type: block_interact
conditions:
- '%block_x% == 20'
- '%block_y% == 60'
- '%block_z% == 20'
- '%block_world% == lobby'
- '%block% == STONE_BUTTON'
- '%action_type% == RIGHT_CLICK'
actions:
default:
- "message: &aYou''ve received $500!"
- "console_command: eco give %player% 500"
变量
BLOCK BREAK 破坏方块
当玩家破坏方块时调用的事件
example:
type: block_break
conditions:
- '%block_head_texture% != %empty%'
actions:
default:
- 'cancel_event: true'
- "message: &cYou can''t break heads with texture!"
- 'playsound: BLOCK_NOTE_BLOCK_PLING;10;0.1'
BLOCK PLACE 放置方块
当玩家放置方块时调用的事件
example:
type: block_place
conditions:
- '%block_world% == spawn'
actions:
default:
- 'cancel_event: true'
- "message: &cYou can''t place blocks on this world."
- 'playsound: BLOCK_NOTE_BLOCK_PLING;10;0.1'