Commit graph Aetheria/tests/Aetheria.Shared.Tests/FloatingBodyTests.cs
Author SHA1 Message Date
Meta Vens
c4dfd905ff Gravity: the Planet guard refuses an unphysical well; tests pin the Roche rule, per-body multipliers, the core band and Ship's order
A WellStrength that evaluates negative, NaN or infinite now throws at construction (it built an
antimass well with NaN height). New tests: the core-inside-Roche guard judged at every mass on
curves that cross in the generated range; per-body multipliers move neither strength, core nor
Roche limit; potential and force consistency inside the cores' outer bands (0.5 R to R); a
moving Ship feels the field where it has moved to.

Not built or run locally; verified in the Yggdrasil job.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 06:36:02 +02:00
Meta Vens
dd06f39dbc FloatingBodyTests: the tilt expectation is spelled from force and K, not read back from GetNormal
Two hand mutants of GetNormal's K (ignored; times 3) survived because the test compared the ship's
tilt with the same GetNormal it was testing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 05:40:10 +02:00
Meta Vens
41e90d0e40 GravityField: a well of no strength digs nothing (c = 0, R = 0 gave NaN height)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 05:02:48 +02:00
Meta Vens
021c4cbcbf Gravity: one potential per zone owns acceleration and height
GravityField is the law of one well (logarithmic tail, softened core).
Zone.GetForce and GetHeight sum it over the bodies; GetNormal derives from
the force for ship tilt; Flow and Ship read GetForce. Well strength, core
radius and Roche limit are PlanetSettings curves of mass, height
exaggeration K one global. Deletes GravityAcceleration, GravityReferenceRate,
GravityStrength, the PowerPulse well, GetNormal's finite differences and
BodyData.GravityDepthExponent. Settings.asset carries the calibrated curves.
Tests: PotentialOwnerTests, the moon's moon placement, retired keys over every
BodyData type, a body-derived giant sweep. Not yet built or run (verify job
follows); this commit may not build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 04:36:28 +02:00
Meta Vens
55d5566743 Gravity subtract tests: open the fixtures' caches with a run store
OrbitData and BodyData are run-store types; a cache opened with a catalog
only has no home for the well body. The six fixtures that dig a well now
open with a run path. The previous commit does not pass its tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-14 19:47:32 +02:00
Meta Vens
7d3fb29ed2 Gravity subtract: delete the zone bowl and the gas-giant and sun ripples
GetHeight sums body wells only. Removes RadialWaves, GasGiant wave fields,
GasGiantData keys 14-17, PlanetSettings Zone*/Wave* fields, the minimap
gravity range, the Boundary brush and Gravity Waves objects from the scene
and both prefabs. The five bowl fixtures become one WellFixture well at the
origin with unchanged expected numbers. Not yet built or tested: this commit
has not been through the Yggdrasil job.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-14 19:34:20 +02:00
Meta Vens
fa911f2d85 Zone.Entities read-only outside Zone: Admit and Remove are the only membership writers
Entities is a MemberView with no mutating member; Admit installs the death watch with the
membership and refuses a member already present, Remove takes it away with the membership.
The Reset and duplicate-Add bypass paths of the death watch cannot be spelled any more.
Tests move to Admit/Remove; Admit also activates, so the explicit Activate calls that followed
a raw Add are dropped. Unity call sites route through Zone.Remove.

Builds: unverified at this commit (verified in the job at the head).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 02:13:43 +02:00
Meta Vens
df53360aa3 FloatingBodyTests: set Ship.Aim where the fixture set LookDirection
The helm split removed LookDirection. The ship-gravity test asserts only Velocity
after Update, so it needs no facing; Aim keeps the value the fixture carried
(Direction already defaults to the same +z facing).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 20:11:08 +02:00
Meta Vens
6299627b72 FloatingBodyTests: pin Ship.Update's gravity line through a real ship in a real well
Ship at +x in an empty zone with a slope: velocity after Update(delta) equals the
3035230b ship law scaled by delta * 60, at 1/60 and 1/30. Fails on `-=` and on a
changed delta factor.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 18:49:20 +02:00
Meta Vens
4dea45bb19 FloatingBodyTests: the legacy drift table is keyed by the normal's length, not its square
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 17:43:08 +02:00
Meta Vens
6c15a33315 Tests: pin For's double mix against the single-xor collapse and Commit's | 1u seed bit
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 17:32:55 +02:00
Meta Vens
d62d44cb99 One gravity law in Zone: ships and floating bodies read Zone.GravityAcceleration
The law ships felt (normalize(f) * strength * (1/(1-|f|^2) - 1), gated at |f|^2 .001) is
now Zone.GravityAcceleration, per second via a 60 Hz reference rate; Ship.Update applies it
times delta, so ships push as before at 60 fps. Zone.GetForce's separate law is gone and
delegates to it. Floating-body drift at 60 fps now matches the legacy GridObject magnitude.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 17:32:53 +02:00
Meta Vens
5919c31948 FloatingBodyTests: pin one step's position and the zero-seed remap, the two Stryker survivors
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 15:49:14 +02:00
Meta Vens
83bf1af106 FloatingBodyTests: launch-speed pin sized to the step's position error bound
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 15:03:12 +02:00
Meta Vens
38c47d80ed Floating bodies: FloatingBodyId, KinematicBody.Step, Zone.NextBodyId and the three drift settings
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-07 14:52:12 +02:00