1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
mySocket = socket.tcp() mySocket:bind("*",3784) mySocket:settimeout(0) -- I SET THE TIMEOUT mySocket:listen(0) Client = {} addhook("always","receiveClients") function receiveClients() 	local cl = mySocket.accept() 	if cl then 		table.insert(Client,cl) 	end 	for id, c in pairs(Client) do 		-- This part blocks the socket 		local Line,err = c.socket:receive("*l") -- We get a line respecting the timeout 		if Line then 		elseif err then 			error(err) 		end 		Client[id] = c 	end end
The socket get my external client, but my problem is that it blocks the system (gets frozen) instead of wait the timeout (What should be 0 - means do not wait). And i have to close the external connection to let the game continue working. Some help?