Skip to content

Commit 462a11d

Browse files
committed
docs: fix error
1 parent 7c5f975 commit 462a11d

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

docs/apis/GameAPI/Player.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -714,11 +714,11 @@ For more usage of container objects, please refer to [Container Object API Docum
714714

715715
#### Modify the Player’s Respawn Coordinates
716716

717-
`mc.setRespawnPosition(pos)`
718-
`mc.setRespawnPosition(x,y,z,dimid)`
717+
`pl.setRespawnPosition(pos)`
718+
`pl.setRespawnPosition(x,y,z,dimid)`
719719

720720
- Parameters:
721-
- pos : `IntPos`
721+
- pos : `IntPos` or `FloatPos`
722722
Respawn coordinates (or use x, y, z, dimid to determine respawn position)
723723
- Return value: Whether the modification was successful.
724724
- Return value type: `Boolean`

docs/apis/GameAPI/Player.zh.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -877,23 +877,23 @@
877877

878878
#### 修改玩家的重生坐标
879879

880-
`mc.setRespawnPosition(pos)`
881-
`mc.setRespawnPosition(x,y,z,dimid)`
880+
`pl.setRespawnPosition(pos)`
881+
`pl.setRespawnPosition(x,y,z,dimid)`
882882

883883
- 参数:
884-
- pos : `IntPos`
884+
- pos : `IntPos``FloatPos`
885885
重生坐标(或者使用x, y, z, dimid来确定重生位置)
886886
- 返回值:是否成功修改
887887
- 返回值类型:`Boolean`
888888

889889
- 示例:
890890
- JavaScript
891891
```js
892-
mc.setRespawnPosition(pos);
892+
pl.setRespawnPosition(pos);
893893
```
894894
- Lua
895895
```lua
896-
mc.setRespawnPosition(pos)
896+
pl.setRespawnPosition(pos)
897897
```
898898

899899
#### 给予玩家一个物品

0 commit comments

Comments
 (0)