Skip to content

Implement unit spawning from main base

Objective

Create unit production system that allows bases to spawn units automatically for MVP gameplay, providing foundation for combat scenarios.

Requirements

  • Auto Production: Main bases periodically produce basic units
  • Resource Cost: Unit production consumes appropriate resources
  • Spawn Logic: Units appear near base without overlapping
  • Ownership: Units are properly assigned to player/AI that created them

Technical Details

  • Implement unit spawning queues and timers
  • Add spawn point management around bases
  • Create unit ownership and faction assignment
  • Handle resource deduction for unit costs
  • Add spawn collision detection
  • Implement production rate configuration

Acceptance Criteria

  • Units spawn automatically from player and AI bases
  • Unit production costs resources appropriately
  • Units spawn without overlapping existing entities
  • Spawned units are assigned correct ownership
  • Production rate is configurable and balanced

Milestone Relation

Core gameplay mechanic for MVP. Required for establishing basic combat forces and enabling player vs AI battles.