更新3.3
This commit is contained in:
@@ -143,3 +143,63 @@ strType = comp.GetEngineTypeStr()
|
||||
|
||||
|
||||
|
||||
## GetEntityDefinitions
|
||||
|
||||
<span style="display:inline;color:#ff5555">服务端</span>
|
||||
|
||||
method in mod.server.component.entityDefinitionsCompServer.EntityDefinitionsCompServer
|
||||
|
||||
- 描述
|
||||
|
||||
获取实体的命名空间ID及其当前和之前的定义组件群
|
||||
|
||||
- 参数
|
||||
|
||||
无
|
||||
|
||||
- 返回值
|
||||
|
||||
| <div style="width: 4em">数据类型</div> | 说明 |
|
||||
| :--- | :--- |
|
||||
| list(str) | 实体的命名空间ID及其当前和之前的定义组件群的list |
|
||||
|
||||
- 示例
|
||||
|
||||
```python
|
||||
import mod.server.extraServerApi as serverApi
|
||||
comp = serverApi.GetEngineCompFactory().CreateEntityDefinitions(entityId)
|
||||
result = comp.GetEntityDefinitions()
|
||||
```
|
||||
|
||||
|
||||
|
||||
## GetEntityNBTTags
|
||||
|
||||
<span style="display:inline;color:#ff5555">服务端</span>
|
||||
|
||||
method in mod.server.component.entityDefinitionsCompServer.EntityDefinitionsCompServer
|
||||
|
||||
- 描述
|
||||
|
||||
获取实体的NBT标签
|
||||
|
||||
- 参数
|
||||
|
||||
无
|
||||
|
||||
- 返回值
|
||||
|
||||
| <div style="width: 4em">数据类型</div> | 说明 |
|
||||
| :--- | :--- |
|
||||
| dict或None | 实体NBT标签的dict |
|
||||
|
||||
- 示例
|
||||
|
||||
```python
|
||||
import mod.server.extraServerApi as serverApi
|
||||
comp = serverApi.GetEngineCompFactory().CreateEntityDefinitions(entityId)
|
||||
result = comp.GetEntityNBTTags()
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user