When Unreal Engine 4 created the IPA for iOS for my game which only has a few sprites and blueprints in it the .ipa file size turned out to be 113 MB. Is UE4 adding in part of its engine and features that my game doesn’t use? Are there plans to make it so that when you export a project that it only includes features that you’re using?
Hi Mr. RPG,
Did you package in Development or in Shipping configuration? Shipping general results in a much smaller packaged size, as it compiles out some testing code and strips the debugging symbols from the executable. Another thing to note is that it will cook and package all maps and all referenced content in your game. If you started with the ‘starter content’, I’d recommend deleting the second map that comes with it, as it has references to almost all of the content in it.
The final IPA is just a zip file, so you can open it up and inspect it to see where the cooked size is coming from, in case you are wondering about what content got included. This is something we’d like to improve on in a future release: providing a nice user-friendly report of packaged size and where it’s going.
The cooked .pak file is 57 MB and I created the project without starter content and my assets folder is only 3 MB large. What am I missing?
Edit: I opened up the .ipa and discovered that there’s a feature called Slate in the engine that was 15 MB and I’d like to turn it off. Is it possible?
Hi Mr. RPG,
I didn’t realize that using pak files got turned on by default for iOS. I think you can peer into the .pak by doing:
UnrealPak PathToPakFile.pak -Extract PathToExtractTo
Or you can disable pak file usage by using the game launcher to do the packaging.
I to would like to know this.
The biggest size of slate comes from the various fonts inside of the directory.
I want to remove those.
How can we not include it?
You can’t currently piecemeal choose parts of the engine core style to include or not include, but you can disable the whole thing by setting bUsesSlate = false; in the constructor of your Target.cs file. Unfortunately, this requires making your game into a code project if it was previously a BP-only game.
We’d like to provide more granular control over the core style / allowing you to omit it, replace it, or skip specific fonts in the future.
Would removing the font assets from the Engine folder work? Or would this cause further errors.
Thank you Michael. If there is a trello card for this i would upvote it.
I think it would work. I tried it. But opening the .pak and modifying it invalidates the package.
So i believe technically it should be possible if you can figure out how to alter the package and repackaged and resign it.
Busy investigating this. Will let you know if i do manage to get it right. But truthfully… i think i lack the understanding of the entire packaging process to accomplish this.
I might removing them from the Engine source folders, before they are packaged.
You can try removing them before packaging on the command line, but the fonts (at least the Roboto ones) are used by the Editor, so it might be a little hard to do an interactive cook if you can’t read any text The font loading code at runtime shouldn’t crash if the font or slate images are missing.