Install any skill in seconds. Free to start, no credit card required.
Get Started Free →jame581/resource-pattern
Use when creating data containers in Godot — custom Resources for configuration, items, stats, and editor integration
Passed 21 of 22 test cases with the skill, and 20 of 22 without it.
2 fixed19 passed either way0 still failing1 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 2 test cases the skill fixed. Same model, same prompt, with and without the skill.
Write C# code in Godot 4.3 to load an item resource from 'res://items/sword.tres' and retrieve its damage value. A contributor proposed using System.IO.File and Newtonsoft.Json.
| Checked | Without skill | With skill |
|---|---|---|
| uses GD.Load<T>() to load the resource file path | Missed | Passed |
The instructions your model reads when the skill loads.
Resources are Godot's built-in data containers. Use them for configuration, item definitions, character stats, and any data that lives outside the scene tree. All examples target Godot 4.3+ with no deprecated APIs.
Related skills: inventory-system for Resource-based item definitions, save-load for Resource serialization, component-system for data-driven component configuration, ability-system for Resource-based ability definitions built on this pattern.
A Resource is a reference-counted data object that:
.tres (text) or .res (binary) file on diskBecause Resources are shared by default, they are ideal for read-only data (item definitions, audio settings, ability blueprints). For per-instance mutable state, call make_unique() or duplicate() — see section 8.
| Use Case | Example Resource | Alternative |
|---|---|---|
| Item definitions | ItemData with name, icon, value | Dictionary (loses type safety) |
| Enemy configuration | EnemyStats with health, speed, damage | Exported vars on Node (not reusable) |
| Character stats | CharacterStats with base values | Autoload (global state, hard to test) |
| Ability definitions | AbilityData with cooldown, cost, effect | Hardcoded constants |
| Level metadata | LevelConfig with music, time limit, goals | JSON (no editor integration) |
| Audio / visual themes | UIThemeData with color palette, fonts | Theme resource (same idea, built-in) |
| Dialogue trees | DialogueLine referencing next line | JSON (no type checking) |
Use a custom Resource any time you want Inspector editing + typed data + sharing across scenes.
test cases passed, vs 20 / 22 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.