A mobile idle/incremental game for iOS and Android. Humanity's last stand against rogue machines!
The Story
The year is 2157. Humanity's automated defense systems went rogue, and now endless waves of machines threaten the last human settlements. You're the commander of a makeshift outpost, scavenging resources to build defenses and push back against the mechanical onslaught.
As you upgrade buildings, you'll discover log entries from the original engineers who built these machines - slowly revealing what went wrong and who 'The Architect' really is.
Core Gameplay Loop
Wave Combat - Enemies spawn in waves, each stronger than the last. You deal damage by tapping (active play) or through your automated defenses (idle progress). Clear waves to earn scrap, the primary currency for building upgrades.
Building System - Construct and upgrade 6 unique buildings:
- Scrap Works - Generates passive scrap income over time
- Weak Point Scanner - Increases critical hit chance and damage
- Training Facility - Boosts tap damage for active players
- Shield Generator - Provides damage reduction against enemy attacks
- Command Center - Unlocks and enhances auto-damage systems
- Engineering Bay - Improves all other building efficiency
Each building has 4-5 evolution tiers with unique visual designs and exponentially scaling power. The first tier Scrap Works is a pile of salvage; the final tier is an automated mining complex.
Boss Fights - Every 10 waves features a boss with significantly more HP and special abilities. Defeating bosses grants bonus scrap and rare blueprints.
Progression Systems
100 Waves to Victory - The campaign spans 100 waves with carefully tuned difficulty scaling:
- Waves 1-12: Tutorial and early game (learn the mechanics)
- Waves 13-50: Mid game (unlock all buildings, first prestige)
- Waves 51-95: Late game (multiple prestiges required)
- Waves 96-100: The Gauntlet (elite enemies, no breaks)
- Wave 100: The Architect (final boss, 2.5 million HP)
Prestige System - When progress stalls, prestige to reset your buildings but keep your blueprints. Blueprints unlock permanent upgrades:
- Tap Power (+25% per level)
- Auto Damage (passive DPS unlocks)
- Production Boost (+15% building output)
- Lucky Drops (better reward chances)
- And 6 more upgrade trees
Quality of Life Features
Offline Progress - Close the app and come back to accumulated resources. Earn up to 8 hours of offline progress at 50% efficiency. Perfect for overnight farming.
Daily Rewards - Log in daily for escalating bonuses. Consecutive logins increase the multiplier up to 7x.
Lucky Drops - Random bonus rewards when clearing waves. Ranges from small scrap bonuses to rare blueprint fragments.
Strategic Depth - Unlike many idle games, Idle Rampage rewards active decision-making. Which building do you upgrade next? When's the optimal time to prestige? Do you push for the next boss or farm the current wave?
A React Native mobile game demonstrating complex game system design, state management patterns, and mobile-specific optimizations.
Architecture Overview
The game uses an ECS-inspired (Entity Component System) architecture with 11 specialized game systems. Each system handles one aspect of game logic and communicates through a central event bus.
GameLoop (60 tick/sec)
|
+-- CombatSystem (damage calculations)
+-- ProductionSystem (resource generation)
+-- WaveManager (enemy spawning)
+-- PrestigeSystem (progression reset)
+-- OfflineProgress (away earnings)
+-- DailyRewards (login streaks)
+-- LuckyDrops (random bonuses)
+-- WorkerEfficiency (building modifiers)
+-- SpecialEffects (visual feedback)
+-- BuilderManager (construction queue)
+-- SaveManager (persistence)
State Management
Zustand Store - Single source of truth for all game state. Zustand was chosen over Redux for its minimal boilerplate and native async support. The store structure:
interface GameState {
// Resources
scrap: number;
blueprints: number;
// Buildings (keyed by building ID)
buildings: Record<string, BuildingState>;
// Combat
currentWave: number;
enemyHP: number;
enemyMaxHP: number;
// Prestige
prestigeLevel: number;
permanentUpgrades: Record<string, number>;
// Meta
lastSaveTime: number;
totalPlayTime: number;
}
Persistence - AsyncStorage serializes game state on every save (auto-save every 30 seconds + on app background). Save files are versioned for migration support when game balance changes.
Game Balance & Formulas
Enemy HP Scaling - Exponential growth with boss multipliers:
const baseHP = 100;
const growthRate = 1.15;
const bossMultiplier = wave % 10 === 0 ? 5 : 1;
const hp = baseHP * Math.pow(growthRate, wave) * bossMultiplier;
// Wave 1: 100 HP
// Wave 50: ~108,000 HP
// Wave 100 (boss): ~2,500,000 HP
Building Costs - Soft exponential with diminishing returns:
const baseCost = buildingData.baseCost;
const costMultiplier = 1.12;
const cost = baseCost * Math.pow(costMultiplier, level);
Prestige Blueprint Formula - Based on highest wave reached:
const blueprints = Math.floor(Math.pow(highestWave / 10, 1.5));
Animation System
react-native-reanimated - All animations run on the UI thread via worklets, ensuring 60fps even during intense combat. Key animations:
- Enemy health bar (interpolated width)
- Damage numbers (spring physics, fade out)
- Building construction (scale + rotation)
- Wave clear celebration (particle burst)
Performance Optimizations:
- Damage numbers pooled and recycled (max 20 active)
- Enemy sprites use shared animated values
- Building renders memoized with React.memo
- Game loop uses requestAnimationFrame for consistent timing
Testing Strategy
1,114 Jest Tests covering:
- Unit tests for all game formulas
- Integration tests for system interactions
- Snapshot tests for component rendering
- Edge cases (wave 100, max prestige, overflow scenarios)
Test structure mirrors src/ directory:
tests/
systems/
CombatSystem.test.ts
WaveManager.test.ts
...
stores/
gameStore.test.ts
data/
buildingData.test.ts
balanceFormulas.test.ts
Mobile-Specific Features
- iOS/Android parity - Identical behavior on both platforms
- Safe area handling - UI respects notches and home indicators
- Background detection - Triggers auto-save when app backgrounds
- In-app purchases - Optional cosmetics via react-native-iap
- No network required - Fully offline-capable