Valhalla Legends Forums Archive | Battle.net Bot Development | Chat DataArrival

AuthorMessageTime
Yegg
I have a very quick question.
In most Chat Clients for their DataArrival, you have something like this,
[code]Private Sub Winsock2_DataArrival(ByVal bytesTotal As Long)
    'Battle.net Data Arrival
    Dim strTmp As String
    Winsock2.GetData strTmp, vbString
    Battlenet.ParseData strTmp
End Sub[/code]
(I took this out of VaporBot) in Python I understand how to put this code together, my only problem is, what is this vbString? Is this needed in Python? In the entire code of VaporBot and a few other Chat Clients I couldn't find anything that created strTmp. I'm guessing that vbString does something to it?[code][/code]
January 8, 2005, 6:53 PM
shadypalm88
[quote author=Yegg link=topic=10144.msg94662#msg94662 date=1105210415]what is this vbString?[/quote]vbString is a constant that is passed to the Winsock object's GetData routine, telling it to retrieve the data into a string.

As for "anything that created strTmp", it's allocated on the line above it (Dim strTmp As String) and filled with data from the socket on the line in question (Winsock2.GetData strTmp, vbString).
January 8, 2005, 6:59 PM
bethra
hehehe Yes, trying to do conversions between languages that you are unfamiliar with is a bitch!

wow, hehe, I had a hard time doing so with VB6 and C++.  I don't know much about Python, I've heard of it, and read somethings about it, but its probably more complex like C++ than VB?


A good reference to use when you are trying to convert something from VB is the MSDN Library.  Just search for whatever your not quite sure it is.

If you have the actual software version of it, then use that.  Else you can use the online version, it is more updated and extensive I believe.

msdn.microsoft.com/library

is the site home url I believe.
January 15, 2005, 12:20 AM

Search