NetworkServerEvent(ServerID)
Posted: Fri Jan 28, 2011 11:29 pm
Ok, I want obtain events only from selected server and ignore events from other servers. Is it posible to add optional argument to NetworkServerEvent function?
Example:
P.S. On Windows network lib use Async, on Linux EPoll? Is it right?
P.P.S. Sorry for my bad english))
Example:
Code: Select all
ServerID=CreateNetworkServer(#PB_Any,2000)
OtherServerID=CreateNetworkServer(#PB_Any,2001)
Procedure ServerManager(SID)
Repeat
Select NetworkServerEvent(SID)
...
EndSelect
Forever
EndProcedure
CreateThread(@ServerManager(),ServerID) ; This thread process events from first server
CreateThread(@ServerManager(),OtherServerID) ; This thread process events from second server
P.P.S. Sorry for my bad english))