Initial commit: Transcience MVP

Top-down twin-stick bullet-hell, Godot 4.7, server-authoritative dedicated
server with client-side prediction. Clients send input only; the server
resolves every hit for both players and enemies (no PvP).

- SimWorld: whole simulation as plain RefCounted objects (no nodes, no
  physics server), ~0.24ms/tick at peak load -- runs headless for free and
  drives 78 tests in under a second
- BulletPool: struct-of-arrays bullet storage, replicated as spawn/despawn
  events rather than per-tick state
- Emitter framework (Ring/AimedSpread/WallGap/ArcSweep) shared by trash
  enemies and bosses -- a new boss is data in src/content/content.gd, no
  simulation changes
- The Warden of the Fold: stationary 4-phase boss built entirely on that
  format
- Lobby hub with a portal into on-demand dungeon instances; one process
  hosts the hub plus every concurrent dungeon
- Emergency escape: 3s server-owned channel, cancelled by damage
- tools/check.sh, test.sh (GUT), smoke.sh (real server + bot clients over
  ENet), bench.gd; git hooks wired to the same scripts
- docs/ARCHITECTURE.md, NETCODE.md, WORKFLOW.md, ROADMAP.md
This commit is contained in:
2026-09-03 16:03:57 +02:00
commit c4beeae38f
385 changed files with 28725 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
class_name EmitContext
extends RefCounted
## Everything an emitter is allowed to see. Keeping this narrow is what lets a
## unit test fire a boss pattern into a bare [BulletPool] with no world at all.
var pool: BulletPool
## Where the shots come from (the emitting actor's position).
var origin := Vector2.ZERO
## Nearest live player, used by aimed emitters. Falls back to [member origin]
## plus a down vector when nobody is alive.
var target := Vector2.ZERO
var has_target := false
## Ticks since the emitting actor entered its current phase.
var local_tick := 0
## How many times this emitter has fired in this phase. Drives spin/step.
var shot_index := 0
var rng: RandomNumberGenerator
func aim_angle() -> float:
if not has_target:
return PI * 0.5
return (target - origin).angle()