聊天格式部分
✨喜欢这个插件吗?
你的支持是我们持续维护的动力,点击查看赞助详情
在聊天格式文件夹 chat 的配置中,可以在 chat-format 和 cross-server-format 字段配置具体聊天格式,示例如下:
# 当前子服聊天格式
chat-format:
- type: plain
content: '[聊天] <'
- type: plain
content: '&e%player_name%'
hover-text:
- '&f玩家名称: &e%player_name%'
- '&f所在世界: &e%player_world%'
- '&f所在坐标: &e%player_x%&7, &e%player_y%&7, &e%player_z%'
- '&f经验等级: &e%player_level%'
- ''
- '&b点击私聊玩家'
click:
action: SUGGEST_COMMAND
value: '/msg %player_name% '
- type: plain
content: '> '
- type: player message
# 在其它子服显示的聊天格式,如不设置则与 chat-format 使用同一个格式
# cross-server-format: {}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
这篇文档用于介绍插件内置可用的聊天格式部分。
# 文本 plain
插入一串文本,均支持 MiniMessage 格式和 PAPI 变量。当然你也可以使用更方便的方法设置鼠标悬停显示和点击操作。
- type: plain
# 文本内容,必选
content: '文本内容'
# 鼠标悬停显示文字,可选
hover-text:
- '第一行'
- '第二行'
# 点击操作,可选
click:
# 点击类型,可用以下类型
# OPEN_URL - 打开链接
# OPEN_FILE - 打开文件
# RUN_COMMAND - 执行命令
# SUGGEST_COMMAND - 聊天建议命令
# COPY_TO_CLIPBOARD - 复制到剪贴板
action: SUGGEST_COMMAND
# 点击操作的参数
value: '/msg %player_name% '
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# 玩家消息 player message
插入经过后处理的、玩家发送的聊天消息
- type: player message
1
上次更新: 2026/02/20, 12:40:50