Files
transcience/.githooks/pre-push
T
claude c4beeae38f 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
2026-09-03 16:03:57 +02:00

23 lines
681 B
Bash
Executable File

#!/usr/bin/env bash
# The one check that needs a real socket: boot a dedicated server, connect two
# bot clients over ENet, and assert the whole loop happened. ~35s, so it runs
# on push rather than every commit.
#
# Skip deliberately (e.g. pushing docs-only or WIP) with:
# SKIP_SMOKE_HOOK=1 git push
set -uo pipefail
cd "$(git rev-parse --show-toplevel)"
if [[ "${SKIP_SMOKE_HOOK:-0}" == "1" ]]; then
echo "pre-push: SKIP_SMOKE_HOOK=1, skipping smoke test"
exit 0
fi
echo "pre-push: running tools/smoke.sh..."
if ! tools/smoke.sh; then
echo
echo "pre-push FAILED: end-to-end smoke test did not pass."
echo "Push anyway with: SKIP_SMOKE_HOOK=1 git push"
exit 1
fi