Skip to main content
Glama

write_script

Write or overwrite GDScript files in a Godot project, creating parent directories if missing, so scripts can be added or modified directly.

Instructions

Write or overwrite a GDScript file in a Godot project. Creates parent directories if needed. Use validate_script afterward to check for syntax errors.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
contentYesThe GDScript source code to write
scriptPathYesPath to the script file (relative to project, e.g., "scripts/player.gd")
projectPathYesPath to the Godot project directory
Behavior1/5

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

The description transparently states 'overwrite' and 'Creates parent directories if needed,' but the annotation destructiveHint=false contradicts the overwrite behavior. Overwriting a file is destructive, so this is a serious inconsistency. Per the rule, a description that contradicts annotations scores 1.

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?

The description is highly concise: two sentences with no wasted words. It front-loads the core action and adds a practical follow-up hint. Every sentence earns its place.

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

Completeness4/5

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

The description covers the essential behavior (write/overwrite), side effects (directory creation), and a recommended next step (validate). It omits edge cases like error handling or project existence, but for a simple file-writing tool this is reasonably complete. The annotation contradiction slightly reduces completeness but is already penalized in transparency.

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

Parameters3/5

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

Schema coverage is 100%, so the baseline is 3. The description does not add parameter-specific details beyond noting that parent directories are created (relevant to scriptPath). It does not conflict with the schema but adds minimal semantic 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 clearly states the tool's function: 'Write or overwrite a GDScript file in a Godot project.' This is a specific verb+resource construction that distinguishes it from siblings like read_script and validate_script. It unambiguously conveys the core action and scope.

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

Usage Guidelines4/5

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

The description provides a clear follow-up instruction: 'Use validate_script afterward to check for syntax errors.' This gives context on recommended usage. However, it does not explicitly mention when not to use this tool or alternatives, so it falls short of a 5.

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