revert(teleport): drop the Slice 2 outdoor readiness-gate hold

User-tested: the Slice 2 'hold outdoor until landblock loaded' gate made
EVERY outdoor teleport a ~10 s freeze, because the destination landblock
does NOT load fast during the hold (lbs=0 the whole time — the #138
streaming gap + _datLock starvation from the CreateObject flood). The hold
was band-aiding a broken/slow foundation rather than fixing it, and it never
actually prevented the #145 edge cascade anyway (it force-snapped onto
NO-LANDBLOCK after the timeout regardless).

Reverts ad8c24e..c880973 to the pre-Slice-2 state (00ef47e): outdoor places
immediately again (fast teleports). The genuine bug found along the way —
IsLandblockLoaded queried the wrong key form (& 0xFFFF0000 vs the stored
| 0xFFFF) — is preserved in the history (c880973) and will be re-applied when
we re-introduce a proper hold ON A FIXED FOUNDATION.

Decision (user, 2026-06-21): fix the foundation FIRST — fast/complete
streaming during teleport (#138), the post-teleport lost-collision bug, and
the FPS leak (Work item C) — then revisit the teleport-flow animation. Slice 1
(the pure TeleportAnimSequencer) stays in (dormant, unwired, harmless).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Erik 2026-06-21 21:46:24 +02:00
parent c8809735f3
commit dd2eb8b39d
6 changed files with 43 additions and 195 deletions

View file

@ -31,19 +31,6 @@ public static class PhysicsDiagnostics
public static bool ProbeResolveEnabled { get; set; } =
Environment.GetEnvironmentVariable("ACDREAM_PROBE_RESOLVE") == "1";
/// <summary>
/// Retail teleport readiness gate (§3.4, 2026-06-21). When true, every transition of
/// the <c>TeleportArrivalReadiness</c> verdict (NotReady → Ready / Impossible) emits one
/// <c>[arrival-gate]</c> line: the destination cell id, landblock id, verdict,
/// <c>PhysicsEngine.LandblockCount</c> at the moment it flips, and whether the
/// flip was forced (Impossible) or natural (Ready).
///
/// <para>Initial state from <c>ACDREAM_PROBE_RESOLVE=1</c> — shares the existing probe
/// flag because this is a readiness-path extension; no new env var needed.</para>
/// </summary>
public static bool ProbeArrivalGateEnabled { get; set; } =
Environment.GetEnvironmentVariable("ACDREAM_PROBE_RESOLVE") == "1";
/// <summary>
/// When true, every change to <c>PlayerMovementController.CellId</c>
/// emits one <c>[cell-transit]</c> line: old → new cell, current
@ -547,7 +534,6 @@ public static class PhysicsDiagnostics
public static void ResetForTest()
{
ProbeResolveEnabled = false;
ProbeArrivalGateEnabled = false;
ProbeCellEnabled = false;
ProbeBuildingEnabled = false;
ProbeCellSetEnabled = false;

View file

@ -31,25 +31,6 @@ public sealed class PhysicsEngine
/// <summary>Number of registered landblocks (diagnostic).</summary>
public int LandblockCount => _landblocks.Count;
/// <summary>
/// Returns true iff the landblock CONTAINING the given id has been registered via
/// <see cref="AddLandblock"/>. Because <see cref="AddLandblock"/> registers terrain +
/// collision cells + portals atomically, a hit implies the collision mesh is present
/// and resolvable.
/// <para>
/// The argument may be any id within the landblock — a full cell id (low 16 = cell
/// index), the landblock-prefix form (low 16 = 0x0000, as the teleport gate passes via
/// <c>destCell &amp; 0xFFFF0000</c>), or the dat-id storage form. The low 16 bits are
/// normalized to the canonical landblock key (<c>0xFFFF</c>) that streaming stores under
/// (<see cref="AcDream.App.Streaming.StreamingRegion.EncodeLandblockId"/> ORs in 0xFFFF),
/// so all three forms resolve. The earlier raw <c>ContainsKey(id &amp; 0xFFFF0000)</c>
/// never matched the 0xFFFF-terminated stored key, leaving the outdoor teleport gate
/// permanently NotReady (2026-06-21 #145 apparatus re-test).
/// </para>
/// </summary>
public bool IsLandblockLoaded(uint landblockId) =>
_landblocks.ContainsKey((landblockId & 0xFFFF0000u) | 0xFFFFu);
/// <summary>
/// Cell-based spatial index for static object collision.
/// Populated during landblock streaming; queried by the Transition system.