Struct GridNavigationPortal
Stores one exact, agent-independent navigation crossing compiled from two cell prisms.
public readonly struct GridNavigationPortal
- Inherited Members
Remarks
The value retains no live grid state. Profile resolution uses only the stored face geometry, direction, and conservative fixed-point capacities.
Fields
SizeInBytes
The stable retained value size used by exact byte-accounted storage.
public const int SizeInBytes = 104
Field Value
Properties
CanonicalFacePoint
The canonical foot crossing on the shared face.
public Vector3d CanonicalFacePoint { get; }
Property Value
- Vector3d
FaceKind
The orientation of the shared positive-area face.
public VoxelContactFaceKind FaceKind { get; }
Property Value
IsValid
Whether this value contains a compiled positive-area navigation face.
public bool IsValid { get; }
Property Value
MaximumBodyHeight
The greatest body height supported by both directed sides of the crossing.
public Fixed64 MaximumBodyHeight { get; }
Property Value
- Fixed64
MaximumHorizontalRadius
The greatest conservatively representable horizontal body radius at the crossing.
public Fixed64 MaximumHorizontalRadius { get; }
Property Value
- Fixed64
SourceToTarget
The exact target-center displacement from the source center.
public Vector3d SourceToTarget { get; }
Property Value
- Vector3d
VerticalFaceSegmentEnd
The second exact XZ endpoint certifying a compiled vertical face.
public Vector2d VerticalFaceSegmentEnd { get; }
Property Value
- Vector2d
VerticalFaceSegmentStart
The first exact XZ endpoint certifying a compiled vertical face.
public Vector2d VerticalFaceSegmentStart { get; }
Property Value
- Vector2d
Methods
TryResolveProfile(Fixed64, Fixed64, out Vector3d, out Vector3d)
Attempts to fit a fixed-point body profile and resolve its directed source and target foot anchors.
public bool TryResolveProfile(Fixed64 horizontalRadius, Fixed64 bodyHeight, out Vector3d sourceFootAnchor, out Vector3d targetFootAnchor)
Parameters
horizontalRadiusFixed64The required nonnegative horizontal body radius.
bodyHeightFixed64The required positive body height.
sourceFootAnchorVector3dThe last canonical foot anchor on the source side.
targetFootAnchorVector3dThe first canonical foot anchor on the target side.
Returns
TryTranslate(Vector3d, out GridNavigationPortal)
Attempts to rigidly translate the canonical face point without fixed-point saturation.
public bool TryTranslate(Vector3d offset, out GridNavigationPortal translated)
Parameters
offsetVector3dThe exact translation applied to the canonical face point.
translatedGridNavigationPortalThe translated portal, or default on failure.