AnimalKingdom
Modular farm simulation demonstrating reusable generic systems (popup framework, pooling, state machine) designed for cross-project deployment.
Install / Use
/learn @mohsansaleem/AnimalKingdomREADME
Animal Kingdom
Modular Farm Simulation with Reusable Generic Systems
A technical demonstration of scalable, modular architecture designed for rapid feature expansion. Showcases production-grade patterns including generic popup systems, state machines, and persistent game state—techniques refined over 10+ years building mobile titles at Ubisoft and other studios.
🎥 Demo
🎮 Core Gameplay
Resource Gathering – Explore the map to collect animals
Economic Loop – Convert captured animals to cash at the farm
Persistent State – Save/load game progress with metadata-driven configuration
🏗️ Technical Architecture
Scalable Design Patterns:
- MVP Architecture – Strict separation enabling parallel development
- Generic Popup System – Reusable UI framework for dialogs and notifications
- State Machine – Clean state transitions (Gathering, Navigation, Farm Management)
- Generic Object Pooling – Memory-optimized entity management
- Dependency Injection (Zenject) – Modular components with minimal coupling
- Reactive Programming (UniRx) – Event-driven updates for responsive UI
- Promise-based Async – Non-blocking operations for smooth gameplay
Data Architecture:
- Context-driven scene management (Bootstrap → MainHub → GamePlay)
- Metadata vs GameState separation for clean persistence
- ScriptableObject-based configuration for designer workflows
- JSON serialization for save/load functionality
📁 Project Structure
Assets/
├── Scripts/
│ ├── AnimalKingdom/
│ │ ├── Contexts/ # Controllers
│ │ ├── Views/ # UI and presentation layer
│ │ ├── Models/ # Data, RemoteData, RemoteDataModels
│ │ └── Commands/ # Game actions and operations
│ └── Core/ # Reusable generic abstractions (submodule)
├── Scenes/ # Scene files
└── Resources/Scenes/ # Scene-specific resources
🔧 Tech Stack
| Technology | Purpose | |-----------|---------| | Unity 2019.4.0f1 | LTS game engine | | Zenject | Dependency injection framework | | UniRx | Reactive extensions | | C# Promises | Asynchronous operations |
🚀 Quick Start
- Clone the repository
- Open with Unity 2019.4.0f1+
- Enable Always Start from Startup Scene in
/MainMenu/Game/ - Press Play
Note: Delete StreamingAssets/GameState.json and MetaData.json to reset after modifying ScriptableObjects.
🎯 Generic Systems Highlight
Reusable Popup Framework – Modal dialog system used across multiple projects
Universal Pooling System – Generic pooling applicable to any GameObject type
Flexible State Machine – Adaptable state management for various game modes
These systems demonstrate production-ready code designed for reusability across multiple titles—a critical skill for mobile game development where rapid iteration drives success.
💼 About the Developer
Senior Game Developer with 10+ years specializing in mobile game architecture and reusable systems. Experience includes:
- Ubisoft – Mobile titles including Clash of Beasts (war strategy)
- Custom editor tools reducing designer iteration time
- Generic systems deployed across multiple production titles
- Persistent state management for millions of players
📫 Connect
Building scalable architectures for mobile games or rapid prototyping systems? Let's connect.
Topics
unity3d mvp-architecture zenject unirx state-machine promises asynchronous-programming gamestate popup pooling
Related Skills
tmux
330.3kRemote-control tmux sessions for interactive CLIs by sending keystrokes and scraping pane output.
blogwatcher
330.3kMonitor blogs and RSS/Atom feeds for updates using the blogwatcher CLI.
Unla
2.1k🧩 MCP Gateway - A lightweight gateway service that instantly transforms existing MCP Servers and APIs into MCP servers with zero code changes. Features Docker deployment and management UI, requiring no infrastructure modifications.
mcp-server-code-execution-mode
317An MCP server that executes Python code in isolated rootless containers with optional MCP server proxying. Implementation of Anthropic's and Cloudflare's ideas for reducing MCP tool definitions context bloat.

