feat(runtime): own initial create residence transaction

This commit is contained in:
Erik 2026-08-01 19:35:08 +02:00
parent 74103f75b5
commit 38fd4b8dc9
10 changed files with 3031 additions and 17 deletions

View file

@ -102,6 +102,25 @@ public sealed class PhysicsTimestampGate
return CreateObjectTimestampDisposition.ExistingGeneration;
}
/// <summary>
/// Classifies an incoming CreateObject generation without consuming any
/// channel timestamp. Runtime uses this to preflight only admissions which
/// can create or replace a canonical incarnation; equal/stale packets must
/// still reach the normal per-channel retail gates unchanged.
/// </summary>
public CreateObjectTimestampDisposition PreviewCreateObject(
ushort instance)
{
if (!_seeded)
return CreateObjectTimestampDisposition.InitialGeneration;
ushort currentInstance = _timestamps[Instance];
if (IsNewer(currentInstance, instance))
return CreateObjectTimestampDisposition.NewGeneration;
if (IsNewer(instance, currentInstance))
return CreateObjectTimestampDisposition.StaleGeneration;
return CreateObjectTimestampDisposition.ExistingGeneration;
}
public bool TryAcceptMovementEvent(
ushort instance,
ushort movement,