mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
update events.md
This commit is contained in:
parent
16f2c2fdd2
commit
cace8b8bf0
2 changed files with 25 additions and 0 deletions
|
|
@ -90,6 +90,18 @@ function on_world_quit()
|
|||
|
||||
Called on world close (after saving)
|
||||
|
||||
```lua
|
||||
function on_block_placed(blockid, x, y, z, playerid)
|
||||
```
|
||||
|
||||
Called on block placed by player
|
||||
|
||||
```lua
|
||||
function on_block_broken(blockid, x, y, z, playerid)
|
||||
```
|
||||
|
||||
Called on block broken by player
|
||||
|
||||
## Layout events
|
||||
|
||||
Script *layouts/layout_name.xml.lua* events.
|
||||
|
|
|
|||
|
|
@ -89,6 +89,19 @@ function on_world_quit()
|
|||
```
|
||||
|
||||
Вызывается при выходе из мира (после сохранения)
|
||||
|
||||
```lua
|
||||
function on_block_placed(blockid, x, y, z, playerid)
|
||||
```
|
||||
|
||||
Вызывается после установки блока игроком
|
||||
|
||||
```lua
|
||||
function on_block_broken(blockid, x, y, z, playerid)
|
||||
```
|
||||
|
||||
Вызывается после разрушения блока игроком
|
||||
|
||||
## События макета
|
||||
|
||||
События прописываются в файле `layouts/имя_макета.xml.lua`.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue