[ N-04 / 07 ]Simulation and AI·2026·Android · Kotlin + C++ (NDK)
Iron Doctrine
A tactical game for Android where squads learn to fight on their own over thousands of simulated battles instead of following a fixed script.
- Engine
- C++ (Android NDK)
- Brain
- GRU neural network
- Generations of learning
- 224
- Status
- in progress

AWhy it exists
In most games the enemy follows rigid rules and soon becomes predictable. I wanted to see whether squads could work out tactics on their own, on an ordinary phone, without a cloud server.
BWhat came out of it
After 224 generations of learning, a squad wins every engagement against the computer opponent in both training programmes (“Range” and “Manoeuvres”). The building generator created 2,000 maps without a single error. Two combat scenarios (capture the flag and a hostage rescue), three maps and three difficulty levels are ready. I am now working on a campaign and a store release.
CFor technical readers: how it is built
A C++ simulation engine over JNI (NDK, CMake): entities, map, brain and ES trainer. The brain evolved from a simple net into a recurrent GRU with residual connections; inputs include “hearing” (8 sectors, attenuated by walls), a compass to the flag and squad radio. Evolution-strategies training runs in a foreground service with a wake lock. A CQB building generator guarantees a path through every building. The UI was rewritten in Jetpack Compose with ViewModel and StateFlow, a command-map canvas with camera and gestures, in Polish and English.
→How it works, briefly
- 01Compose UI
- 02ViewModel
- 03JNI
- 04C++ engine
- 05ES trainer
↳What it does
Technologies
- Kotlin
- Jetpack Compose
- C++
- Android NDK
- CMake
- JNI
01
Hearing
Soldiers hear shots from eight directions, and walls muffle the sound.
02
Hostages
Missions with civilians who react in their own way. Every civilian loss costs points.
03
Background training
Both squads keep learning even with the phone screen locked.
04
Command map
Pan and zoom the map with your fingers, and tap a soldier to see their status. Works on phones and tablets.
05
Live orders
Tap a soldier and give an order: move, attack, hold, retreat. You can also hand command to the computer.
06
Day, night and colour-blind modes
Day and night themes in uniform colours, a colour-blind mode and a battery saver.
▢Screens


↗Contact
Got an app worth testing? Get in touch.
Next project · N-05
RONDO