Valhalla Legends Forums Archive | Battle.net Bot Development | Auto Update Code PLZ HELP

AuthorMessageTime
ChR0NiC
Well obviously in current version of your bot, you have bugs and once you update, you wish for those bugs to be forgotten. So I want an auto update which checks the current version against the latest version on my website. And I know LoRd]ZeR0[ knows how to do that, but he isn't as nice as people think. Anyways, if anyone knows even where to START all help will be appreciated. But no useless posts plz..
May 17, 2003, 7:39 PM
Crypticflare
Go to http://www.pscode.com Search For Auto Update, It has a few examples on how to check two versions, its all done with msInet.ocx I believe.
May 17, 2003, 9:08 PM
iago
Well, if you know how to use winsock it's pretty simple to have a verification server running on your computer and when your program starts it connects to your box, gets the version, and informs the user that an update is available. If you want to be meaner, don't let them run the program if an update is available.

That's about as simple as it gets, making the users update it themselves :)
May 17, 2003, 9:49 PM
TheMinistered
LordZero probably stole the code from someone else... He seems like an asshole :) almost as asshole as camel, but camel is actually smart :)
May 17, 2003, 11:49 PM
St0rm.iD
assume(vb)

1. Get yourself a Geoshitties acct
2. Make a textfile, update.txt, that looks like (ignore the ' comments):
1.1 'current version
1234abcd 'CRC32 of the current version EXE file
This version adds some new stuff 'description of patch
http://www.geocities.com/crapbot/patch1.1.exe 'patch executable

3. In your bots sub main or form_load, have your inet control get that textfile, and split() by vbcrlf. Run a CRC32 on the bot exe (app.path & "\" & app.exename) and compare to line(1). If they aren't the same, pop up a message box, asking, "Do you want to upgrade to " & line(0) & ": " & line(2) & "?"

4. If they want to upgrade, use msinet to get the file at line(3), and run it with shell

5. You can get a cool patch maker at www.clickteam.com

Have a nice day.
May 18, 2003, 2:30 AM
SNiFFeR
Inet makes things alot easier. Just do OpenURL, and your set.
May 18, 2003, 3:49 AM
ChR0NiC
LoL I seem to have offended LoRd]ZeR0[ cuz he kind of blocked me and shit. I just meant, he has the knowledge.....why doesn't she share it. Cuphead knows 100 times more than he does and he shares almost every bit of it.
May 18, 2003, 6:20 PM
TheMinistered
I know a million times more than he does, and I share it too... want an example of how to do it? then message me on aim!
May 18, 2003, 6:50 PM
ChR0NiC
I finally got it....and yes I used iNet. Thank you all.
May 20, 2003, 5:42 AM
Camel
[quote author=TheMinistered link=board=17;threadid=1361;start=0#msg10161 date=1053215353]
LordZero probably stole the code from someone else... He seems like an asshole :) almost as asshole as camel, but camel is actually smart :)
[/quote]

camel is an asshole? he seems pretty cool to me... ;)
May 22, 2003, 2:14 AM
Soul
Use inet - Good idea? :o
May 22, 2003, 9:24 PM
MrRaza
Why not? It's very simple to use.
May 22, 2003, 11:26 PM
St0rm.iD
Heavyweight
May 22, 2003, 11:46 PM
Camel
[quote author=St0rm.iD link=board=17;threadid=1361;start=0#msg10450 date=1053647191]
Heavyweight
[/quote]

it's a tradeoff. if you don't use it, you have to invest more time and effort. compared to the size vb's overhead already is, it's relatively lightweight. the ocx is under 60k, and i can't see how it could possibly add more than a few miliseconds longer than the old-sk00l method to execute. imo, it's worth it -- i'd rather spend the time making sure the php is correct than worrying about handling socket errors and the like.
May 23, 2003, 1:33 AM
Grok
[quote author=St0rm.iD link=board=17;threadid=1361;start=0#msg10169 date=1053225043]
assume(vb)

1. Get yourself a Geoshitties acct
2. Make a textfile, update.txt, that looks like (ignore the ' comments):
1.1 'current version
1234abcd 'CRC32 of the current version EXE file
This version adds some new stuff 'description of patch
http://www.geocities.com/crapbot/patch1.1.exe 'patch executable

3. In your bots sub main or form_load, have your inet control get that textfile, and split() by vbcrlf. Run a CRC32 on the bot exe (app.path & "\" & app.exename) and compare to line(1). If they aren't the same, pop up a message box, asking, "Do you want to upgrade to " & line(0) & ": " & line(2) & "?"

4. If they want to upgrade, use msinet to get the file at line(3), and run it with shell

5. You can get a cool patch maker at www.clickteam.com

Have a nice day.

[/quote]

A hearty -1 to St0rm.iD for going to the trouble to paste yet another viable solution which gets ignored. The only thing I'd change in his would be to have the update checker in a menu item, and not done automatically by default. Users shouldn't be forced to upgrade, ala Microsoft.
August 21, 2003, 8:01 AM
CrAz3D
I love Microsoft's updates, they popup at inconveint, random times. They provide almost no help to whatever may be wrong with my computer.
-I do msgs saying that I need to update or w/e, jsut so I know something is wrong.

It's just so much fun to sit on dial-up & download Microsoft patches.

EDIT:
Well I'll be damned, just as I post this I look at my System tray & there is Windows Update going about it's business.
August 21, 2003, 4:32 PM
DaRk-FeAnOr
Post a text file on a server.
By using MSinet.ocx, make it state the current version in the text file. If the version on the bot you are running and the current version uploaded do not match, Tell them that their bot is out of date

[code]
Public Function GetVer(ByVal Version As String) As Boolean
On Error Resume Next
dim textstuff as string
textstuff = Inet1.OpenURL(www.yoursite.com/text.txt)
Do While Inet1.StillExecuting
DoEvents
Loop
If LCase(textstuff) = LCase(version) Then
Getver = True
Else
Getver = False
End If
End Function
[/code]
August 21, 2003, 5:30 PM
Camel
[quote author=Grok link=board=17;threadid=1361;start=0#msg18788 date=1061452918]
A hearty -1 to St0rm.iD for going to the trouble to paste yet another viable solution which gets ignored. The only thing I'd change in his would be to have the update checker in a menu item, and not done automatically by default. Users shouldn't be forced to upgrade, ala Microsoft.
[/quote]

I believe a great man once said, "DIE THREAD, DIE."
August 21, 2003, 8:17 PM
Grok
Why die? This is a good topic with a great many possible good solutions. I think a listing and discussion of them is completely relevant to good bot development.
August 22, 2003, 12:43 AM
DaRk-FeAnOr
Why not add something like this to BNLS, that could be hooked up to your BNLS account? You send a packet on connection to BNLS and it returns if a new release is out :)
August 22, 2003, 2:43 AM
Camel
[quote author=DaRk-FeAnOr link=board=17;threadid=1361;start=15#msg18827 date=1061520235]
Why not add something like this to BNLS, that could be hooked up to your BNLS account? You send a packet on connection to BNLS and it returns if a new release is out :)
[/quote]

How is that in any way related to the BNCS protocol? Perhaps your suggestion would be better suited on BotNet and not BNLS.
August 22, 2003, 6:06 AM
CrAz3D
True, but either way that would be a good/cool idea.
August 22, 2003, 4:33 PM
St0rm.iD
Grok: that's why I've essentially stayed off of this forum and kept to Adron/Grok/Advanced/Webdev forums.
August 23, 2003, 12:28 AM
CrAz3D
Are you dissing us st0rm?
August 23, 2003, 12:39 AM
St0rm.iD
Yes, I am. Tough.
August 23, 2003, 1:07 AM
WinSocks
St0rm reminds me of........ me

but more cocky :P +1 to St0rm

and -10000000000 to me from everyone else :D
August 23, 2003, 1:34 AM
St0rm.iD
Noooo +1
But I have a reason: I always used to post perfectly viable solutions, which were always ignored, and whenever I told someone what I thought about their problems, they always say "well you could've helped."

It really pisses me off.
August 23, 2003, 9:10 PM

Search