Commit Graph

9 Commits (eb6a4feddebd94b011d0634b5a7ae65d34285b5e)

Author SHA1 Message Date
Don 047237e651 NEO-91: address code review follow-ups
Add legacy alpha targeting integration test, elite HP assertion, AAA fix,
Bruno docs refresh, and module/alignment doc updates. Strike through
resolved items in the NEO-91 review.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-26 23:46:39 -04:00
Don fa9acc85ac NEO-91: migrate combat targets to three NPC instances
Replace alpha/beta dummies with PrototypeNpcRegistry (melee/ranged/elite),
per-archetype max HP from INpcBehaviorDefinitionRegistry, and updated
server tests + Bruno smokes. Documents breaking client change for NEO-97.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-26 23:42:31 -04:00
VinPropane e6ccc4453c chore: Apply Arrange/Act/Assert across server and client tests.
Split HTTP verification reads into Assert in C# API and integration tests.
Add # Arrange/# Act/# Assert to GdUnit suites and keep Act free of assertions
where casts and busy guards are under test.
2026-04-27 22:09:35 -04:00
VinPropane 9ac4f27ea2 NEO-29: resolve follow-up review regressions
Fix the hotbar client test transport body construction so the suite parses and runs again, and normalize AAA marker ordering in the flagged C# tests to restore readability consistency with the test template.
2026-04-25 23:26:25 -04:00
VinPropane 71af7a5942 NEO-29: normalize test formatting across server and client suites
Audit all test files and bring them in line with formatting/style expectations by adding explicit AAA markers across server test methods and fixing GDScript test lint/format issues.
2026-04-25 22:57:05 -04:00
VinPropane d6ef4fd811 NEO-24: race-free target/select via optional positionHint
Followup #5: after locking alpha, walking into beta's ring, stopping and
pressing Tab could still return `out_of_range` even when client and server
agreed on position (Δ=0). The freshness-kick move-stream POST and the
target/select POST race on separate HTTP connections so the select can be
validated against a stale stored snap.

Extend TargetSelectRequest v1 with an optional positionHint {x,y,z}.
Server uses the hint for the radius check and for the echoed
targetState.validity; the hint is advisory and does not write to the
position store (move-stream stays the sole write path). Client attaches
the hint automatically whenever set_freshness_kick(...) is wired, so
headless unit tests that skip the wiring fall through to the no-hint
behavior. Freshness kick is kept in place to refresh the stored snap for
later validity GETs but is no longer load-bearing for denial correctness.

Server: 3 new tests (hint accepts when stored is stale, hint-far denies,
hint never writes to position store). Client: 1 new test asserting the
hint is in the POST body when wired. All 62 server + 96 client tests
pass.

Plan Decision 8, review follow-up #5, manual QA section 6, and NEO-23
contract notes updated. New bruno request exercises the hint path.
2026-04-21 23:52:20 -04:00
VinPropane a7453eb82f NEO-24: unify prototype target radius at 6 m, overlap rings at origin
All prototype targets now share `PrototypeTargetRegistry.SharedLockRadius`
(= 6 m). Anchors moved to alpha `(-3, 0.5, -3)` and beta `(3, 0, 3)` so
the two 6 m rings overlap ~3.5 m wide centered at origin, letting Tab
flip between targets without locomotion. Spawn `(-5, -5)` keeps alpha
in range (~2.83 m) and beta out (~11.31 m) so the existing soft-lock
denial QA path at spawn still holds.

`prototype_target_constants.gd` mirrors the shared radius + new anchors.
The range-aware Tab picker now **skips the currently-locked id** so Tab
always expresses a swap intent — if the only in-range target is already
locked, the fallback picks the next cycle id and the server denies
(preserves NEO-23's "Tab = visible denial when no swap possible" rule).

Tests:
- Server: new `PlayerTargetStateReaderTests.ComputeValidity_AtOrigin_…`
  asserts both targets report `Ok` at origin. Existing boundary test
  rewritten for the new alpha anchor.
- Client: new `test_tab_from_locked_alpha_at_origin_swaps_to_beta_when_both_in_range`
  and `test_tab_when_only_current_lock_is_in_range_falls_back_to_cycle_for_denial`.
  Existing in-range/out-of-range positions updated for the new layout.

Server 59/59 and client 95/95 suites pass.

Plan Decision 7, review follow-up #4, manual QA section 5 (new "Tab-flip
at origin" overlap sanity), and README updated. Per-target radii will
return with real combat design (E5.M1) — this is a prototype stub.
2026-04-21 23:37:42 -04:00
VinPropane 17f87aa747 NEO-23: code review follow-up (E1.M3 docs, GET 404 test, radius bounds) 2026-04-17 21:14:43 -04:00
VinPropane 465c4b14eb NEO-23: add targeting HTTP API (TargetState v1, select intent) 2026-04-17 21:06:59 -04:00