Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21297

[HELP] Winsock problem. Please help me

$
0
0
Hi guys,

I have a game server, that people can connect using winsock indexes. But in another section of the game, the user get disconnect of Winsock Index 1, and get connected to Winsock Index 2

For example:

Before closing Winsock Index 1 for accept new users, I would like to CHECK if the same IP that was connected to Winsock INDEX 1 is connected to another winsock index.

Why do I want it?

I want to do it because I need to check if that IP, for sure, is not connected to another Winsock Index

Basically, I want to check if the IP still conected to any Winsock Index.

The code I use to kill sockets

Code:

Public Sub CleanDeadSockets()

Dim intX As Integer

For intX = 1 To 100
    If wsbroker(intX).State = 8 Then
        wsbroker(intX).Close
    End If
   
Next intX

End Sub

If you can, help me, please.

Thank you.

Viewing all articles
Browse latest Browse all 21297

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>