Yes, it was tested without the encryption before hand and the same problems have been happening. We have been trying to rewrite the buffer for a few days now. Between the both of us we are stumpped. Ive probably rewriten it more then a thousand times with no luck.
Tonight I rewrote it to a point where the packets get past the buffer and onto the handler but it gets a subscript out of range error when it trys to set the players hp and mp. Which I dont understand because the value of a new characters hp / mp are both 30/30.
And when the error happens and I debug it highlights the line. I hover the mouse over values of things and it does the popup bubble saying what it equals and there is no problem with what it equals.
So yea, Im totally stummped.
I rewrote the buffer to this to get to the above:
Ps: Sorry for posting this in the wrong section didnt notice there was a specific spot to post winsock problems now.Code:Sub IncomingData(ByVal DataLength As Long) Dim Buffer As String Dim Packet As String Dim A As String Dim Start As Integer frmScourge.Socket.GetData Buffer Buffer = Decrypt(Buffer, EncryptionKey) PlayerBuffer = PlayerBuffer & Buffer Start = InStr(PlayerBuffer, END_CHAR) Do While Start > 0 Start = InStr(PlayerBuffer, END_CHAR) Packet = Mid(PlayerBuffer, 1, Start - 1) PlayerBuffer = Mid(PlayerBuffer, Start + 1, Len(PlayerBuffer)) Start = InStr(PlayerBuffer, END_CHAR) Loop If Len(Packet) > 0 Then Call HandleData(Packet) End If End Sub
Pss.. also just noticed you said in your post "WITHOUT decryption", did you mean without encryption completely or without decrypting the packets? Cause if the packets arnt decrypted nothing will happen.





Reply With Quote