Jump to content

Updater software! MD5


slaughter
 Share

Recommended Posts

This is game loader witch check files with MD5 checksum.

Why is good? You dont have to change anyting when you update your game or app

just upload changed files to server. Thats it. Client automaticly check file and if its difrent on client side will delete it and replace with updated one in server.

Screenshoot:

post-3048-1196723161_thumb.jpg

Only beta version baisicly made it for Lineage 2

TDL:

direct seciurity data transfer to memory withuot saving on disk

sub folders check

custom files out of game directory

protection, preventing app start without loader

Requiriments:

Web server with PHP.

Files:

file_list.php

$dir = Path to original files to compare with client ones. Dont put folder there it dosent support sub folder check.

This file goes to Web server.

And your originl files witch have to be cheked goes to on web server. Take a look at PHP code

post-3048-1196612106_thumb.jpg

Original name: bg.jpg

Backgruond picture for loader. Add some text with photosop and you have your news shown every time they start client.

MD5Hash.dll

name: loader.dll

(you can find it in forum search to. It's not my dll I borowed it)

save it as loader.dll it is dll witch i fuond on autoit forums it does MD5 checksumm function, as autoit dosent have it.

name: Loader.au3

Loader.au3

AU3 script :)

Comments? Offers? ^_^ Greatfull

Edited by slaughter
Link to comment
Share on other sites

sorry for dump witch I posted. at 8:00 +2GTM will be full with guide.

Just wanted to see is this use full. SO I carry on on this.

Link to comment
Share on other sites

you should check out the VersionCompare udf

the function you would find useful is VersionCompareX

It can handel any version number that is numbers or letters...

like 10.3.4.5.2 and 11.34.4.5.2A

i use it in my AutoUpdater

Thanks I will tke a look :)
Link to comment
Share on other sites

-1 means $sOne > $sTwo

0 means $sOne = $sTwo

1 means $sOne < $sTwo

BTW: I'm not the author of this... Im unsure of the author...

Func _VersionCompareX($sOne, $sTwo)
    Local $returnValue = 0
    Local $tempOne = StringSplit($sOne, "."), $tempTwo = StringSplit($sTwo, ".")
    Local $numPositions = $tempOne[0]
    If $tempTwo[0] > $tempOne[0] Then $numPositions = $tempTwo[0]
    Dim $arrayOne[$numPositions], $arrayTwo[$numPositions]
    For $X = 0 to $numPositions - 1
        $arrayOne[$X] = 0
        $arrayTwo[$X] = 0
    Next
    For $X = 1 to $tempOne[0]
        If $X > $numPositions Then ExitLoop
        $stripped = StringRegExpReplace ($tempOne[$X], "^0+", "")
        If $stripped <> "" Then $arrayOne[$X - 1] = $stripped
    Next
    For $X = 1 to $tempTwo[0]
        If $X > $numPositions Then ExitLoop
        $stripped = StringRegExpReplace ($tempTwo[$X], "^0+", "")
       
        If $stripped <> "" Then $arrayTwo[$X - 1] = $stripped     
    Next
    For $X = 0 to $numPositions - 1
        Switch StringCompare ($arrayOne[$X],$arrayTwo[$X])
            Case 0
                $returnValue = 0
            Case -1
                $returnValue = -1
                ExitLoop
            Case 1
                $returnValue = 1
                ExitLoop
        EndSwitch
    Next
    Return $returnValue
EndFunc

Hope it helps!

Edited by DBak

[center][/center]

Link to comment
Share on other sites

  • 8 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...