1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2024-06-22 05:03:22 +00:00

Update event docs (#1304)

This commit is contained in:
ouroborus 2023-01-17 13:17:47 -08:00 committed by GitHub
parent 9e1de23f4a
commit 67244b17af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 14 additions and 2 deletions

View File

@ -6,7 +6,7 @@
## Return Values
1. @{string}: The event name.
... @{string}: The arguments passed to the command.
2. @{string}<abbr title="Variable number of arguments">&hellip;</abbr>: The arguments passed to the command.
## Example
Prints the contents of messages sent:

View File

@ -4,6 +4,9 @@
The @{event!redstone} event is fired whenever any redstone inputs on the computer change.
## Return values
1. @{string}: The event name.
## Example
Prints a message when a redstone input changes:
```lua

View File

@ -10,7 +10,7 @@ ## Return Values
2. @{number}: The ID of the task that completed.
3. @{boolean}: Whether the command succeeded.
4. @{string}: If the command failed, an error message explaining the failure. (This is not present if the command succeeded.)
...: Any parameters returned from the command.
5. <abbr title="Variable number of arguments">&hellip;</abbr>: Any parameters returned from the command.
## Example
Prints the results of an asynchronous command:

View File

@ -9,6 +9,9 @@
When this event fires, some parts of the terminal may have been moved or deleted. Simple terminal programs (those
not using @{term.setCursorPos}) can ignore this event, but more complex GUI programs should redraw the entire screen.
## Return values
1. @{string}: The event name.
## Example
Print a message each time the terminal is resized.

View File

@ -8,6 +8,9 @@
@{terminate} will be sent even when a filter is provided to @{os.pullEventRaw}. When using @{os.pullEventRaw} with a filter, make sure to check that the event is not @{terminate}.
## Return values
1. @{string}: The event name.
## Example
Prints a message when Ctrl-T is held:
```lua

View File

@ -4,6 +4,9 @@
The @{turtle_inventory} event is fired when a turtle's inventory is changed.
## Return values
1. @{string}: The event name.
## Example
Prints a message when the inventory is changed:
```lua