Convert Construct 2/HTML5 to APK (AdMob available!)


Hello readers! Today I am going to share my experience on exporting my Construct 2 project to APK (Android Apps).

So, a couple days after I released Chiperia on Itch.io HTML5 (playable on ANY device that has a browser in it).

And I decided to make the Android version of it which has touch control. After adding the touch control and a little bit of Ads from AdMob I realized that there is no APK option in the 'Export' section.

Obviously I googled the solution but most of them is hard or outdated. Then I remembered there is PhoneGap Build! Which could convert Cordova to APK and other Mobile Apps such as iOS and Windows Phone.

Oh... PhoneGap is Dead. I'm sure there is more online alternative which are free!

Actually no. There is no free online alternative. If it is free it comes with a great limitations.

There is also Cocoon.io which is free and VERY easy to use. But it is also dead. Intel XDK is also dead.

After days of research I stumbled upon 'How to convert Cordova to APK using Android Studio'. I followed the tutorial and it is HARD.

But then, there is still a pinch of hope.

The Hope:

I found a website that offers a free software than can convert Construct 2 Cordova to APKcalled HTML5 Adapter. It is completely FREE! It also has all plugins and APIs you need such as AdMob and other stuff. You can visit the website here:

https://html5-adapter.tk/

Please note that Java and JDK are required use the program optimally.

Step by Step Tutorial:

After you downloaded it, unzip the .zip file. I think this software is portable and can be "installed" in a USB Drive.

1. Open your Construct 2 project and export it as 'Cordova'

After you exported it to Cordova (Android ticked) the exported files should look like this:

2. Open HTML5 Adapter. 2 windows will pop up. One looks like to be some sort of command prompt window:

And the other one is the GUI window

3. After you opened it, you need to add a new project

4. Name your project. In my case I will name it 'Test1'

5. After you created your project select your project (in my case it is 'Test1').

6. And then choose which platform you will export your project to. To export to Android as .apk choose 'AndroidIAP'.

7. Fill in the application details.

In my case it is:

8. And then copy the Cordova folder that you exported from Construct 2 and paste it to the project folder which is located in (adapter folder)>projects>(your project name in my case it is 'Test1')>AndroidIAP

Copy the all of the files including 'www' and config.xml and config.json.

Copy all those files and folders into the mentioned directory above ((adapter folder)>projects>(your project name in my case it is 'Test1')>AndroidIAP)

9. Click 'Build' in the HTML5 Adapter software.

10. Wait until it finished building. The program might become 'Not Responding' while building. Just wait patiently.

If it says 'build failed. something went wrong' just close the software and then re-open it and select your project and rebuild it again.

If it STILL says 'build failed. something went wrong' again, try running the program as administrator.

Also if it STILL does that make sure you filled in the right details and change the version number to 4 section version number (1.0.0.0 instead of 1.0 / 1.0.0).

I don't know if it matters but sometimes it happens to me and I tried some of the possible fixes including the fixes above that I mentioned.

11. Also, forgot to mention. You can change the icons by replacing the icons in this directory:

Adapter1dot42\projects\Test1\AndroidIAP\icons

Make sure to make the correct resolution and keep the file names and formats same each file as the example icons.

12. Done! After you successfully build the app, the all will be exported to the 'builds' folder in the HTML5 Adapter directory. 

- Please keep in mind that the name will be generic and you need to      move the exported APK files or rename it before exporting other        project to avoid overwriting or corrupting the APK.

You will get 2 APKs.

1) This APK is unsigned and impossible to install (Usually). To install this APK you need to sign it with a unique keystore. Signing is necessary if you want to publish your Application to App Stores such as Google Play Store, Samsung Galaxy Store, etc.. (Except Amazon Appstore).

2)This APK is signed using a 'Debug' keystore. You can install this on your Android device straight away. You can also re-sign it later using your own unique keystore.

Note: Some developers have problems with AdMob ads not showing due to variations of keystore. As for now, my 'Chiperia' game does not shows AdMob ads on Amazon Appstore but AdMob ads run smoothly on Samsung Galaxy Store and Independent APK available on my Itch.io page (https://freadel.itch.io/Chiperia). I am waiting for a response from the Amazon Developer Support Team.

UPDATE: Add Amazon Appstore to the App Stores list in your AdMob Application setting to fix the problem above.

Note: Use test ads first. If it shows then change it to your real AdMob ID. It may takes time for your real ads to show.

Here are the end result of my Construct 2 Project exported to APK using HTML5 Adapter which you can download here for free:

https://freadel.itch.io/Chiperia

Hopefully this tutorial helped you. Check out my YouTube Channel for more contents:

youtube.com/Freadel


THIS POST WAS ORIGINALLY MADE FOR Freadel Blog


tags: How To Export Construct 2 to APK, how to export construct 2 games to android, construct 2 admob tutorial, construct 2 Android tutorial, html5 to apk, cordova to apk, how to turn html5 to APK, webstie to APK, construct 2 android tutorial, construct 2 admob, construct 2 android games, how to make android games and make money with admob, how to make Android games, how to make Android Apps, html5 to APK converter, website to apk converter, construct 2 to apk with admob 100% working


Files

Chiperia.apk 5 MB
Jun 27, 2021

Get Chiperia

Download NowName your own price

Leave a comment

Log in with itch.io to leave a comment.