Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Client Patcher (VB6)


Lenton
 Share

Recommended Posts

Hello, I know it's a big ask but I was just wondering if anyone knew how to program a client patcher.

It would have to be written in VB6 so I could impliment it into my game .exe.

Even ifyou don't know how to do it all, anything would be a great help.

If you help me out or do this for me your name will be put in a large, bold font on the patcher interface.

Note - The client patcher is for Mayhem Online.

Thanks for your help!
Link to comment
Share on other sites

What does this do?

```
URLDownloadToFile(0, Site & "Decks.ini", App.Path & "\Decks.ini", 0, 0)
```
And what does this do?

```
Sub DownloadMain()
Dim X As Long

    Select Case Progress
        Case 0
            If FileExists(App.Path & "\Update.ini") = True Then
                ReDim Files(1 To Val(ReadINI("Update", "Files", App.Path & "\Update.ini")))
                For X = 1 To ReadINI("Update", "Files", App.Path & "\Update.ini")
                    Files(X) = ReadINI("Update", "File" & X, App.Path & "\Update.ini")
                Next X
                Label2.Caption = "Downloading " & Trim(ReadINI("Update", "File1", App.Path & "\Update.ini"))
                retVal = URLDownloadToFile(0, Site & Trim(ReadINI("Update", "File1", App.Path & "\Update.ini")), App.Path & "\" & ReadINI("Update", "File1", App.Path & "\Update.ini"), 0, 0)
                If retVal = 0 Then
                    Progress = 1
                    Call DownloadMain
                End If
            End If

        Case Else
            If ReadINI("Update", "Files", App.Path & "\Update.ini") >= Progress Then
                Label2.Caption = "Downloading " & Trim(ReadINI("Update", "File" & Progress, App.Path & "\Update.ini"))
                retVal = URLDownloadToFile(0, Site & Trim(ReadINI("Update", "File" & Progress, App.Path & "\Update.ini")), App.Path & "\" & ReadINI("Update", "File" & Progress, App.Path & "\Update.ini"), 0, 0)
                If retVal = 0 Then
                    Progress = Progress + 1
                    Call DownloadMain
                End If
            Else
                LblUpdate.Caption = "Updated to version " & Val(Version + 1)
                Label2.Caption = ""
                CmdPlay.Visible = True
                Kill (App.Path & "\Update.ini")
                Call WriteINI("Updater", "Version", Val(Version + 1), App.Path & "\Settings.ini")
            End If
    End Select
End Sub
```
I just need to know this and I would be done.
Link to comment
Share on other sites

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

×
×
  • Create New...