CollisionShape3D

Inherits: Node3D < Node < Object

Node that represents collision shape data in 3D space.

Description

Editor facility for creating and editing collision shapes in 3D space. Set the shape property to configure the shape. IMPORTANT: this is an Editor-only helper to create shapes, use CollisionObject3D.shape_owner_get_shape to get the actual shape.

You can use this node to represent all sorts of collision shapes, for example, add this to an Area3D to give it a detection shape, or add it to a PhysicsBody3D to create a solid object.

Warning: A non-uniformly scaled CollisionShape3D node will probably not function as expected. Please make sure to keep its scale uniform (i.e. the same on all axes), and change the size of its shape resource instead.

Tutorials

Properties

bool

disabled

false

Shape3D

shape

Methods

void

make_convex_from_siblings ( )

void

resource_changed ( Resource resource )


Property Descriptions

bool disabled = false

  • void set_disabled ( bool value )

  • bool is_disabled ( )

A disabled collision shape has no effect in the world.


Shape3D shape

The actual shape owned by this collision shape.


Method Descriptions

void make_convex_from_siblings ( )

Sets the collision shape's shape to the addition of all its convexed MeshInstance3D siblings geometry.


void resource_changed ( Resource resource )

If this method exists within a script it will be called whenever the shape resource has been modified.