mirror of
https://github.com/MightyPirates/OpenComputers.git
synced 2025-09-07 22:27:42 -04:00
Added close()
parent
7c15c38b97
commit
caab2983d7
@ -10,6 +10,8 @@ Callbacks:
|
||||
Returns whether the specified "port" is currently being listened on. Messages only trigger signals when they arrive on a port that is open.
|
||||
- `open(port: number): boolean`
|
||||
Opens the specified port number for listening. Returns `true` if the port was opened, `false` if it was already open.
|
||||
- `close([port: number]): boolean`
|
||||
Closes the specified port (default: all ports). Returns true if ports were closed.
|
||||
- `send(address: string, port: number[, ...]): boolean`
|
||||
Sends a network message to the specified address. Returns `true` if the message was sent. This does *not* mean the message was received, only that it was sent. No port-sniffing for you.
|
||||
Any additional arguments are passed along as data. These arguments must be basic types: nil, boolean, number and string values are supported, tables and functions are not. See [[the text API|API/Text]] for serialization of tables.
|
||||
|
Loading…
x
Reference in New Issue
Block a user