Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CreateFromSphere() [1/2]

static BoundingBox Microsoft.Xna.Framework.BoundingBox.CreateFromSphere ( BoundingSphere sphere)
inlinestatic

Definition at line 129 of file BoundingBox.cs.

130 {
131 BoundingBox result = default(BoundingBox);
132 result.Min.X = sphere.Center.X - sphere.Radius;
133 result.Min.Y = sphere.Center.Y - sphere.Radius;
134 result.Min.Z = sphere.Center.Z - sphere.Radius;
135 result.Max.X = sphere.Center.X + sphere.Radius;
136 result.Max.Y = sphere.Center.Y + sphere.Radius;
137 result.Max.Z = sphere.Center.Z + sphere.Radius;
138 return result;
139 }
BoundingBox(Vector3 min, Vector3 max)