Ok so basically this is my first article, so please, don't bite.

This is the first article on how to make a game updater in MMF with the Download Extension. I'll post a second type (even more easy) later today or tomorrow.

You will need:

A website
A text editor
MMF2
Time to read this article carefully

And the following Objects/Extensions in your application:

Download Object (1)
Ini (1)
String (4)
Button (1)


Step 1

Open Notepad, or any text editor, and put this:

Version=1.0
New Dwnld URL: Http:// www. yoursiteaddess .com/ Newest Version.exe


Then, save the file with a specific name. In this article, I'll use the name New.Ini.

Go to your website control panel thing, and upload New.ini. After that, note the URL (example: http:// www. yoursiteaddress .com/New.Ini)

Open Notepad again, or any text editor, and put this:

Current=0.0

Then save it the same folder you're going to save the .MFA file with the name Current.ini.

Step 2

Go to your MMF application, and add the Specified Objects/Extensions.
Go to events, and add this event:

Timer is greater than 00''-05 :
Download File http:// www. yoursiteaddress .com/New.Ini ! <- This is your file's url ! on slot 1 Destination: Appdir$+New.Ini


Start of Frame :
(Ini) Set Current file to Appdir$+Current.ini
(String 1)Change alterable string to ItemString$(Ini, Current)


(Download Object) Download successfully completed slot 1:
(Ini) Set file to Appdir$+new.ini
(String 2) Set alterable string to ItemString$(Ini, Version)
(String 4) Set alterable string to ItemString$(Ini, New Downld URL)


String$(String 1) <> String$(String 2) :
(String 3) Change Alterable String to A new version is available. Would you like to download it?


(Button 1) Button Clicked :
Download File String$(String 4) on slot 2 Destination: Appdir$+GameName.exe


(Download Object) Download successfully completed lot 2:
(String 3) Change alterable string to Download Complete! You now have the most recent version!
(Ini) Set file to Appdir$+Current.ini
(Ini Set string string$(String 2) to item Current


And that's it! The newer file will overwrite the older file. Always be careful not to close the app while downloading the new file, because it will corrupt it.

I'll update this article to add pictures and correct mistakes, if any. And I'll add the second Type of updater later.

To Update the File, you need to edit the New.Ini file on your website. Just change the version number.