collision_add_shape
Add a collision shape to a CollisionObject2D or CollisionObject3D node in a Godot scene. Specify the shape type and properties to create rectangle, circle, box, sphere, or capsule colliders.
Instructions
Add a collision shape to a CollisionObject2D/3D node.
Category: Collision
Args: project_path: Path to the Godot project directory scene_path: Path to the scene file (relative to project) node_path: Path to the CollisionObject node (e.g., "Player", "Enemy/CollisionObject2D") shape_type: Type of collision shape (RectangleShape2D, CircleShape2D, BoxShape3D, SphereShape3D, CapsuleShape2D, etc.) shape_properties: JSON string of shape properties (e.g., '{"size": [10, 20]}' for rectangle)
Returns: Success message or error description
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project_path | Yes | ||
| scene_path | Yes | ||
| node_path | Yes | ||
| shape_type | Yes | ||
| shape_properties | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |