Skip to main content
Glama

set_collision_layer_mask

Set collision layers and masks on physics nodes to control which objects interact. Use layer numbers (1-32) or raw bitmask values.

Instructions

Set collision layer and/or mask on a physics node. Accepts layer numbers (1-32) as array or raw bitmask.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodePathYesPath to the physics node
scenePathYesPath to the scene file (relative to project)
projectPathYesPath to the Godot project directory
collisionMaskNoArray of mask numbers [1,2,3] or raw bitmask integer
collisionLayerNoArray of layer numbers [1,2,3] or raw bitmask integer
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only indicate readOnlyHint=false and destructiveHint=false. The description adds input format details but does not disclose whether existing values are replaced, whether the scene file is saved, or validation behavior (e.g., out-of-range layer numbers). It does not contradict annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single sentence effectively communicates the tool's purpose, target, and accepted input formats without unnecessary words. It is front-loaded with the core action and resource.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is adequate for a focused setter but lacks important behavioral context: what happens when both layer and mask are set, replacement semantics, scene persistence, and prerequisites. With no output schema and minimal annotations, these details would improve completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

While the schema covers all parameters, the description adds the valid range 1-32 and clarifies that both array and raw bitmask forms are accepted for collisionLayer and collisionMask. This is not explicitly stated in the schema descriptions, adding practical value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb 'Set' with resource 'collision layer and/or mask' on 'physics node', clearly distinguishing from generic node property setters like set_node_properties. It also specifies accepted input formats (layer numbers array or raw bitmask), adding clarity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool vs alternatives, nor any prerequisites or conditions. The description simply states the action without context such as 'use this when you need to configure collision layers' or comparing to set_node_properties.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Vollkorn-Games/godot-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server