Commit graph Aetheria/tests/Aetheria.Shared.Tests/PickupTests.cs
Author SHA1 Message Date
Meta Vens
a89d30376d Fix merge build: contact reveal tests remove through Zone.Remove; PickupTests settings drop the retired TargetArmorInfoThreshold
The merge commit before this does not build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 08:31:27 +02:00
Meta Vens
4fba95e56f Pickup: one beam region for selection and the pre-pull cancel; selection skips what no bay can store; test gaps and the phase rule pinned
beam-corner-claim-loop: InBeam is the one region predicate; Select claims from it and the pre-pull cancel holds the item only while it stays in it (an item at 74 along, 20 off is collected, not claimed and dropped every other tick).
full-hold-regrab-pins-and-blocks: Select skips an item no cargo bay can store whole, asked of the bay's own TryFindSpace (the test TryStore opens with), per ruling beam-skips-unstorable-items; a hold that fills mid-grab still cancels at the end.
pickup-test-gaps: smoothstep pose, spin-down while the gear is inactive, Remove freeing only the removed holder's items.
phase-ticks-not-rate-invariant: the claim is corrected in the tests; each phase fires on the first tick at or after its boundary, pinned at 1/60, 1/600 and an uneven dt cycle.

Builds; not yet run (the verify job follows).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 07:43:42 +02:00
Meta Vens
8e3dd3129d PickupTests: assert on booleans, never on an Entity (a failing Assert.Same prints the whole entity graph and crashes the test host)
Found by the mutation table: two mutants read 'Test Run Aborted' instead of naming the failing test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 07:07:03 +02:00
Meta Vens
60b5876cd9 PickupTests: bounded waits (a broken rule fails instead of hanging the run); a stray item is never even attempted
Found by the mutation table: a mutant that never claims hung the test host, and a mutant that doubled the
range survived because the observation landed between two attempts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 07:01:35 +02:00
Meta Vens
359aba2c5d PickupTests: each grab phase is published on the tick its boundary is crossed
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 05:54:08 +02:00
Meta Vens
720fbd6431 PickupTests: gear off, range before the pull, the loser's next item, a held item's pose
Pins the cancel rules (inactive gear, out of range before the pull and not after it), TryHold refusing a held
item, the next-item selection, and the held pose as a function of progress.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 05:50:46 +02:00
Meta Vens
68430771f3 Every generated ship carries a tractor beam; AetherDb pickup-catalog turns the Tractor Beam into Pickup gear (group B, code)
GenerateShipLoadout equips one gear whose behaviours include PickupData after the shared outfitting
(stations and turrets get none). The pickup-catalog command (retired in the next commit after apply) edits
the existing Tractor Beam. PickupTests: two fixes found by group A's run (equip is refused once a ship is
deployed, and the freeing tick takes one step). PickupGenerationTests needs the applied catalog and is
red until the catalog commit; the catalog itself is not in this commit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 05:18:15 +02:00
Meta Vens
5aa989abbf Pickup is a capability: PickupData/Pickup run a timed grab through Zone's hold API and TryPickUp (group A, sim)
GrabEvent carries a FloatingBodyId; Zone gains TryHold/SetHeldProgress/Free and places a held item instead of
integrating it; Entity.TractorPower is derived from Pickup.Power and TractorCommand is the pilot's input
(ActionGameManager writes it undamped, the Time.deltaTime ramp is deleted). Binder and FieldTester change the
delegate type only. PickupTests and a save round-trip pin for the player's zone index.

Group A builds; no beam is on any generated ship until group B.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 05:00:22 +02:00