Work in progress

Godot documentation is being updated to reflect the latest changes in version 4.0. Some documentation pages may still state outdated information. This banner will tell you if you're reading one of such pages.

The contents of this page are up to date. If you can still find outdated information, please open an issue.

SphereShape3D

Inherits: Shape3D < Resource < RefCounted < Object

Sphere shape resource for 3D collisions.

Description

3D sphere shape to be added as a direct child of a PhysicsBody3D or Area3D using a CollisionShape3D node. This shape is useful for modeling sphere-like 3D objects.

Performance: Being a primitive collision shape, SphereShape3D is the fastest collision shape to check collisions against, as it only requires a distance check with the shape's origin.

Tutorials

Properties

float

radius

0.5


Property Descriptions

float radius = 0.5

  • void set_radius ( float value )

  • float get_radius ( )

The sphere's radius. The shape's diameter is double the radius.