Can Corona Enterprise support expansion file (over 50M APK limit in Google play) for android?

Corona Enterprise already supports “reading” from *.obb expansion files.  The only thing you have to do is create the expansion file yourself, which is really just a zip file, and add the following AndroidManifest.xml entry telling Corona that an expansion file exists.

\<manifest ...\> \<application ...\> \<activity android:name="com.ansca.corona.CoronaActivity" ...\> \<!-- Add this meta-data entry within the CoronaActivity tag. --\> \<!-- This tells Corona that an expansion file exists. --\> \<meta-data android:name="usesExpansionFile" android:value="true"/\> \</activity\> \</application\> \</manifest\>

Remember, Corona Enterprise is just a library which you integrate into your own Android application project.  You’re really compiling with Google’s Android SDK.  So, you have to create the Google Play expansion file yourself according to Google’s documentation.  What I recommend is for you to move all of your assets from your Corona project folder to another folder for you to zip up and rename it with a *.obb extension.  When you do an Android build, ideally, only the Lua scripts should be included within your APK’s assets.  The app template we provide with Corona Enterprise will automatically compile the Lua scripts, bundle them within a “resource.car” file, and move that to your Android app project’s “assets” folder as a pre-build step within your “build.xml”.

Thank you for your reply Joshua. All of what you said is true; however, there is the part on app startup that checks to see whether the obb file is downloaded and will download it if it does not exist. This is the code that I am interested in getting from Corona since you guys have already written it for Corona SDK and it works.

Okay.  You’ll have to do add the “meta-data” tag to your AndroidManifest.xml as I’ve shown up above.

You’ll also need to add Google Licensing (aka: LVL) support to your app as well, which is a Google Play requirement.  You’ll need to add the Android permission equivalents documented in the link below to your AndroidManifest.xml file as well.

   http://docs.coronalabs.com/daily/guide/distribution/buildSettings/index.html#expansion-files

And you’ll need to copy Corona’s Google Licensing plugin *.jar files to your Android app project’s “libs” directory.  You can download our plugins from our daily build page (link below, under “Enterprise” tab).  Make sure to download the Corona build number that matches your Corona Enterprise build number.

   http://developer.coronalabs.com/downloads/daily-builds/

I recommend that you verify that you’ve got Google licensing working first before adding expansion file support.

Once you’ve got licensing working, then move your assets to another folder and create your expansion file.  You can test your expansion file support before uploading your *apk and *.obb file to Google Play by putting your *.obb file in the right SD card location on your device via the Android tool “Monitor” or the older “ddms” tool.  Unfortunately, the exact folder location is different between many devices.  More details can be found here…

   http://developer.android.com/google/play/expansion-files.html