diff --git a/engine/match.go b/engine/match.go index 487a748..e863bef 100644 --- a/engine/match.go +++ b/engine/match.go @@ -255,11 +255,18 @@ func (mr *MatchRunner) generateMap(gs *GameState, numPlayers int) { } // Place cores for each player using rotational symmetry. - // Very tight spawn radius (25% from center) forces immediate bot contact. - // At 25% radius on 54x54 grid: ~7 tiles from center, ~12 tiles between 3 players. - // Attack radius is 3 tiles, so bots need to close ~9 tiles to engage. - primaryRadius := 0.25 - secondaryRadius := 0.15 + // Tight spawn radius forces immediate bot contact. + // For 2 players: 20% from center (~8 tiles on 40x40) → ~16 tiles apart at spawn + // For 3+ players: 25% from center (~7 tiles on 54x54) → ~12 tiles apart at spawn + // Attack radius is 3 tiles, so bots need to close ~10 tiles to engage. + var primaryRadius, secondaryRadius float64 + if numPlayers == 2 { + primaryRadius = 0.20 // Tighter for 2-player to force contact + secondaryRadius = 0.12 + } else { + primaryRadius = 0.25 + secondaryRadius = 0.15 + } halfRows := float64(centerRow) halfCols := float64(centerCol) diff --git a/engine/types.go b/engine/types.go index da2c277..8f6fbb0 100644 --- a/engine/types.go +++ b/engine/types.go @@ -235,11 +235,17 @@ func ConfigForPlayers(numPlayers, coresPerPlayer int) Config { // Scale energy nodes with player count cfg.EnergyInterval = 10 - // Scale zone parameters for 3+ players to force combat contact - // 2-player matches naturally converge at center; 3+ need aggressive zone + // Scale zone parameters to force combat contact // Zone must compress bots into contact range while preserving enough population for combat - // Tight spawn radius (0.25) means bots start very close; zone finishes the job - if numPlayers >= 3 { + // For 2-player: start later to allow buildup, then shrink aggressively + // Also increase attack radius for 2-player to make combat more likely + if numPlayers == 2 { + cfg.ZoneStartTurn = 30 // Allow time for bots to spawn and move + cfg.ZoneShrinkInterval = 2 // Shrink every 2 turns (faster than 3+) + cfg.ZoneShrinkStep = 2 // Shrink 2 tiles per interval (1 tile/turn) + cfg.ZoneMinRadius = 3 // Tight final zone forces contact + cfg.AttackRadius2 = 12 // 3.5 tiles (balanced for 2-player) + } else { cfg.ZoneStartTurn = 15 // Start zone early (bots already close at spawn) cfg.ZoneShrinkInterval = 3 // Shrink every 3 turns (vs default 5) cfg.ZoneShrinkStep = 3 // Shrink 3 tiles per interval (1 tile/turn)