[VB6] SeaShadow Changing Client Version For more updated

08/04/2011 13:41 ruancarlosbr#1
Changing Client Version For more updated

This morning I changed the version of Client

but I still have errors when I create the character Name check<< Erro
already done all change and still the same error

Case "7007" 'Character manipulaiton.

Select Case "&H" & Mid(sData, 1, 2)

Case 2 'Character listing.
CharacterList index

Case 1 'Character create.
CreateCharacter index, sData

Case 4 'Character name check.
SprawdzImie index, sData

Case Else
Debug.Print "Unknown 7007 identifier: "; sData








[C -> S][72F7]


04 <<? ................


08 00 <<? ................


58 44 53 44 53 44 53 44 XDSDSDSD........


++++++++++++++++++++++++++++++++++++++++++++++++++ +++++=
[C -> S][7007]


04 ................


08 00 ................


58 44 53 44 53 44 53 44 XDSDSDSD........



error when I click check name of the game will freeze the screen:handsdown:

help :)

Public Function SprawdzImie(index As Integer, DATA As String)

'Should check if character doesn't already exist.
Creator = "0200f7b200000401"
If frmMain.GSocket(index).State = 7 Then
frmMain.GSocket(index).SendData cv_StringFromHex(Creator)
Else
fastErase index
End If

End Function
08/05/2011 00:35 stiifii#2
Let's go analize that step by step.
Quote:
'Should check if character doesn't already exist.
Creator = "0200f7b200000401"
If frmMain.GSocket(index).State = 7 Then
frmMain.GSocket(index).SendData cv_StringFromHex(Creator)
Else
fastErase index
End If

End Function
We are interested:
Creator = "0200f7b200000401"
02- byte which send char create
F7B2 - opcode B2F7
04 - byte (which check name)
01 - byte( send to client this name is valid)

For 1.265 This will be so:
Creator = "020007B000000401"
Need only change opcode to work because this didn't check anything. It's just that there was no freeze or crash.

If you need function which check name if exist or use illegal letters send me pm. I will try to explain you.
Sorry for bad english.
08/05/2011 12:53 ruancarlosbr#3
Creator = "7B00"
Creator = Creator & "0000"
Creator = Creator & "0201"
Creator = Creator & "01" '# of characters
'=========STARTCHARACTER=========

Creator = Creator & DWordFromInteger(PlayerData(index).Chartype)
Creator = Creator & WordFromInteger(Len(PlayerData(index).Charname))
Creator = Creator & cv_HexFromString(PlayerData(index).Charname)
Creator = Creator & ByteFromInteger(PlayerData(index).Volume)
Creator = Creator & ByteFromInteger(PlayerData(index).level)
Creator = Creator & DWordFromInteger(PlayerData(index).Expirience) 'Experience
Creator = Creator & "00000000" 'Experience
Creator = Creator & WordFromInteger(PlayerData(index).Strength)
Creator = Creator & WordFromInteger(PlayerData(index).Intelligence)
Creator = Creator & WordFromInteger(PlayerData(index).AttributePoints) 'Apparently this is attribute points, no SP
Creator = Creator & DWordFromInteger(PlayerData(index).hp)
Creator = Creator & DWordFromInteger(PlayerData(index).MP)
Creator = Creator & "00" 'Marked for deletion
'Creator = Creator & "58270000" 'Minutes till deletion.
Creator = Creator & "0000"
Creator = Creator & "00"
Creator = Creator & "00"


[S -> C][B2F7]


02


01


01


74 07 00 00


09 00


73 73 73 64 73 61 64 73 61


33


05


00 00 00 00 00 00 00 00


18 00


18 00


0C 00


C8 00 00 00


C8 00 00 00


00


00


00
00
05


38 0E 00 00


00


39 0E 00 00


00


3A 0E 00 00


00


30 0E 00 00


00


FB 00 00 00


00


00


ERROR CHARACTER DOES NOT APPEAR

[S -> C][B2F7] For 1.265


02 ................


01 ................


01 ................


74 07 00 00 t...............


09 00 ................


73 73 73 64 73 61 64 73 61 sssdsadsa.......


33 3...............


05 ................


00 00 00 00 00 00 00 00 ................


18 00 ................


18 00 ................


0C 00 ................


C8 00 00 00 ................


C8 00 00 00 ................


00 ................


00 ................


00 ................


00 ................


05 ................


38 0E 00 00 8...............


00 ................


39 0E 00 00 9...............


00 ................


3A 0E 00 00 :...............


00 ................


30 0E 00 00 0...............


00 ................


FB 00 00 00 ................


00 ................


00 ................