Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Building Unity 3D game (in Windows) as a single *.EXE file.

Discussion in 'Formats & External Tools' started by Kaya, Jan 3, 2011.

  1. Kaya

    Kaya

    Joined:
    Dec 21, 2010
    Posts:
    50
    Unity 3D (in Windows) creates an *.exe file a data folder with many files and subdirectories.

    Which SW tool you would recommend to combine all those files and folders into a single *.EXE file?

    -Kaya
     
    rakkarage likes this.
  2. siliwangi

    siliwangi

    Joined:
    Sep 25, 2009
    Posts:
    303
    ShizumaruRiya likes this.
  3. siliwangi

    siliwangi

    Joined:
    Sep 25, 2009
    Posts:
    303
    I've wrote a tutorial on enigma forum, you can check it out : http://enigmaprotector.com/forum/viewtopic.php?f=20&t=569 , the enigma virtual box is free but you can get more advanced version on their Enigma Protector product, i have tested both the virtual box and protection it works for unity project.
     
  4. lightbe

    lightbe

    Joined:
    Mar 17, 2016
    Posts:
    8
    It appears that MoleBox is no longer in business. The link provided as of 5/12/2016 is a blog related to online dating. I also could not get the Enigma Virtual Box to work. The help section is terrible and I could not get both the exe file and data folders in the same place.
     
  5. GrumpyFour

    GrumpyFour

    Joined:
    Jan 12, 2016
    Posts:
    17
    I am also trying to figure out how to do this. I have tried Inno Setup and Enigma Virtual Box. Inno Setup is good for creating a single installer file, but running that file just reproduces the whole set of files created by the Unity build process. Enigma Virtual Box creates a single .exe file, but I can't get that file to run-- it throws an error labeled "cannot load library UnityPlayer.dll".

    Any help is appreciated. Thanks!

    Edit: tried MoleBox as well. My antivirus flagged a file produced by the MoleBox build as a ransomware trojan. oops. Looks like that's a no-go as well.
     
    Last edited: Apr 24, 2019
  6. Alex_Playz_Kingdom

    Alex_Playz_Kingdom

    Joined:
    Oct 2, 2019
    Posts:
    1
    I can't get that file to run-- it throws an error labeled "cannot load library UnityPlayer.dll".
    Did you include the UnityPlayer.dll from Unity build? In order for it to work you should Include data, exe, mono and UnityPlayer.dll
     
  7. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    May I ask why you want it all in one executable? Unless your game is very simple, won't that blow up the size of the exe?

    If you want to be able to just send people a single file, you can use NSIS to create a self-extracting executable, but the end result will still include directories.
     
    Eco-Editor and Andersen_27 like this.
  8. dpt2

    dpt2

    Joined:
    Jun 15, 2021
    Posts:
    50
    Makes it harder to decompile - 1 extra step. Also, makes it easier to port around.
     
  9. mgear

    mgear

    Joined:
    Aug 3, 2010
    Posts:
    9,350
    also the default desktop output folder is quite messy,
    multiple exe's (crashhandlers or so), some dll's in the root folder, "strange" bleedingedge-folder.. customers are confused. (installer could help, if user has rights to install apps, but rather would have quick n easy to run single file)

    sadly those current all-in-one-packers seems to trigger antivirus too often..
     
    astracat111 likes this.
  10. dpt2

    dpt2

    Joined:
    Jun 15, 2021
    Posts:
    50
    That's the downside. Also, it turns a file binary -- which can be good and bad. This means on Steam, they'll have to download THE ENTIRE GAME each patch (instead of just updated files). On the bright side, this also hides diff updates from snoopers.
     
  11. xdSyke

    xdSyke

    Joined:
    Sep 5, 2022
    Posts:
    1
    none of your busy busy busines
     
  12. astracat111

    astracat111

    Joined:
    Sep 21, 2016
    Posts:
    725
    I'm looking for a cheap quick solution as well.

    Couldn't the game be a .bat file, then you could just put all the unity stuff in a hidden subfolder. People will steal data and assets no matter what you do, for me it's just a matter of being neat.

    A bat or sh file could extract an archive on the first time the game runs, then delete the archive (to save space), then the game could run from the bat or sh file.

    Looking into Engima Virtual Box as well, but this is my cheap quick solution for the problem of it not being neater.