mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-11-20 09:29:44 +00:00
update doc/*/scripting/events.md
This commit is contained in:
parent
6ab161a518
commit
5dd605a4f5
2 changed files with 5 additions and 5 deletions
|
|
@ -137,10 +137,10 @@ function on_world_save()
|
|||
Called before world save.
|
||||
|
||||
```lua
|
||||
function on_world_tick()
|
||||
function on_world_tick(tps)
|
||||
```
|
||||
|
||||
Called 20 times per second
|
||||
Called *tps* times per second
|
||||
|
||||
```lua
|
||||
function on_world_quit()
|
||||
|
|
|
|||
|
|
@ -124,7 +124,7 @@ function on_block_break_by(x: int, y: int, z: int, playerid: int)
|
|||
|
||||
Вызывается при нажатии ЛКМ на блок (в т.ч неразрушимый). Предотвращает разрушение блока, если возвращает `true`
|
||||
|
||||
## События мира
|
||||
## События мира
|
||||
|
||||
События мира для контент-пака прописываются в `scripts/world.lua`
|
||||
|
||||
|
|
@ -141,10 +141,10 @@ function on_world_save()
|
|||
Вызывается перед сохранением мира
|
||||
|
||||
```lua
|
||||
function on_world_tick()
|
||||
function on_world_tick(tps)
|
||||
```
|
||||
|
||||
Вызывается 20 раз в секунду
|
||||
Вызывается *tps* раз в секунду
|
||||
|
||||
```lua
|
||||
function on_world_quit()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue