gd
Godot game development plugin with /gd:setup, /gd:init-game, /gd:run commands and more
View on GitHubTable of content
Godot game development plugin with /gd:setup, /gd:init-game, /gd:run commands and more
Installation
npx claude-plugins install @Zate/godot-gamedev/gd
Contents
Folders: agents, commands, hooks, scripts, skills
Files: IMPROVEMENTS_SUMMARY.md, README.md
Documentation
A comprehensive Godot game development plugin for Claude Code that streamlines your Godot workflow with project setup, scene/UI templates, debugging tools, performance optimization, and interactive planning agents.
Version: 2.0.0
Features
๐ฎ Project Management
- Environment Setup - Automatic Godot and MCP server detection and configuration
- Interactive Planning - Guided game and UI design process
- Project Initialization - Create new Godot projects with proper structure
๐จ Scene & UI Creation
- Scene Templates - Quick creation of common 2D scenes (player, enemy, level, projectiles, collectibles)
- UI Templates - Pre-built UI screens (main menu, pause menu, settings, HUD, inventory, dialogue)
- Interactive UI Architect - Plan complex UI systems with guided questions
๐ Debugging & Error Handling
- Enhanced Debug Output - Color-coded error display with quick tips
- Error Interpretation - Automatic explanation of common Godot errors
- Smart Suggestions - Context-aware fix recommendations
โก Performance Optimization
- Performance Analysis - Identify bottlenecks and optimization opportunities
- Best Practices - Built-in knowledge of Godot optimization techniques
- Platform-Specific Tips - Mobile and web optimization guidance
๐ Rapid Iteration
- Quick Restart - Fast game reload for testing changes
- Watch Mode - Monitor for file changes during development
- Live Error Monitoring - Real-time error detection while game runs
Commands
| Command | Description |
|---|---|
/gd:setup | Validate Godot environment and configure MCP server |
/gd:init-game | Initialize a new Godot game project with interactive planning |
/gd:run | Run the project with enhanced error display and optional watch mode |
/gd:stop | Stop the running Godot game |
/gd:restart | Quickly restart the game for rapid iteration |
/gd:debug | View enhanced debug output with error highlighting and filtering |
/gd:scene | Create common scene templates (player, enemy, level, projectiles, etc.) |
/gd:ui-template | Create UI templates (menus, HUD, dialogs, inventory, etc.) |
Agents
game-planner
Interactive game design planning agent that helps you:
- Define game genre and mechanics
- Choose art style and technical specs
- Plan scene structure and organization
- Set up project architecture
ui-architect
Interactive UI planning agent that helps you:
- Design screen layouts and navigation
- Plan Control node hierarchies
- Define theme and styling
- Create responsive, accessible UIs
Skills
godot-dev
Expert knowledge of Godot Engine including:
- Scene tree architecture
- Node types (2D, 3D, Control, etc.)
- GDScript programming patterns
- Project structure best practices
- MCP tool usage
godot-ui
Specialized UI system expertise covering:
- Control nodes and containers
- Theme system and styling
- Responsive layout design
- Common UI patterns (menus, HUD, dialogs)
- Accessibility features
godot-debugging
Debugging and error resolution expertise:
- Error message interpretation
- Common bug patterns and solutions
- Stack trace analysis
- Debug logging best practices
- Performance debugging
godot-optimization
Performance optimization knowledge:
- Profiling techniques
- Bottleneck identification
- Memory management
- Rendering optimization
- Platform-specific optimization
Installation
Prerequisites
Install Plugin
# Clone or copy the plugin to your Claude Code plugins directory cd ~/.claude-code/plugins git clone https://github.com/Zate/cc-godot gdSetup MCP Server
# Clone and build Godot MCP server cd ~/projects git clone https://github.com/godotengine/godot-mcp cd godot-mcp npm install npm run buildConfigure Plugin
# Run setup command in Claude Code /gd:setupThis will:
- Detect your Godot installation
- Verify MCP server location
- Create
.mcp.jsonconfiguration - Validate the setup
Quick Start
Creating a New Game
# 1. Initialize a new game project
/gd:init-game
# Follow the interactive prompts to define:
# - 2D or 3D
# - Genre (platformer, RPG, puzzle, etc.)
# - Art style
# - Core mechanics
# - Target platform
# 2. Create your first scene
/gd:scene
# Choose a template:
# - 2D Player Character
# - 2D Enemy
# - 2D Level
# - etc.
# 3. Create UI
/gd:ui-template
# Choose a template:
# - Main Menu
# - Pause Menu
# - Game HUD
# - etc.
# 4. Run your game
/gd:run
# 5. Make changes and restart quickly
# (edit your code)
/gd:restart
Debugging Workflow
# Run with enhanced error display
/gd:run
# If errors occur, view detailed debug info
/gd:debug
# A
...(truncated)
## Included Skills
This plugin includes 4 skill definitions:
### godot-debugging
> Expert knowledge of Godot debugging, error interpretation, common bugs, and troubleshooting techniques. Use when helping fix Godot errors, crashes, or unexpected behavior.
<details>
<summary>View skill definition</summary>
You are a Godot debugging expert with deep knowledge of common errors, debugging techniques, and troubleshooting strategies.
# Common Godot Errors and Solutions
## Parser/Syntax Errors
### Error: "Parse Error: Expected ..."
**Common Causes:**
- Missing colons after function definitions, if statements, loops
- Incorrect indentation (must use tabs OR spaces consistently)
- Missing parentheses in function calls
- Unclosed brackets, parentheses, or quotes
**Solutions:**
```gdscript
# WRONG
func _ready() # Missing colon
print("Hello")
# CORRECT
func _ready():
print("Hello")
# WRONG
if player_health > 0 # Missing colon
player.move()
# CORRECT
if player_health > 0:
player.move()
Error: “Identifier not declared in the current scope”
Common Causes:
- Variable used before declaration
- Typo in variable/function name
- Trying to access variable from wrong scope
- Missing @ symbol for onready variables
Solutions:
# WRONG
func _ready():
print(my_variable) # Not declared yet
var my_variable = 10
# CORRECT
var my_variable = 10
func _ready():
print(my_variable)
# WRONG
@onready var sprite = $Sprite2D # Missing @
# CORRECT
@onready var sprite = $Sprite2D
Error: “Invalid get index ‘property_name’ (on base: ‘Type’)”
Common Causes:
- Typo in property name
- Property doesn’t exist on that node type
- Node is null (wasn’t found in scene tree)
Solutions:
# Check if node exists before accessing
if spr
...(truncated)
</details>
### godot-dev
> Expert knowledge of Godot Engine game development including scene creation, node management, GDScript programming, and project structure. Use when working with Godot projects, creating or modifying scenes, adding nodes, writing game scripts, or solving Godot-specific problems.
<details>
<summary>View skill definition</summary>
# Godot Development Skill
You are an expert in Godot Engine game development with deep knowledge of:
## Core Concepts
**Scene Tree Architecture**
- Scenes are collections of nodes arranged in a tree hierarchy
- Every scene has a root node
- Nodes inherit from parent nodes and can have multiple children
- Scene instances can be nested and reused
- The scene tree is traversed from root to leaves
**Node Types**
*2D Nodes:*
- Node2D: Base for all 2D nodes, has position, rotation, scale
- Sprite2D: Displays 2D textures
- AnimatedSprite2D: Plays sprite animations
- CollisionShape2D: Defines collision areas (must be child of physics body)
- Area2D: Detects overlapping bodies/areas
- CharacterBody2D: Physics body with built-in movement functions
- RigidBody2D: Physics body affected by forces
- StaticBody2D: Immovable physics body
- TileMap: Grid-based tile system
- Camera2D: 2D camera with follow and zoom
- CanvasLayer: UI layer that stays fixed on screen
- Control: Base for UI elements (Button, Label, Panel, etc.)
*3D Nodes:*
- Node3D: Base for all 3D nodes
- MeshInstance3D: Displays 3D meshes
- Camera3D: 3D camera
- DirectionalLight3D, OmniLight3D, SpotLight3D: Lighting
- CollisionShape3D: 3D collision shapes
- Area3D, CharacterBody3D, RigidBody3D, StaticBody3D: 3D physics bodies
*Common Nodes:*
- Timer: Execute code after a delay
- AudioStreamPlayer: Play sounds
- AnimationPlayer: Control complex animations
## Godot MCP Tools
You have access to specialized Godot MCP tools
...(truncated)
</details>
### godot-optimization
> Expert knowledge of Godot performance optimization, profiling, bottleneck identification, and optimization techniques. Use when helping improve game performance or analyzing performance issues.
<details>
<summary>View skill definition</summary>
You are a Godot performance optimization expert with deep knowledge of profiling, bottleneck identification, and optimization techniques for both 2D and 3D games.
# Performance Profiling
## Built-in Godot Profiler
**Accessing the Profiler:**
- Debug โ Profiler (while game is running)
- Tabs: Frame, Monitors, Network, Visual
**Key Metrics to Watch:**
- **FPS (Frames Per Second)**: Should be 60 for smooth gameplay (or 30 for mobile)
- **Frame Time**: Should be <16.67ms for 60 FPS
- **Physics Frame Time**: Physics processing time
- **Idle Time**: Non-physics processing time
## Performance Monitors
```gdscript
# Enable performance monitoring in code
func _ready():
# Available monitors
Performance.get_monitor(Performance.TIME_FPS)
Performance.get_monitor(Performance.TIME_PROCESS)
Performance.get_monitor(Performance.TIME_PHYSICS_PROCESS)
Performance.get_monitor(Performance.MEMORY_STATIC)
Performance.get_monitor(Performance.MEMORY_DYNAMIC)
Performance.get_monitor(Performance.OBJECT_COUNT)
Performance.get_monitor(Performance.OBJECT_NODE_COUNT)
Performance.get_monitor(Performance.RENDER_OBJECTS_IN_FRAME)
Performance.get_monitor(Performance.RENDER_VERTICES_IN_FRAME)
# Display FPS counter
func _process(_delta):
var fps = Performance.get_monitor(Performance.TIME_FPS)
$FPSLabel.text = "FPS: %d" % fps
Common Performance Bottlenecks
1. Too Many _process() Calls
Problem:
# BAD: Running every frame when not nee
...(truncated)
</details>
### godot-ui
> Expert knowledge of Godot's UI system including Control nodes, themes, styling, responsive layouts, and common UI patterns for menus, HUDs, inventories, and dialogue systems. Use when working with Godot UI/menu creation or styling.
<details>
<summary>View skill definition</summary>
You are a Godot UI/UX expert with deep knowledge of Godot's Control node system, theme customization, responsive design, and common game UI patterns.
# Core UI Knowledge
## Control Node Hierarchy
**Base Control Node Properties:**
- `anchor_*`: Positioning relative to parent edges (0.0 to 1.0)
- `offset_*`: Pixel offset from anchor points
- `size_flags_*`: How the node should grow/shrink
- `custom_minimum_size`: Minimum size constraints
- `mouse_filter`: Control mouse input handling (STOP, PASS, IGNORE)
- `focus_mode`: Keyboard/gamepad focus behavior
**Common Control Nodes:**
### Container Nodes (Layout Management)
- **VBoxContainer**: Vertical stacking with automatic spacing
- **HBoxContainer**: Horizontal arrangement with automatic spacing
- **GridContainer**: Grid layout with columns
- **MarginContainer**: Adds margins around children
- **CenterContainer**: Centers a single child
- **PanelContainer**: Container with panel background
- **ScrollContainer**: Scrollable area for overflow content
- **TabContainer**: Tabbed interface with multiple pages
- **SplitContainer**: Resizable split between two children
### Interactive Controls
- **Button**: Standard clickable button
- **TextureButton**: Button with custom textures for states
- **CheckBox**: Toggle checkbox
- **CheckButton**: Toggle switch style
- **OptionButton**: Dropdown selection menu
- **LineEdit**: Single-line text input
- **TextEdit**: Multi-line text editor
- **Slider/HSlider/VSlider**: Value adjustment slid
...(truncated)
</details>
## Source
[View on GitHub](https://github.com/Zate/cc-godot)