How I didn’t use Unity3D

George Xu, me (Adin Kwok), Josh Chan

Luckily, an idea popped in my head.

Unity has a feature that allows exporting projects into a native codebase. This in turn allows developers to import the code into the platform’s native IDE. Being a novice Android developer at the time, that meant that I could continue development with Android Studio. What if I just made an Android menu that launched the Unity engine with the press of a button? Having to simultaneously learn Unity and implement our ideas was rewarding but limiting. Moving the remaining development into Android Studio was going to help us finish our project on time, but only if it was possible. However, I wasn’t an expert in Android development, so I wasn’t completely confident in my idea. The burnout was really getting to me and I needed a break. Luckily, one great thing about hackathons is that there’s usually a ton of free stuff given out, so I spent an hour throwing a bouncy ball against the wall. As the drowsiness began to wear off, I thought the idea over one more time. We had nothing to lose, maybe except for the competition, so why not?

Notice the Export Project checkbox and Export button, that’s the play
I had to deal with this stuff for what seemed like an eternity
<activity android:label="@string/app_name" android:screenOrientation="sensorLandscape" android:launchMode="singleTask" android:configChanges="mcc|mnc|locale|touchscreen|keyboard|keyboardHidden|navigation|orientation|screenLayout|uiMode|screenSize|smallestScreenSize|fontScale|layoutDirection|density" android:hardwareAccelerated="false" android:name="com.adinkwok.vremdr_unity.UnityPlayerActivity">
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.intent.category.LEANBACK_LAUNCHER" />
<category android:name="" />
<meta-data android:name="unityplayer.UnityActivity" android:value="true" />
// Code snippet to launch the UnityPlayerActivity manually
Intent startSession = new Intent(this, UnityPlayerActivity.class);
startActivity(startSession); // Kotlin > Java



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Adin K

Adin K


SWE Intern @ Facebook. Ex-SDE Intern @ Amazon (AWS). Ex-SWE, Data Eng, Product Manager Intern @ Intersect.