Skip to content

The executable

Adrian Hintze edited this page May 8, 2017 · 10 revisions

A quick look at the generated executable by OS. Structure, features and quirks.

Common

The following is true for all versions of the executable.

  • As soon as you execute the executable it will start loading your project. This may take some time. You may only see a white screen or some jumbled up sprites until the project finishes loading.

  • Once the project has been loaded, Snap's flag event will be fired once. This means that if your project starts when the green flag is pressed, it will start immediately. This also means that it will only run once.
    Depending on your project, you might want to change the start of the execution to a "when <key> pressed" block.

  • MP3 sounds and other proprietary formats won't work. Check out this Q&A for more details.

Windows

Structure

.<project_name>/
├── bunch_of_files
├── bunch_of_directories/
└── <project_name>.exe

You want to ignore everything and execute the <project_name>.exe file. Depending on your UAC settings, Windows might complain about executing an unknown program. This is normal as the executables are not signed in any way.

Features

  • Windows executables switch to full-screen mode when the F11 key is pressed, just as a browser would. You can press the same key again to exit full-screen mode.

MacOS

Structure

./
└── <project_name>.app

As the entire application is stored inside the .app directory, as a MacOS user you won't see any clutter. Except if you manually start digging through the .app.

Just execute the application. It is likely that MacOS will complain about running an unknown application. This is normal as the application is not signed in any way.

Features

You should be able to use standard MacOS shortcuts to close, minimise and maximise the application.

Quirks

If you have a retina display the executable may look fuzzier than Snap running on a browser.

Linux

Structure

./
├── <project_name>.snapp/
└── <project_name>.desktop

If you are using a GNOME-based desktop you should be able to execute the application by opening the .desktop file. As a bonus, the file will auto-update it's icon to something snappier!

If for some reason the .desktop file doesn't work for you just open the .snapp directory and execute the corresponding binary file directly.