Author | Message | Time |
---|---|---|
ChR0NiC | I was using my bot, and I kept getting an error Run Time Error '5': Invalid procedure call or argument So I tried Stealth Bot and the same thing happened so I opened up my source and tried to connect with it and it said. [code] Run Time Error '5': Invalid procedure call or argument [/code] And when it went to show me where the problem is it highlight [code] VersionStatstring = Mid(Data, 16, Len(Data) - 16) [/code] So has there been any changes in BNLS or BNET that I am not aware of ?? Because if yes, I would like to know them ASAP, so I can make the changes on my bot. Thanks ;D | January 22, 2004, 11:38 AM |
iago | It sounds like one of the arguments in that statement is invalid. Usually it's because you go over the end of an array or something. Perhaps battle.net made a change to their statstrings? | January 22, 2004, 12:40 PM |
ChR0NiC | that's what I was thinking......possibly bnet updated their statstring.....I was hoping maybe SkyWing or someone like iago could inform us of this change ;D | January 22, 2004, 12:53 PM |
Soul Taker | If that's what grabs the version from D2 statstrings, it's always caused errors on rare occasions in the popular VB statstring parsing code. You could either handle the error or just get rid of that part. | January 22, 2004, 1:04 PM |
ChR0NiC | I don't think it has to do with D2, cuz if I put a ' in front of it, it won't connect because of a invalid game version, so it has to do with the hashing part I believe..... | January 22, 2004, 1:07 PM |
Arthas | [code] Case &H9 version = Val("&H" & StrToHex(StrReverse(Mid(data, 8, 4)))) version = CLng(version) CheckSum = Val("&H" & StrToHex(StrReverse(Mid(data, 12, 4)))) CheckSum = CLng(CheckSum) ExeInfo = Mid(data, 16, Len(data) - 16) If BNET.Product = "PX2D" Or BNET.Product = "PX3W" Then With pBuffer .InsertDWORD &H0 .InsertBYTE &H2 .InsertDWORD &H1 .InsertDWORD Servers .InsertNTString BNET.Cdkey .InsertNTString BNET.Cdkey2 .SendBNLSPacket &HC End With Else With pBuffer .InsertDWORD Servers .InsertNTString BNET.Cdkey .SendBNLSPacket &H1 End With End If[/code] Mine is ExeInfo = Mid(data, 16, Len(data) - 16). I am getting the same problem. I assume BNLS is working properlly, yet there is a slight mishap with the documentation on the 0x9 packet now. Perhaps if we get an updated documentation, we could connect. Besides, this is a VERY important packet we're dealing with here - it determines whether or not out CD keys get accepted or not 8-). For now, I'm stuck hashing on SC. But hey, oh well. 0x1E isnt THAT bad ;D. Please Skywing help us out! | January 22, 2004, 3:35 PM |
iago | "VersionStatstring" is a really bad name for that variable. And why would iago know? I don't know much at all about making bots or battle.net. | January 22, 2004, 4:44 PM |
Kp | [quote author=Arthas link=board=17;threadid=4843;start=0#msg40647 date=1074785719] For now, I'm stuck hashing on SC. But hey, oh well. 0x1E isnt THAT bad ;D.[/quote] Yes, it is. Starcraft uses SID_AUTH_* (0x50 / 0x51 series) for CDkey verification, and has done so for a long time... :P | January 22, 2004, 6:53 PM |
Stealth | The only currently documented source of runtime error 5 in StealthBot's current release occurs when the user's Windows Regional Settings are not set to US English or similar. I have yet to pinpoint the specific source of this, but because it's a language setting it must have something to do with the fact that I use GetSystemDefaultLangID and GetSystemDefaultLCID in 0x50. Edit: Correction: I hadn't read my support forums before these. Many people had runtime error 5 -- Since this doesn't occur anymore I would assume that Skywing's recent BNLS fix repaired whatever the cause was. | January 22, 2004, 6:54 PM |
UserLoser. | [quote author=Stealth link=board=17;threadid=4843;start=0#msg40674 date=1074797671] The only currently documented source of runtime error 5 in StealthBot's current release occurs when the user's Windows Regional Settings are not set to US English or similar. I have yet to pinpoint the specific source of this, but because it's a language setting it must have something to do with the fact that I use GetSystemDefaultLangID and GetSystemDefaultLCID in 0x50. Edit: Correction: I hadn't read my support forums before these. Many people had runtime error 5 -- Since this doesn't occur anymore I would assume that Skywing's recent BNLS fix repaired whatever the cause was. [/quote] If using Starcraft/Broodwar/Diablo II/Lord of Destruction you should use GetUserDefaultLangID and GetUserDefaultLCID | January 22, 2004, 11:56 PM |