Description
The CenterB
field represents the position of point B in a Capsule
structure. A capsule is defined by two points, CenterA
and CenterB
, and a radius. These points determine the endpoints of the capsule's central axis, with the radius defining the thickness of the capsule.
Usage
To use the CenterB
field, you can directly access it from an instance of the Capsule
struct. This field is of type Vector3
, which means it holds three-dimensional coordinates (x, y, z) representing the position of point B in the 3D space.
Example
// Example of accessing the CenterB field
Capsule capsule = new Capsule();
Vector3 pointB = capsule.CenterB;
// Example of setting the CenterB field
capsule.CenterB = new Vector3(1.0f, 2.0f, 3.0f);