• Welcome to Valhalla Legends Archive.
 

Bnetauth.dll issues

Started by Tazo, March 05, 2006, 07:03 PM

Previous topic - Next topic

Tazo

I am having trouble using the hash function.

Dim RevisionCheck As Long
Dim exeinfo As String
Dim checksum As Long
Dim version As Long
exeinfo = Space(256)
RevisionCheck = z(App.Path & "\StarCraftJ.exe", _
                App.Path & "\storm.dll", App.Path & "\battle.snp", _
                modDeclares.ValueString, version, checksum, exeinfo, "IX86ver2.mpq")
If RevisionCheck = "0" Then
    AddText vbRed, "Failed version check!"
    frmMain.sckBnet.Close
    Exit Sub
End If

Unfortunately, RevisionCheck is returning 0 every time. I'm not sure why. My value string is not the problem. thanks in advance.

Hdx

If I remember correctly, the MPQ info is a long and it's the MPQ number, not the full string.
~-~(HDX)~-~

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Tazo

#2
I dont think it is, I pull it out by

modDeclares.MPQName = Mid(Data, InStr(1, Data, "IX86ver"), Len(Data))
modDeclares.MPQName = Mid(MPQName, 1, 12)

and also its IX86ver4.mpq not 2, but that doesnt matter.. anyways, ive been using the MPQ name for SC/BW and its worked fine.

also::
im pulling out the hashcommand by

Case &H6
                modDeclares.ValueString = Mid(Data, 24, Len(Data) - 2)

Hdx

#3
I'm refering to when passing it to Z()
RevisionCheck = z(App.Path & "\StarCraftJ.exe", _
                App.Path & "\storm.dll", App.Path & "\battle.snp", _
                modDeclares.ValueString, version, checksum, exeinfo, "IX86ver2.mpq")

Should be
RevisionCheck = z(App.Path & "\StarCraftJ.exe", _
                App.Path & "\storm.dll", App.Path & "\battle.snp", _
                modDeclares.ValueString, version, checksum, exeinfo, &H2)



Also I suggest you learn to use a 'debuffer' class. Like this
Helps a lot in keeping ti straight in your mind.
~-~(HDX)~-~

Proud host of the JBLS server www.JBLS.org.
JBLS.org Status:
JBLS/BNLS Server Status

Tazo

#4
Ok, I got it thanks

l2k-Shadow

Quote from: replaced on November 04, 2006, 11:54 AM
I dunno wat it means, someone tell me whats ix86 and pmac?
Can someone send me a working bot source (with bnls support) to my email?  Then help me copy and paste it to my bot? ;D
Já jsem byl určenej abych tady žil,
Dával si ovar, křen a k tomu pivo pil.
Tam by ses povídaj jak prase v žitě měl,
Já nechci před nikym sednout si na prdel.

Já nejsem z USA, já nejsem z USA, já vážně nejsem z USA... a snad se proto na mě nezloběj.

UserLoser

Quote from: Tazo on March 05, 2006, 07:34 PM
I dont think it is, I pull it out by

modDeclares.MPQName = Mid(Data, InStr(1, Data, "IX86ver"), Len(Data))
modDeclares.MPQName = Mid(MPQName, 1, 12)


Data = ...IX86ver1.mpq...
InStr(Data, "IX86ver1.mpq") = 4
MpqName = Mid(Data, 4) = "IX86ver1.mpq..."
MpqName = Mid(MpqName, 1, 12) = "IX86ver1.mpq"
MpqName = "IX86ver1.mpq"

That doesn't get the number and store it into a long variable..all it does is use the crappiest way possible to pull out a string from another string.

Quote from: Tazo on March 05, 2006, 07:34 PM
and also its IX86ver4.mpq not 2, but that doesnt matter.. anyways, ive been using the MPQ name for SC/BW and its worked fine.

By the way, there's more than just one IX86ver MPQ

Joe[x86]

People who don't use packet-reading classes just make me laugh.
Quote from: brew on April 25, 2007, 07:33 PM
that made me feel like a total idiot. this entire thing was useless.

Eric

Quote from: Joe on March 06, 2006, 12:56 AM
People who don't use packet-reading classes just make me laugh.

People who refer to temporary data buffers as "packet-reading classes" make me laugh.

warz

The same pointless topics, arguments and scenarios being played out on these forums for the past several years makes me laugh.

Joe[x86]

Quote from: Lord[nK] on March 06, 2006, 01:06 AM
Quote from: Joe on March 06, 2006, 12:56 AM
People who don't use packet-reading classes just make me laugh.

People who refer to temporary data buffers as "packet-reading classes" make me laugh.

Oh? Well what should it be called, my king?
Quote from: brew on April 25, 2007, 07:33 PM
that made me feel like a total idiot. this entire thing was useless.

MyndFyre

Quote from: Lord[nK] on March 06, 2006, 01:06 AM
Quote from: Joe on March 06, 2006, 12:56 AM
People who don't use packet-reading classes just make me laugh.

People who refer to temporary data buffers as "packet-reading classes" make me laugh.

Note that people typically aren't referring to data buffers themselves as the mechanisms by which meaningful data is read from them.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.