feat(physics): port retail complete object frame pipeline
Restore the named-retail object update order across local, remote, static, projectile, animation, shadow, teleport, and effect lifetimes. Separate authoritative root commits from spatial rebucketing, preserve per-owner hook/FIFO ordering, and remove update-path allocations with exact lifecycle and residency gates. Add deterministic conformance, adversarial lifetime, GUID-reuse, pending-cell, quaternion, timestamp, and allocation coverage. Release build is warning-free and all 6,446 tests pass with five intentional skips; retail, architecture, and adversarial reviews are clean. Co-authored-by: OpenAI Codex <codex@openai.com>
This commit is contained in:
parent
31a0889f08
commit
f961d70023
77 changed files with 12513 additions and 1871 deletions
|
|
@ -11,15 +11,11 @@ namespace AcDream.App.Input;
|
|||
/// </summary>
|
||||
public sealed class LocalPlayerOutboundController
|
||||
{
|
||||
private readonly Func<float, Quaternion> _toWireRotation;
|
||||
private readonly Action<string, uint, MovementResult, Vector3, uint, byte> _diagnostic;
|
||||
|
||||
public LocalPlayerOutboundController(
|
||||
Func<float, Quaternion> toWireRotation,
|
||||
Action<string, uint, MovementResult, Vector3, uint, byte> diagnostic)
|
||||
{
|
||||
_toWireRotation = toWireRotation
|
||||
?? throw new ArgumentNullException(nameof(toWireRotation));
|
||||
_diagnostic = diagnostic
|
||||
?? throw new ArgumentNullException(nameof(diagnostic));
|
||||
}
|
||||
|
|
@ -38,14 +34,13 @@ public sealed class LocalPlayerOutboundController
|
|||
if (session is null || hidden)
|
||||
return;
|
||||
|
||||
Quaternion wireRotation = _toWireRotation(controller.Yaw);
|
||||
if (!controller.TryGetOutboundPosition(
|
||||
wireRotation,
|
||||
out uint wireCellId,
|
||||
out Vector3 wirePosition))
|
||||
if (!controller.TryGetOutboundPosition(out Position outboundPosition))
|
||||
{
|
||||
return;
|
||||
}
|
||||
uint wireCellId = outboundPosition.ObjCellId;
|
||||
Vector3 wirePosition = outboundPosition.Frame.Origin;
|
||||
Quaternion wireRotation = outboundPosition.Frame.Orientation;
|
||||
|
||||
if (movement.ShouldSendMovementEvent)
|
||||
TrySendMovement(session, controller, movement);
|
||||
|
|
@ -82,16 +77,14 @@ public sealed class LocalPlayerOutboundController
|
|||
if (session is null || hidden)
|
||||
return;
|
||||
|
||||
Quaternion wireRotation = _toWireRotation(controller.Yaw);
|
||||
if (!controller.TryGetOutboundPosition(
|
||||
wireRotation,
|
||||
out uint wireCellId,
|
||||
out Vector3 wirePosition))
|
||||
if (!controller.TryGetOutboundPosition(out Position position))
|
||||
{
|
||||
return;
|
||||
}
|
||||
uint wireCellId = position.ObjCellId;
|
||||
Vector3 wirePosition = position.Frame.Origin;
|
||||
Quaternion wireRotation = position.Frame.Orientation;
|
||||
|
||||
var position = new Position(wireCellId, wirePosition, wireRotation);
|
||||
if (!controller.ShouldSendPositionEvent(
|
||||
position,
|
||||
controller.ContactPlane,
|
||||
|
|
@ -136,14 +129,13 @@ public sealed class LocalPlayerOutboundController
|
|||
if (session is null || controller is null)
|
||||
return false;
|
||||
|
||||
Quaternion wireRotation = _toWireRotation(controller.Yaw);
|
||||
if (!controller.TryGetOutboundPosition(
|
||||
wireRotation,
|
||||
out uint wireCellId,
|
||||
out Vector3 wirePosition))
|
||||
if (!controller.TryGetOutboundPosition(out Position outboundPosition))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
uint wireCellId = outboundPosition.ObjCellId;
|
||||
Vector3 wirePosition = outboundPosition.Frame.Origin;
|
||||
Quaternion wireRotation = outboundPosition.Frame.Orientation;
|
||||
|
||||
byte contactByte = movement.IsOnGround ? (byte)1 : (byte)0;
|
||||
RawMotionState rawMotionState = BuildRawMotionState(movement);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue