Skip to content

Format

typescript
Gizmos.DrawSphere(center, radius, depthTest)

class: Gizmos

Description

Draw a solid sphere with a center and a radius.

Parameters

param_nametypedescription
centerVector3The center coordinate of the sphere.
radiusnumberThe radius of the sphere.
depthTestbooleanWhether to perform depth testing.

Return

typedescription
void

Code Example

typescript
OnUpdate(): void {

    let center = new Vector3(0,0,0);
    let radius = 1;
    Gizmos.DrawSphere(center,radius,false);
    
}