Merge docs for 'added startup and shutdown events. fixes #586'

This commit is contained in:
github-actions[bot] committed 2020-12-07 05:12:40 +00:00
1 parent 522d971688
commit fb2602eea8
1 file changed
+7
+7
View File
@@ -3959,6 +3959,13 @@ if it accepts required number of parameters.
Global events will be handled once per app that is with `'global'` scope. With `player` scoped apps, each player instance Global events will be handled once per app that is with `'global'` scope. With `player` scoped apps, each player instance
is responsible independently from handling their events, so a global event may be executed multiple times for each player. is responsible independently from handling their events, so a global event may be executed multiple times for each player.
### `__on_server_starts()`
Event triggers after world is loaded and after all startup apps have started. It won't be triggered with `/reload`.
### `__on_server_shuts_down()`
Event triggers when the server started the shutdown process, before `__on_close()` is executed. Unlike `__on_close()`, it doesn't
trigger with `/reload`.
### `__on_tick()` ### `__on_tick()`
Event triggers at the beginning of each tick, located in the overworld. You can use `in_dimension()` Event triggers at the beginning of each tick, located in the overworld. You can use `in_dimension()`
to access other dimensions from there. to access other dimensions from there.