• Welcome to Valhalla Legends Archive.
 

Auto Update Code PLZ HELP

Started by ChR0NiC, May 17, 2003, 02:39 PM

Previous topic - Next topic

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..

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.

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 :)
This'll make an interesting test for broken AV:
QuoteX5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*


TheMinistered

LordZero probably stole the code from someone else... He seems like an asshole :) almost as asshole as camel, but camel is actually smart :)

Banana fanna fo fanna

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.

SNiFFeR

Inet makes things alot easier. Just do OpenURL, and your set.

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.

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!

ChR0NiC

I finally got it....and yes I used iNet. Thank you all.

Camel

Quote from: TheMinistered on May 17, 2003, 06:49 PM
LordZero probably stole the code from someone else... He seems like an asshole :) almost as asshole as camel, but camel is actually smart :)

camel is an asshole? he seems pretty cool to me... ;)

Soul


MrRaza

Why not? It's very simple to use.

Banana fanna fo fanna


Camel

Quote from: St0rm.iD on May 22, 2003, 06:46 PM
Heavyweight

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.

Grok

Quote from: St0rm.iD on May 17, 2003, 09:30 PM
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.


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.