toJSON

Writes this sphere as [centerX, centerY, centerZ, radius].

Mirrors three.js toJSON() (which produces { radius, center: center.toArray() }); flattened here since the math layer has no JS object type. Center first, so the leading three components are exactly what Vector3.toArray would write.

Return

Serialized structure with fields representing the object state.