更新3.4API
This commit is contained in:
@@ -474,6 +474,66 @@ fps = comp.GetFps()
|
||||
|
||||
|
||||
|
||||
## GetHostPlayerId
|
||||
|
||||
<span style="display:inline;color:#ff5555">服务端</span><span style="display:inline;color:#7575f9">客户端</span>
|
||||
|
||||
### 服务端接口
|
||||
|
||||
<span id="s0"></span>
|
||||
method in mod.server.extraServerApi
|
||||
|
||||
- 描述
|
||||
|
||||
获取房主的entityId
|
||||
|
||||
- 参数
|
||||
|
||||
无
|
||||
|
||||
- 返回值
|
||||
|
||||
| <div style="width: 4em">数据类型</div> | 说明 |
|
||||
| :--- | :--- |
|
||||
| str | 房主的entityId,若房主未加入则返回None |
|
||||
|
||||
- 示例
|
||||
|
||||
```python
|
||||
import mod.server.extraServerApi as serverApi
|
||||
serverApi.GetHostPlayerId()
|
||||
```
|
||||
|
||||
|
||||
|
||||
### 客户端接口
|
||||
|
||||
<span id="c0"></span>
|
||||
method in mod.client.extraClientApi
|
||||
|
||||
- 描述
|
||||
|
||||
获取房主的entityId
|
||||
|
||||
- 参数
|
||||
|
||||
无
|
||||
|
||||
- 返回值
|
||||
|
||||
| <div style="width: 4em">数据类型</div> | 说明 |
|
||||
| :--- | :--- |
|
||||
| str | 房主的entityId,若房主未加入则返回None |
|
||||
|
||||
- 示例
|
||||
|
||||
```python
|
||||
import mod.client.extraClientApi as clientApi
|
||||
clientApi.GetHostPlayerId()
|
||||
```
|
||||
|
||||
|
||||
|
||||
## GetMinecraftEnum
|
||||
|
||||
<span style="display:inline;color:#ff5555">服务端</span><span style="display:inline;color:#7575f9">客户端</span>
|
||||
|
||||
Reference in New Issue
Block a user