You all think I'm insane, and will have that thought reinforced after reading this post. You'll live.
Revelation Bot will be a Battle.net Bot that is aimed to make all the features available in the client available through the bot, much like LoRd[nK]'s BBBB. The difference, though, is that I'm placing the core of the bot in an OCX like CleanSlateBot called RevelationBotCore.
RevelationBot
I'm looking to create an easy-to-use, user-friendly, yet attractive bot, that even your little sister could use. This will have the standard features that all bots should have, a configuration form, a queue, etc, yet have more options as well, such as to display ads, download files from BNFTP, and to use BCP plugins.
RevelationBotCore
This will be a collection of User Controls that aim to make Battle.net bot programming as easy as possible, even more than the CSB did. A few features will be a complete BNCS gateway (for lack of a better word) like CSB, an improved picture box control that allows use of PCX files, and in the future SMK files, and even a blocking Winsock.
I'm looking to implement most stuff that DLL's are used for, such as CheckRevision and CDKey decoding, right into the bot.
Wish me luck.
EDIT -
I guess I forgot to say this, but..
This is very likely to be my last endeavor into Battle.net bot programming with Visual Basic, and because of that, I'm going to do my absolute best work on this, revising every piece of code until its pretty and stuff like that, and then relase it open source for all the little people to enjoy! =)
Wow sounds cool. Can't wait to see this. Keep us updated on how it's going! :)
Suffice to say...Battle.net programming is already easy. Your CSB wannabe control would only help a little bit and cut out any fun that battle.net programming even possess anymore. Good job. I think that's a radical revelation in itself.
Joe... you work too hard. :P
Nice encouragment, Networks. Why people get on here to read things and ideas other people cherish and turn to this community for support and help, only to bash and put them down, I'm not quite sure anymore.. As many before your time have said, Networks; Battle.net is a community that will most likely never fade. Although the amount of developers has grown to an immense number, There are still people out there willing to dedicate time and effort to learning and putting back into this same community. Comments like those, however, shoot them down and may possible prevent them from wanting to return here. All I'm saying is, be a little more supportive or productive with your nonsense post's.... Its getting rediculous.
Anyways, Joe. I've perfected the art of VB programming in ways i never thought possible only a year ago. I have designed a method of coding that maintains such stability, It was kind of hard to beleive once I conquered it. As you know, I'm probably the first or one of the veterans for displaying animated banner files. At first, I had my bot actually use the smacker program to divide the frames up and compile the banners into .gif's so i could display them pretty easily. After non-stop searching I've came accross the smacker API, and its so easy it makes me giggle sometimes. If your having any problems painting them onto the form or accessing the API correctly, shoot me a PM...
As far as the bot goes, I think you'll progress pretty easily. All the hashing and encoding functions and whatnot have been ported to visual basic already, although quite sluggish at times, but hey, your bot core relies on an active x control anyways, so I guess you'll have that... Keep us posted, good luck!
Quote from: Networks on December 27, 2005, 11:56 AM
Suffice to say...Battle.net programming is already easy. Your CSB wannabe control would only help a little bit and cut out any fun that battle.net programming even possess anymore. Good job. I think that's a radical revelation in itself.
I disagree. The fun of programming a Battle.net program is making it have original features. Modularization facilitates that.
Quote from: MyndFyre on December 27, 2005, 02:31 PM
Quote from: Networks on December 27, 2005, 11:56 AM
Suffice to say...Battle.net programming is already easy. Your CSB wannabe control would only help a little bit and cut out any fun that battle.net programming even possess anymore. Good job. I think that's a radical revelation in itself.
I disagree. The fun of programming a Battle.net program is making it have original features. Modularization facilitates that.
Funny, I thought the fun of battle.net programming was the challenge that once existed. At least it was that way for me. CSB really doesn't help unless you're tired of creating the same shit connection structure, I still haven't gotten tired of that since I improve it everytime.
I can understand Joe wanting to program something that may be a challenge to himself however I can't understand why he'd make it easier for everyone else in an area that's already so open. Perhaps if it was open source :P.
Maybe because programmers like him already know the run-down on connection procedures and whatnot, just like you. I can honestly say, and I'm sure many of you recognize this as well, since CSB and the number of developers grew so greatly, this place has been more active, more productive, and alot more idea's have come forth. For example, Joe hasn't been here as long as me, yet has probably accomplished more or just as much as I have. Look at his starcraft Cd-key thread. You should be thanking people and idea's like that for still being active in this community... You can hold yourself on high and try to "fight" for some cause that you think may be unfair, but just remember you were in that very same position at some point too.
Quote from: Mesiah / haiseM on December 27, 2005, 02:48 PM
Maybe because programmers like him already know the run-down on connection procedures and whatnot, just like you. I can honestly say, and I'm sure many of you recognize this as well, since CSB and the number of developers grew so greatly, this place has been more active, more productive, and alot more idea's have come forth. For example, Joe hasn't been here as long as me, yet has probably accomplished more or just as much as I have. Look at his starcraft Cd-key thread. You should be thanking people and idea's like that for still being active in this community... You can hold yourself on high and try to "fight" for some cause that you think may be unfair, but just remember you were in that very same position at some point too.
This is why I said, jokingly, that Joe works too hard. Although he can be quite annoying and childish at times, he has gotten a great amount of work accomplished on these forums.
Quote from: Networks on December 27, 2005, 02:33 PM
Funny, I thought the fun of battle.net programming was the challenge that once existed. At least it was that way for me. CSB really doesn't help unless you're tired of creating the same shit connection structure, I still haven't gotten tired of that since I improve it everytime.
Perhaps then we simply have a difference of opinion. For me, the first time I got into making a bot, the challenge wasn't the connection. That was, of course, a hurdle to overcome; however, that wasn't the real draw for me. Instead, I wanted to find new and original things that my bot could do -- for example, I wrote a plugin for my bot that would interface with my clan's website, monitor our members and their aliases, and then update the website with the message "so-and-so was last seen as
alias on the
game-icon on
long date-time." It might not have been as revolutionary as WebBot, for example, but it was something that no other bot had, at least that I could get my hands on.
Quote from: Networks on December 27, 2005, 02:33 PM
I can understand Joe wanting to program something that may be a challenge to himself however I can't understand why he'd make it easier for everyone else in an area that's already so open. Perhaps if it was open source :P.
Why would making it open-source be any better? And why not share his work with the rest of the community? I did so with my first bot -- the .NET binary was documented and provided to anyone who wanted to use it. In many ways, it was a lot more powerful than CSB, and that was inherent in the object-oriented design I took with it.
At the end of the day, I think it's silly to pick on a project like this.
@Networks: Go write your own CleanSlateBot-"wannabe" control that supports every game, supports local hashing, and doesn't depend on other libraries, release it open source, and then, only then, come back and bitch at me. Thanks. -.-
@Everyone else: Thanks.
So far I've gotten the core laid down and a few packets being sent and received. Its easy sailing from here.
Implementing CD-Key decoding and stuff in VB is harder than I thought. I'll cheat and use BNCSutil, for now.
Quote from: Joe on December 27, 2005, 10:12 PM
Implementing CD-Key decoding and stuff in VB is harder than I thought. I'll cheat and use BNCSutil, for now.
Implementing the long alphanumeric Cd-Key decoding routine in Visual Basic may be tough, but the simple numeric and short alphanumeric routines shouldn't be much of a hassle. Give it a try.
I already did give it a try. I'll get it done eventually, I just have bigger priorities, that can't be handled by BNCSUtil.
I'm doing a lot of work on RBC instead of RB itself to start out with. If you're bored, read these notes I have for AuthEvent and LogonEvent.
AuthEvent status codes:
0x01 - SID_AUTH_INFO sent
0x02 - SID_AUTH_INFO recv
0x03 - SID_AUTH_CHECK sent
0x04 - SID_AUTH_CHECK recv
-- 0x01 PASS
-- 0x02 CDKEY FAIL
-- 0x03 CDKEY2 FAIL
Always check these bitwise
LogonEvent status codes:
0x01 - SID_LOGONRESPONCE
-- 0x01 SEND
-- 0x02 RECV FAIL
-- 0x03 RECV PASS (extrainfo holds unique username)
0x02 - SID_LOGONRESPONCE2
-- 0x01 SEND
-- 0x02 RECV FAIL
-- 0x03 RECV PASS (extrainfo holds unique username)
Damn, we got some haters in the house.
Omg, its beautiful!
Private Sub Handle_SID_AUTH_INFO(sPacket As String, Core As ucBotCore, Debuf As clsPacketDebuffer, BotVars As clsBotVariables)
With Debuf
BotVars.LogonType = .removeINT32
BotVars.ServerToken = .removeINT32
BotVars.UDPValue = .removeINT32
BotVars.MPQNum = Val(Mid(.removeSTRING, 8, 1))
BotVars.ValueString = .removeSTRING
If BotVars.Product = "WAR3" Or BotVars.Product = "W3XP" Then BotVars.ServerSignature = .removeVOID(128)
End With
BotVars.ClientToken = GetTickCount
'// TOTO: SEND 0x51
Dim InfoString$, Checksum&, EXEVersion&
Dim KeyHash1 As String * 20, PublicValue1 As Long, ProductValue1 As Long
Dim KeyHash2 As String * 20, PublicValue2 As Long, ProductValue2 As Long
Call checkRevision(BotVars.ValueString, BotVars.GetHashes(1), BotVars.GetHashes(2), BotVars.GetHashes(3), BotVars.MPQNum, Checksum)
Call kd_quick(BotVars.CDKey, BotVars.ClientToken, BotVars.ServerToken, PublicValue1, ProductValue1, KeyHash1, 20)
Select Case Product
Case "D2XP", "W3XP"
Call kd_quick(BotVars.CDKey, BotVars.ClientToken, BotVars.ServerToken, PublicValue1, ProductValue1, KeyHash1, 20)
Call kd_quick(BotVars.CDKey2, BotVars.ClientToken, BotVars.ServerToken, PublicValue2, ProductValue2, KeyHash2, 20)
Case Else
Call kd_quick(BotVars.CDKey, BotVars.ClientToken, BotVars.ServerToken, PublicValue1, ProductValue1, KeyHash1, 20)
End Select
With BNCS.PBuffer
.addINT32 BotVars.ClientKey
.addINT32 EXEVersion
.addINT32 Checksum
Select Case BotVars.Product
Case "D2XP", "W3XP"
.addINT32 2
.addINT32 0
.addINT32 Len(BotVars.CDKey)
.addINT32 ProductValue1
.addINT32 PublicValue1
.addINT32 0
.addVOID KeyHash1
.addINT32 Len(BotVars.CDKey2)
.addINT32 ProductValue2
.addINT32 PublicValue2
.addINT32 0
.addVOID KeyHash2
Case Else
If Spawn Then
.addINT32 0
.addINT32 1
Else
.addINT32 1
.addINT32 0
.addINT32 Len(BotVars.CDKey)
.addINT32 ProductValue
.addINT32 PublicValue
.addINT32 0
.addVOID KeyHash
End If
End Select
.addSTRING InfoString
.addSTRING "Revelation Bot Core"
Core.SendData .returnBNCS(&H51)
End With
End Sub
More pretty!
Public Function GetHashes(I As Integer)
Select Case Product
Case "DRTL"
Select Case I
Case 1: GetHashes = HashPath & "\diablo.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "DRTL"
Select Case I
Case 1: GetHashes = HashPath & "\diablo_s.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "STAR", "SEXP"
Select Case I
Case 1: GetHashes = HashPath & "\starcraft.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "JSTR"
Select Case I
Case 1: GetHashes = HashPath & "\starcraft_j.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "SSHR"
Select Case I
Case 1: GetHashes = HashPath & "\starcraft_s.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "W2BN"
Select Case I
Case 1: GetHashes = HashPath & "\WarCraft II BNE.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\battle.snp"
End Select
Case "D2DV", "D2XP"
Select Case I
Case 1: GetHashes = HashPath & "\Game.exe"
Case 2: GetHashes = HashPath & "\Bnclient.dll"
Case 3: GetHashes = HashPath & "\D2Client.dll"
End Select
Case "WAR3", "W3XP"
Select Case I
Case 1: GetHashes = HashPath & "\war3.exe"
Case 2: GetHashes = HashPath & "\storm.dll"
Case 3: GetHashes = HashPath & "\game.dll"
End Select
End Select
End Function
Try it this way, its much prettyer :)
Public Const CLIENT_PX3W& = &H57335850
Public Const CLIENT_3RAW& = &H57415233
Public Const CLIENT_PX2D& = &H44325850
Public Const CLIENT_VD2D& = &H44324456
Public Const CLIENT_PXES& = &H53455850
Public Const CLIENT_RATS& = &H53544152
Public Const CLIENT_LTRD& = &H4452544C
Public Const CLIENT_NB2W& = &H5732424E
Public Const CLIENT_RTSJ& = &H4A535452
Public Const CLIENT_RHSS& = &H53534852
Public Const CLIENT_RHSD& = &H44534852
Public Function FILE_EXE$(Client&)
Select Case Client
Case CLIENT_3RAW, CLIENT_PX3W: FILE_EXE = "war3.exe"
Case CLIENT_VD2D, CLIENT_PX2D: FILE_EXE = "game.exe"
Case CLIENT_RTSJ: FILE_EXE = "starcraftj.exe"
Case CLIENT_NB2W: FILE_EXE = "WarCraft II BNE.exe"
Case CLIENT_LTRD: FILE_EXE = "diablo.exe"
Case CLIENT_RHSD: FILE_EXE = "diablo_s.exe"
Case Else: FILE_EXE = "starcraft.exe"
End Select
End Function
Public Function FILE_DLL$(Client&)
Select Case Client
Case CLIENT_VD2D, CLIENT_PX2D: FILE_DLL = "bnclient.dll"
Case Else: FILE_DLL = "storm.dll"
End Select
End Function
Public Function FILE_SNP$(Client&)
Select Case Client
Case CLIENT_VD2D, CLIENT_PX2D: FILE_SNP = "d2client.dll"
Case CLIENT_3RAW, CLIENT_PX3W: FILE_SNP = "game.dll"
Case Else: FILE_SNP = "battle.snp"
End Select
End Function
or the traditional way:
Public Sub GetHashes(ByRef GameEXE As String, ByRef BnetDLL As String, ByRef GameDLL As String)
Dim HashPath As String
HashPath = App.Path & "\Hashes\" & Product
Select Case Product
Case "DRTL"
GameEXE = HashPath & "\diablo.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\battle.snp"
Case "STAR", "SEXP"
GameEXE = HashPath & "\starcraft.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\battle.snp"
Case "JSTR"
GameEXE = HashPath & "\starcraft_j.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\battle.snp"
Case "SSHR"
GameEXE = HashPath & "\starcraft_s.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\battle.snp"
Case "W2BN"
GameEXE = HashPath & "\WarCraft II BNE.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\battle.snp"
Case "D2DV"
GameEXE = HashPath & "\Game.exe"
BnetDLL = HashPath & "\Bnclient.dll"
GameDLL = HashPath & "\D2Client.dll"
Case "D2XP"
'Remember D2XP and D2DV use DIFFERENT hashes
GameEXE = HashPath & "\Game.exe"
BnetDLL = HashPath & "\Bnclient.dll"
GameDLL = HashPath & "\D2Client.dll"
Case "WAR3", "W3XP"
GameEXE = HashPath & "\war3.exe"
BnetDLL = HashPath & "\storm.dll"
GameDLL = HashPath & "\game.dll"
End Select
End Sub
Why not just let the user specify the files?
Quote from: dxoigmn on December 29, 2005, 01:21 PM
Why not just let the user specify the files?
Maybe they set up defaults while also giving the user the power to modify these paths?
Quote from: dxoigmn on December 29, 2005, 01:21 PM
Why not just let the user specify the files?
Agree.
Create a browse function, this way if the user has the game they can just use the hashes in the program directory instead of manually copying them out. If they actually use the game than they will always have up-to-date hashes.
You could have it search the registry for installed clients.
Or set raw files and let the user specify a directory. $dir could be app.path, this is what I do.
Because, would your little sister know how? =)
I've revised AuthEvent and LogonEvent, while implementing them.
AUTHEVENT
DATA1 DATA2 MEANING
0x01 Any Requesting authorization
0x02 Any Authorization challenged
0x03 Any Answering challenge
0x04 0x01 Passed challenge
0x04 0x02 CDKey failed
0x04 0x03 CDKey2 failed
LOGONEVENT
DATA1 DATA2 MEANING
0x01 Any Sent login request
0x02 Any Login request denied
0x03 Any Login request accepted
Networks, if I understand what you're saying, thats what I'm doing. I have a hashpath box in the configuration, which defaults to . (period, points to current directory).
Quote from: Joe on December 30, 2005, 05:41 AM
Because, would your little sister know how? =)
So have defaults and allow power users to set them however they want.