Class FieldLayout
SimWorld with FRC field geometry: a carpet floor
and four perimeter wall planes.
All bodies added by this class are static — they deflect game pieces and robots but cannot themselves be moved.
Coordinate frame: X points from the blue alliance wall toward the red alliance wall; Y points across the field; Z points up. This matches AdvantageScope's field rendering.
Wall implementation: Each wall is an infinite half-space PlaneCollider.
Infinite planes are always in the broadphase and use signed-distance narrowphase, so they are
completely immune to tunneling even when game pieces are launched at very high velocities.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final doubleFRC 2025/2026 field length (blue to red) in metres (54 ft).static final doubleFRC 2025/2026 field width in metres (27 ft). -
Method Summary
Modifier and TypeMethodDescriptionstatic voidAdd a configurable rectangular field (carpet floor + four perimeter wall planes) toworld.static voidAdd just the carpet floor (infinite plane at Z = 0) toworld.static voidaddFrcField(SimWorld world) Add a standard FRC field (carpet floor + four perimeter wall planes) toworld.static voidAdd four perimeter wall planes toworld.
-
Field Details
-
FRC_LENGTH_M
public static final double FRC_LENGTH_MFRC 2025/2026 field length (blue to red) in metres (54 ft).- See Also:
-
FRC_WIDTH_M
public static final double FRC_WIDTH_MFRC 2025/2026 field width in metres (27 ft).- See Also:
-
-
Method Details
-
addFrcField
Add a standard FRC field (carpet floor + four perimeter wall planes) toworld.- Parameters:
world- the world to populate
-
addField
Add a configurable rectangular field (carpet floor + four perimeter wall planes) toworld.- Parameters:
world- the world to populatelengthM- field length along X (metres)widthM- field width along Y (metres)
-
addFloor
Add just the carpet floor (infinite plane at Z = 0) toworld.- Parameters:
world- the world to populate
-
addWalls
Add four perimeter wall planes toworld.Each wall is a
PlaneCollider(infinite half-space) anchored at the corresponding field boundary and oriented so its normal points into the field. Plane colliders have unbounded AABBs and use signed-distance collision tests, making them immune to tunneling at any projectile speed.- Parameters:
world- the world to populatelengthM- field length along X (metres)widthM- field width along Y (metres)
-