How to make your game into a single EXE

Posted by
April 21st, 2016 8:44 pm

Hey all. I figured I would share a trick we use to make our game a single double-clickable .exe with no hassle, extraction, or installation. I’ve found a lot of Unity guys giving out .zips and this could really streamline the process.

Grab a copy of WinRAR. Pretty sure everybody has this except for the hardcore 7zip fanatics. WinRAR is better!

Create a new archive and name it whatever.

1

Copy all of your game data in there. For me it’s just an .exe and a font file.  For your it might be the Unity exe and the data folder or whatever.

Click SFX, then Advanced SFX Options. This basically turns the entire .RAR into a program that will extract itself then run your game.

2

3 4

5

Set some settings. Add the name of your game .exe to “Run after extraction” and make sure the extraction process is both hidden and going to a temporary directory. Check “Overwrite all files,” in case you ever need to make a bugfix it will overwrite the existing stuff in the temp folder with your new stuff.

Add an icon if you want under the Text and Icon section, but it’s not really necessary. After saving and hitting okay, you should now have a single .exe file that will Just Work. Hurray!

PS: Check out our game The Combinatorhttp://ludumdare.com/compo/ludum-dare-35/?action=preview&uid=22640


11 Responses to “How to make your game into a single EXE”

  1. Green Soda says:

    WOW this is really helpful! thnks man

  2. josemwarrior says:

    really awesome trick

  3. ReactorScram says:

    7-zip can do this, too

    • ReactorScram says:

      And it’s free

      • Fumiko says:

        7zip is open source and can do the same trick. It’s okay to use WinRAR instead, but it should be obvious that a free and open standard is the better choice to take when making a tutorial.

        Despite the Pepsi/Coke-like theme here, I would always recommend trying to get more into creating a suitable installer for your target OS. The .exe installers will always only benefit windows systems, so for windows, you could use NSIS (which is also open source) https://de.wikipedia.org/wiki/Nullsoft_Scriptable_Install_System
        The WinRAR “installer” is just an automatic extraction on double click. It has nothing to do with installing the game properly on a windows machine.

        Other operating systems work quite different. Mac OS has the .app system, where you drag and drop the .app container to your software list, and linux users can quite happily work with either a portable .tar.gz file or a shell script. Or you could use http://appimage.org/ for that purpose, to make a single executable that works on multiple distributions.

        Either way, I am thinking that it’s better to write a tutorial about something that everyone can use. And to help people share their games on the right way, not on the bad way. And with “bad” I mean, the “only-with-our-product” way.

        Sorry for the long comment.

        • El Cabaro says:

          The entire point of this method is to avoid anything about installing or leaving any trace on your disk- especially when you’re going to be playing a lot of games. An installer is not wanted. So yeah this is a little bit hacky, but it’s a bunch of little LD games so it doesn’t matter.

          This trick only really benefits Windows because on Macintosh you’d just give out a DMG with a .app inside, which contains your game data.

  4. tybantarnusa says:

    I am a hardcore 7-zip fanatic :(
    And yes I don’t have winRAR xD

  5. elvinv8 says:

    I’ve created a small game and now I want to export it into an EXE file but I don’t know how. I’ve attempted using the application but it doesn’t work, so I don’t know what to do. If anybody could help it would be very much appreciated :) Get the latest apps for free on Tutuapp vip free.

  6. matadore64 says:

    A word to the wise: this process will go easier if your game executable does not have any spaces in its filename. If you’re using Unity, that means going to the Player Settings before you export your build and removing any spaces from the Product Name, and this will ensure consistency in the game data. I hope you have a fantastic day!

  7. flyinpancake says:

    Thank you so much. This is something I have been looking for and found it today. Thank you so much. You da real WinRAR.

Leave a Reply

You must be logged in to post a comment.

[cache: storing page]