Add in-game chat, bot fill for casual, and borderless fullscreen
- In-game chat: T=all, Y=team (race doubles as team), server-relayed and team-filtered via new ChatManager autoload; last 10 messages shown bottom-left (chat/chat_box.gd). - Bot fill for casual (bots/): keeps each of the match's 2 offered races at a minimum of 7 total humans+bots, spawning/despawning reactively as players join/leave. Bots always fly their race's fighter and use negative peer_ids so they ride the existing networked-ship stack (spawning, loadout sync, health/position sync, bullet attribution) with no special-casing. Casual matchmaking now forms with just 1 real player queued instead of waiting for a second (matchmaking-api/). - Borderless fullscreen with stretch scaling disabled instead of scaling the Steam-Deck-matched 1280x800 canvas up to fill PC monitors (which read as zoomed in) — PC monitors now reveal more world/HUD at native size instead. Reworked main_menu/team_select/chat_box to position via anchors relative to the real window instead of hardcoded coordinates. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
+22
-5
@@ -13,9 +13,26 @@
|
||||
- Avoids the ghost-town feeling of a 25v25 map with 3 players
|
||||
- Bots are not added beyond 7v7 so human players always dominate strategy
|
||||
|
||||
## Implementation Notes (not yet built)
|
||||
## Implementation Notes
|
||||
|
||||
- Bots use simplified AI: thrust toward nearest enemy, shoot when in range
|
||||
- Bot difficulty: intentionally easy (this is casual — bots are filler, not challenge)
|
||||
- Bot names: procedurally generated callsigns so they're not obviously bots in the HUD
|
||||
- Server tracks human vs bot count per team and manages swap-in on player join
|
||||
- **`bots/bot_manager.gd`** (server-authoritative autoload) owns bot lifecycle. All
|
||||
spawn/despawn decisions funnel through one function, `_reconcile_race(race_id)`,
|
||||
triggered by `PlayerRegistry`'s existing `loadout_updated`/`player_removed`
|
||||
signals (join/leave) and `World.decide_offered_races()` (match start) — no
|
||||
polling. This is the one place to change for future tweaks (fill curve, per-map
|
||||
team size, etc.)
|
||||
- Bots get **negative peer_ids** (`-1, -2, ...`), assigned by `BotManager`. This
|
||||
lets them reuse every existing networked-ship system for free — spawning
|
||||
(`MultiplayerSpawner`), loadout replication/backfill (`PlayerRegistry`),
|
||||
position/health/visibility sync, bullet damage attribution — none of which
|
||||
cares whether a `peer_id` came from ENet or from `BotManager`
|
||||
- Bots always fly **the race's fighter/Interceptor** (`race.ships[0]` in
|
||||
`team_select.gd`'s `RACES` data)
|
||||
- AI (`bots/bot_ai.gd`, `class_name BotAI`): thrust toward nearest living enemy,
|
||||
turn to face it, shoot when roughly aimed and in range — simplified
|
||||
seek-and-shoot, intentionally easy (casual bots are filler, not a challenge).
|
||||
Fully isolated from `ship_movement.gd`'s networking code so future
|
||||
difficulty/behavior tuning only ever touches this one file
|
||||
- Bot names: `bots/bot_names.gd`, a flat pool of procedural callsigns
|
||||
- Tunables live in `GameConfig` (`bot_min_team_size`, `bot_engage_range`,
|
||||
`bot_stop_distance`, `bot_aim_tolerance_deg`)
|
||||
|
||||
Reference in New Issue
Block a user