Skip to content

Commit eba9feb

Browse files
committed
🎉 支持1.21.5+
🔧 修改文本格式化逻辑 🔧 格式化代码 ✨ 美化页面 📝 修改README
1 parent f0a1b73 commit eba9feb

4 files changed

Lines changed: 459 additions & 431 deletions

File tree

README.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,19 @@
1010
/summon minecraft:text_display ~0 ~0.5 ~-0.49 {text:'["", {"text":"文本展示实体(Text Display)", "color":"dark_green","bold":true}, "\\n\\n于", {"text":"1.19.4", "italic":true,"color":"dark_blue"}, "版本中加入,为展示", {"text":"大量文本", "bold":true,"color":"gold"}, "提供了新的手段。\\n\\n它支持基本的", {"text":"文本效果", "bold":true,"color":"gold"}, "(", {"text":"颜", "color":"dark_red"}, {"text":"色", "color":"light_purple"}, "、", {"text":"粗体", "bold":true}, "、", {"text":"斜体", "italic":true}, "等),同时提供了许多", {"text":"个性化选项", "bold":true,"color":"gold"}, "(", {"text":"背景颜色", "underlined":true,"color":"light_purple"}, "、", {"text":"文本对齐的方式", "underlined":true,"color":"yellow"}, "、", {"text":"整体的缩放", "underlined":true,"color":"aqua"}, "等),适用于公示信息、展示说明等需要大量文本的场景。"]', brightness:{block:15,sky:15}, background:-1778384896, alignment:"left", see_through:true, width:1f, height:1f, view_range:0.5f}
1111
```
1212

13-
## 说明
13+
从1.12.5开始,文本组件不再使用Json,所以要用下面的命令:
1414

15-
* 将鼠标移动到下面有点点线的文本上,会显示对应的提示信息。
16-
* 如果情况允许,可以仅通过`距离系数`来进行剔除,以减少工作量。
17-
* `文本跨越方块的数量 * 40`可以粗略得出文本的宽度,以供`行宽`参考。
18-
* 不喜欢内置的富文本编辑器?可以在`文本`栏中粘贴外部的富文本(无法保证后续的编辑或生成),或者直接在`命令`栏中修改`text`的值。
19-
* 下载`Unifont`字体可以让`文本`栏的显示效果更加接近实际效果。
15+
```text
16+
/summon minecraft:text_display ~0 ~0.5 ~-0.49 {text:["", {"text":"文本展示实体(Text Display)", "color":"dark_green","bold":true}, "\n\n于", {"text":"1.19.4", "italic":true,"color":"dark_blue"}, "版本中加入,为展示", {"text":"大量文本", "bold":true,"color":"gold"}, "提供了新的手段。\n\n它支持基本的", {"text":"文本效果", "bold":true,"color":"gold"}, "(", {"text":"颜", "color":"dark_red"}, {"text":"色", "color":"light_purple"}, "、", {"text":"粗体", "bold":true}, "、", {"text":"斜体", "italic":true}, "等),同时提供了许多", {"text":"个性化选项", "bold":true,"color":"gold"}, "(", {"text":"背景颜色", "underlined":true,"color":"light_purple"}, "、", {"text":"文本对齐的方式", "underlined":true,"color":"yellow"}, "、", {"text":"整体的缩放", "underlined":true,"color":"aqua"}, "等),适用于公示信息、展示说明等需要大量文本的场景。"], brightness:{block:15,sky:15}, background:-1778384896, alignment:"left", see_through:true, width:1f, height:1f, view_range:0.5f}
17+
```
18+
19+
## 提示
20+
21+
* 将鼠标悬停在画着点点线的文本上,可以获得对应的提示信息。
22+
* `行宽`为文本的最大宽度,单位长度约为`1/40`格。
23+
* `文本`栏中可以粘贴外部富文本,但可能无法正确生成。
24+
* 自带的富文本编辑器可能无法正确显示复杂文本的实际效果。
25+
* 使用`Unifont`字体可以让`文本`栏的预览效果更加接近实际效果。
2026

2127
![使用Unifont字体](img/unifont.png)
2228

0 commit comments

Comments
 (0)