Deep Dive: Android Integration for a Zig + Mach Game
This covers the full path from mach build to a Play Store AAB, including the JNI bridge for Play Games Services, lifecycle handling, and the traps that eat days.
Part 0: Mental Model — How Android Games Work
An Android game is an APK/AAB containing :
MyGame.apk
├── classes.dex ← Java/Kotlin bytecode (Activity, JNI glue)
├── lib/arm64 v8a/
│ └── libMyGame.so ← your Zig code, loaded via System.loadLibrary