mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-09 04:51:49 +00:00
add socket:get_address, serversocket:get_port
This commit is contained in:
parent
3e949bd499
commit
21c76c1b0d
6 changed files with 66 additions and 12 deletions
|
|
@ -59,6 +59,9 @@ socket:is_alive() --> bool
|
|||
|
||||
-- Checks if the connection is present (using socket:send(...) is available).
|
||||
socket:is_connected() --> bool
|
||||
|
||||
-- Returns the address and port of the connection.
|
||||
socket:get_address() --> str, int
|
||||
```
|
||||
|
||||
```lua
|
||||
|
|
@ -80,6 +83,9 @@ server:close()
|
|||
|
||||
-- Checks if the TCP server exists and is open.
|
||||
server:is_open() --> bool
|
||||
|
||||
-- Returns the server port.
|
||||
server:get_port() --> int
|
||||
```
|
||||
|
||||
## Analytics
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue