Skip to content

Commit e073e80

Browse files
twoone-3ShrBox
authored andcommitted
chore: polish the docs
LLSE -> LSE more tips
1 parent 065ce36 commit e073e80

File tree

8 files changed

+25
-21
lines changed

8 files changed

+25
-21
lines changed

docs/apis/DataAPI/OtherData.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
Provides some other common data processing interfaces. You can use and expand by yourself.
44

5+
Note that data is an empty class and the functions are all static functions.
6+
57
### Convert Variable to JSON String
68

79
`data.toJson(var[,space])`

docs/apis/DataAPI/OtherData.zh.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
提供一些其他的常用数据处理接口。你可以自行使用并拓展。
44

5+
注意data是一个空类,函数都是静态函数。
6+
57
### 变量转换为JSON字符串
68

79
`data.toJson(var[,space])`

docs/apis/LanguageSupport.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
# 📋 LLSE - Multi development Language Support
1+
# 📋 LSE - Multi development Language Support
22

33
## 🌏 Current Status
44

5-
With the support of the [ScriptX](https://github.com/Tencent/ScriptX) project, LLSE adapts to multiple development languages using the same set of source code.
5+
With the support of the [ScriptX](https://github.com/Tencent/ScriptX) project, LSE adapts to multiple development languages using the same set of source code.
66
At the same time, the API remains consistent, allowing various languages to share the same development document. It greatly reducing maintenance difficulties.
77

8-
Currently, LLSE supports writing plugins in the following languages:
8+
Currently, LSE supports writing plugins in the following languages:
99

1010
| Language backend | Remarks |
1111
| ---------------- | ------------------------------------------------------------------------------ |
@@ -36,7 +36,7 @@ Currently, LLSE supports writing plugins in the following languages:
3636

3737
## Node.js support description
3838

39-
- LLSE makes it possible to work in embedded mode by implementing the Node.js starter code itself, and isolates the execution environment for different plugins
39+
- LSE makes it possible to work in embedded mode by implementing the Node.js starter code itself, and isolates the execution environment for different plugins
4040
- Created interface to implement programmic support for npm. Support installing third-party extension dependencies via package.json
4141

4242
#### **Node.js Plugin Development**
@@ -51,7 +51,7 @@ Currently, LLSE supports writing plugins in the following languages:
5151
- After the plugin is finish, package `package.json` and all the plugin source code into a zip archive and **change the file name suffix to .llplugin**
5252
- The `node_modules` directory should not be packed in the archive
5353
- Distribute the **.llplugin** file as a plugin. When installing the plugin, just place this file directly into the plugins directory
54-
- LLSE will automatically recognize the **.llplugin** file when BDS launch, extract it to the `plugins/nodejs/<PluginName>` directory, and automatically execute `npm install` in the directory to install the dependency packages. No manual intervention is needed for the whole process
54+
- LSE will automatically recognize the **.llplugin** file when BDS launch, extract it to the `plugins/nodejs/<PluginName>` directory, and automatically execute `npm install` in the directory to install the dependency packages. No manual intervention is needed for the whole process
5555

5656

5757

@@ -69,7 +69,7 @@ Currently, LLSE supports writing plugins in the following languages:
6969
#### **Python Multi-File Plugin Development**
7070

7171
- For formal Python plugins, this method is highly recommended. Multi-file plugins support all full Python features.
72-
- LLSE uses the `pyproject.toml` project file for metadata storage (similar to `package.json` in Node.Js). This project file is recommended to be automatically generated using PDM package manager ([pdm-project/pdm](https://github.com/pdm-project/pdm)), which supports modern project features to facilitate plugin project creation and maintenance.
72+
- LSE uses the `pyproject.toml` project file for metadata storage (similar to `package.json` in Node.Js). This project file is recommended to be automatically generated using PDM package manager ([pdm-project/pdm](https://github.com/pdm-project/pdm)), which supports modern project features to facilitate plugin project creation and maintenance.
7373

7474
##### **The turtorial for Python plugins development: **
7575
1. First, install Python 3.10.9
@@ -94,9 +94,9 @@ Currently, LLSE supports writing plugins in the following languages:
9494
To be fair, the quality and maintenance of CPython's code is in a somewhat worrisome state. Given below are some problems to be aware of when developing Python plugins, many of which are caused by bugs in CPython itself:
9595

9696
1. Do not use `threading`, `asyncio` and other features for the time being
97-
- LLSE uses CPython's sub-interpreter as the core unit of engine scheduling, but CPython itself has long had bad support for the sub-interpreter, and there are many bugs that are hard to explain. The GIL api that is currently used for these mechanisms does not take into account the existence of sub-interpreters, so deadlocks and crashes will occur once they are used.
97+
- LSE uses CPython's sub-interpreter as the core unit of engine scheduling, but CPython itself has long had bad support for the sub-interpreter, and there are many bugs that are hard to explain. The GIL api that is currently used for these mechanisms does not take into account the existence of sub-interpreters, so deadlocks and crashes will occur once they are used.
9898
- Developers with parallel computing needs can temporarily use `multiprocess` to parallelize multiple processes.
99-
- Python 3.12 is scheduled to have targeted fixes for sub-interpreter and GIL-related bugs, and LLSE will adapt CPython 3.12 to address this issue after its release.
99+
- Python 3.12 is scheduled to have targeted fixes for sub-interpreter and GIL-related bugs, and LSE will adapt CPython 3.12 to address this issue after its release.
100100
2. `sys.stdin` is disabled for all Python engines
101101
- This is another CPython bug, see https://github.com/python/cpython/issues/83526 for details
102102
- In addition, even if the CPython engine is not loaded in the above case, there will be a problem of stdin grabbing, causing some tools that use the input redirection to fail

docs/apis/LanguageSupport.zh.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636

3737
## Node.js 支持说明
3838

39-
- LLSE 通过自行实现 Node.js 启动代码,使其可以在嵌入式模式下工作,并实现了不同插件的执行环境隔离
39+
- LSE 通过自行实现 Node.js 启动代码,使其可以在嵌入式模式下工作,并实现了不同插件的执行环境隔离
4040
- 自行编写接口实现了对 npm 的 programmic 支持。支持通过 package.json 安装第三方扩展依赖包
4141

4242
#### **Node.js 插件开发方法**
@@ -64,12 +64,12 @@
6464

6565
- 为了方便不熟悉Python的开发者快速上手,我们提供了一种简单的 Python 插件支持:单文件插件。
6666
- 单文件插件类似QuickJs和Lua插件。只要编写单个.py文件作为插件,将插件直接放置到 plugins目录中,在开服时就会被加载运行
67-
- 单文件插件缺点:不支持插件元数据储存、不支持源码分文件、不支持pip第三方包。单文件插件仅用于开发者熟悉LLSE的Python环境,或者开发非常简易的插件而使用。
67+
- 单文件插件缺点:不支持插件元数据储存、不支持源码分文件、不支持pip第三方包。单文件插件仅用于开发者熟悉LSE的Python环境,或者开发非常简易的插件而使用。
6868

6969
#### **Python 多文件插件开发方法**
7070

7171
- 对于大型、正式的Python插件,强烈建议使用此方法进行开发。多文件插件支持所有完整的Python特性。
72-
- LLSE 使用`pyproject.toml` 项目文件进行元数据储存(类似 Node.Js 的`package.json`)。此项目文件推荐使用支持现代项目特性的 PDM 包管理器([pdm-project/pdm](https://github.com/pdm-project/pdm))自动生成,以便于进行插件项目的创建和维护。
72+
- LSE 使用`pyproject.toml` 项目文件进行元数据储存(类似 Node.Js 的`package.json`)。此项目文件推荐使用支持现代项目特性的 PDM 包管理器([pdm-project/pdm](https://github.com/pdm-project/pdm))自动生成,以便于进行插件项目的创建和维护。
7373

7474
##### **下面是具体的插件开发流程:**
7575

@@ -101,9 +101,9 @@
101101
平心而论,CPython的代码质量和维护状况有些堪忧。下面给出了一些开发Python插件时需要注意的地方,其中有不少都是由CPython本身的Bug引起的:
102102

103103
1. 暂时不要使用`threading` `asyncio`等特性
104-
- LLSE使用CPython的子解释器作为引擎调度的核心单位,然而CPython自身长期以来对子解释器机制的支持并不完善,存在众多Bug,令人一言难尽。目前上面这些机制所需要使用到的GIL api内部并没有考虑到子解释器的存在,因此一旦使用会发生死锁、崩溃等问题。
104+
- LSE使用CPython的子解释器作为引擎调度的核心单位,然而CPython自身长期以来对子解释器机制的支持并不完善,存在众多Bug,令人一言难尽。目前上面这些机制所需要使用到的GIL api内部并没有考虑到子解释器的存在,因此一旦使用会发生死锁、崩溃等问题。
105105
- 如果有并行计算需求的开发者可以暂时使用`multiprocess`进行多进程并行
106-
- Python3.12 按计划将对子解释器和GIL相关bug做出针对性的修复,届时LLSE将对CPython3.12进行适配,解决此问题。Py3.12预计在2023年10月份左右推出,请耐心等待
106+
- Python3.12 按计划将对子解释器和GIL相关bug做出针对性的修复,届时LSE将对CPython3.12进行适配,解决此问题。Py3.12预计在2023年10月份左右推出,请耐心等待
107107
2. 所有Python引擎的`sys.stdin`被禁用
108108
- 这是另外一个CPython的bug,具体详见:https://github.com/python/cpython/issues/83526
109109
- 另外,即使不是上述情况下加载的CPython引擎,也会出现抢夺stdin的问题,导致部分使用了输入重定向机制的工具失效

docs/apis/NbtAPI/NBT.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This provides scripts with the ability to manipulate the **NBT** data type. **NB
99

1010
In the game, a node called **NBT tag** is used to identify an item of NBT data. A variety of data types such as ordinary data, List, Compound, etc. can be stored in NBT tags.
1111

12-
In LeviLamina ScriptEngine, each NBT data type has its corresponding data type, and we collectively call them "NBT objects".
12+
In LegacyScriptEngine, each NBT data type has its corresponding data type, and we collectively call them "NBT objects".
1313
The comparison of the LLSE type with the NBT data type is as follows:
1414

1515
| NBT Data Type | Corresponding NBT Object Type | Type Description (Wiki) |

docs/apis/NbtAPI/NBT.zh.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
游戏中,使用被称为 **NBT标签 **的节点来标识一项NBT数据。NBT标签中可以储存普通数据、List、Compound 等多种数据类型。
1111

12-
在LeviLamina ScriptEngine中,每种NBT数据类型都有其对应的数据类型,我们统称他们为「NBT对象」。
12+
在LegacyScriptEngine中,每种NBT数据类型都有其对应的数据类型,我们统称他们为「NBT对象」。
1313
脚本引擎类型与NBT数据类型的对照如下:
1414

1515
| NBT数据类型 | 对应的NBT对象类型 | 类型说明(来自MC Wiki) |

docs/apis/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
# Overview of LLSE Plugin Development
1+
# Overview of LSE Plugin Development
22

33
## ⛳ Start
44

5-
`LeviLamina ScriptEngine` hereinafter referred to as **LLSE** is an official server for Bedrock Edition `Bedrock Dedicated Server` hereinafter referred to as **BDS** plugin framework, providing powerful cross-language script plug-in support and stable development API support.
5+
`LegacyScriptEngine` hereinafter referred to as **LSE** is an official server for Bedrock Edition `Bedrock Dedicated Server` hereinafter referred to as **BDS** plugin framework, providing powerful cross-language script plug-in support and stable development API support.
66

7-
> Welcome to LLSE's plug-in development!
7+
> Welcome to LSE's plug-in development!
88
9-
From here, you will gradually become familiar with the basic elements and processes of LLSE plug-in development.
9+
From here, you will gradually become familiar with the basic elements and processes of LSE plug-in development.
1010

11-
Before engaging with development, you need to have a systematic understanding of LLSE. The documentation here, first of all, will help you establish a general knowledge framework.
11+
Before engaging with development, you need to have a systematic understanding of LSE. The documentation here, first of all, will help you establish a general knowledge framework.
1212
Familiarize yourself with them first, this will be a very important part of your learning development process.
1313

1414

docs/apis/README.zh.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## ⛳ 放在前面
44

5-
`LeviLamina ScriptEngine`(以下简称**LLSE**/**脚本引擎**)是一个基岩版官方服务端 `Bedrock Dedicated Server`(以下简称**BDS**)的插件框架,提供强大的跨语言脚本插件支持能力和稳定的开发API支持。
5+
`LegacyScriptEngine`(以下简称**LSE**/**脚本引擎**)是一个基岩版官方服务端 `Bedrock Dedicated Server`(以下简称**BDS**)的插件框架,提供强大的跨语言脚本插件支持能力和稳定的开发API支持。
66

77
> 欢迎参与到脚本引擎的插件开发中来!
88

0 commit comments

Comments
 (0)