mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-07 12:01:50 +00:00
add console.get(...) & add 'player' console variable
This commit is contained in:
parent
2e89cc14ee
commit
9c630645b4
4 changed files with 9 additions and 2 deletions
|
|
@ -4,7 +4,7 @@ To work with the command interpreter, use the **console** library.
|
|||
|
||||
When sending a command via the standard console (core:console layout):
|
||||
1. the `allow-cheats` rule is checked
|
||||
2. the `pos.x|y|z`, `entity.id`, `entity.selected` variables are automatically set.
|
||||
2. the `player`, `pos.x|y|z`, `entity.id`, `entity.selected` variables are automatically set.
|
||||
3. the command handler is called - console.submit or the default one.
|
||||
|
||||
The default handler calls console.execute, passing the result to the console.log call.
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
При отправке команды через стандартную консоль (макет core:console):
|
||||
1. проверяется правило `allow-cheats`
|
||||
2. автоматически устанавливаются переменные `pos.x|y|z`, `entity.id`, `entity.selected`.
|
||||
2. автоматически устанавливаются переменные `player`, `pos.x|y|z`, `entity.id`, `entity.selected`.
|
||||
3. вызывается обработчик команд - console.submit или по-умолчанию.
|
||||
|
||||
Обработчик по-умолчанию вызывает console.execute, передавая результат в вызов console.log.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue