Tooluck logoTooluck
SKILL.md

godot-shaders

Agent skill fromgamedev-skills/awesome-gamedev-agent-skills

Write Godot 4.7 shaders in the Godot Shading Language: canvas_item shaders for 2D and spatial shaders for 3D, with vertex/fragment functions, uniforms (source_color, hint_range), TIME/UV animation, and screen-reading via hint_screen_texture. Use when authoring .gdshader files, writing fragment/vertex code, making 2D/3D visual effects, or porting 3.x shaders (SCREEN_TEXTURE, hint_color) to 4.x.

How to install godot-shaders

install godot-shaders
# install the awesome-gamedev-agent-skills pack with the skills CLI
npx skills add gamedev-skills/awesome-gamedev-agent-skills

# or add only this skill to Claude Code: copy the folder

skills/godot/godot-shaders/

# into

~/.claude/skills/godot-shaders/ (all projects)

.claude/skills/godot-shaders/ (one project)

skills/godot/godot-shaders/SKILL.md

Apache-2.0Full file
1# Godot Shaders (4.x)
2
3Write `canvas_item` (2D) and `spatial` (3D) shaders in the Godot Shading Language, animate
4with `TIME`/`UV`, expose `uniform`s, and read the screen. Targets **Godot 4.7**.
5
6## When to use
7
8- Use when writing `.gdshader` code or a `ShaderMaterial`: 2D effects (outline, dissolve,
9 flash, water), 3D surface shaders (rim light, toon, scrolling UV), or screen-space
10 post effects.
11
12**When *not* to use:** the cross-engine *concepts* of shading (UVs, vertex/fragment
13theory) → `shader-programming`; particles/VFX nodes → general 3D; non-shader visuals.
14
15## Core workflow
16
171. **Pick the shader type** on the first line: `shader_type canvas_item;` for 2D
18 (Sprite2D, TextureRect, anything `CanvasItem`) or `shader_type spatial;` for 3D
19 materials. (`particles`, `sky`, `fog` also exist.)
202. **Attach via a `ShaderMaterial`.** Create a `ShaderMaterial`, assign your `.gdshader`,
21 and put it on the node's `material`. Uniforms appear in the Inspector.
223. **Write `fragment()`** to set the output: `COLOR` (2D) or `ALBEDO`/`EMISSION`/`ALPHA`
23 (3D). Optionally `vertex()` to move geometry and `light()` for custom lighting.
244. **Expose tunables as `uniform`s** with hints (`source_color`, `hint_range`) so they are
25 editable and correctly color-managed.
265. **Animate with the built-in `TIME`** and sample textures with `texture(tex, UV)`.
276. **Set uniforms from code** with `material.set_shader_parameter("name", value)`.
28
29## Patterns
30…

Excerpt shown under the repository's Apache-2.0 license.

More skills in awesome-gamedev-agent-skills

Keep exploring

Similar skill repositories

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates