Use this skill for texturing meshes with UV awareness, atlas creation, and UV remapping. **Triggers:** "texture character", "UV texture", "texture atlas", "atlas packing", "decal projection", "multi-material mesh", "bake texture", "UV mapping", "texel density" **Load references when:** - UV bounds/island detection → `references/uv-mapping.md` - Character texturing → `references/character-texturing.md` - Atlas packing → `references/atlas-packing.md` - Decals/wear overlays → `references/decal-projection.md` For base texture generation: use `procedural-textures` skill. For mesh generation: use `procedural-meshes` skill.
/plugin marketplace add nethercore-systems/nethercore-ai-plugins/plugin install zx-procgen@nethercore-ai-pluginsThis skill inherits all available tools. When active, it can use any tool Claude has access to.
references/atlas-packing.mdreferences/character-texturing.mdreferences/decal-projection.mdreferences/uv-mapping.mdreferences/uv-projection-techniques.mdBridge procedural mesh and texture generation with UV-aware workflows.
This skill covers:
Key principle: All generation is BUILD-TIME tooling. Output files are bundled into ROM.
| Task | Approach | Reference |
|---|---|---|
| Single mesh texture | UV-aware generation | references/uv-mapping.md |
| Multiple meshes | Atlas packing | references/atlas-packing.md |
| Character skins | Region-based | references/character-texturing.md |
| Damage/wear | Decal projection | references/decal-projection.md |
| Use Case | Resolution | Texel Density |
|---|---|---|
| Character main | 256x256 | ~64 texels/unit |
| Character detail | 128x128 | ~32 texels/unit |
| Props | 64-128 | ~24-32 texels/unit |
| Terrain tiles | 128x128 | Varies |
from dataclasses import dataclass
import numpy as np
@dataclass
class UvBounds:
min_u: float
max_u: float
min_v: float
max_v: float
def get_uv_bounds(uvs: np.ndarray) -> UvBounds:
"""Calculate UV bounds from mesh UV coordinates."""
return UvBounds(
min_u=float(np.min(uvs[:, 0])),
max_u=float(np.max(uvs[:, 0])),
min_v=float(np.min(uvs[:, 1])),
max_v=float(np.max(uvs[:, 1]))
)
For detailed implementation, see references/uv-mapping.md.
Match texture resolution to mesh detail:
import math
def calculate_texture_resolution(
mesh_area: float,
uv_bounds: UvBounds,
target_density: float
) -> tuple[int, int]:
"""Calculate optimal texture resolution for mesh."""
desired_texels = math.sqrt(mesh_area * target_density**2)
uv_coverage = (uv_bounds.max_u - uv_bounds.min_u) * (uv_bounds.max_v - uv_bounds.min_v)
size = desired_texels / math.sqrt(uv_coverage)
# Round to next power of 2, clamp to 64-512
size = 2 ** math.ceil(math.log2(size))
size = max(64, min(512, size))
return (size, size)
1. Generate mesh with UVs (procedural-meshes)
2. Calculate texture resolution (64 texels/unit)
3. Identify UV regions (body, head, limbs)
4. Generate albedo (skin + clothing)
5. Generate MRE/SSE (per-region roughness)
6. Export coordinated set
See references/character-texturing.md for complete workflow.
1. Generate individual textures for props
2. Pack into atlas using shelf algorithm
3. Remap mesh UVs to atlas coordinates
4. Export single atlas + remapped meshes
See references/atlas-packing.md for packing algorithms.
# Character with coordinated textures
[[assets.meshes]]
id = "player"
path = "generated/meshes/player.gltf"
[[assets.textures]]
id = "player_albedo"
path = "generated/textures/player_albedo.png"
# Atlased props (single texture for multiple meshes)
[[assets.textures]]
id = "props_atlas"
path = "generated/textures/props_atlas.png"
[[assets.meshes]]
id = "crate"
path = "generated/meshes/crate.gltf" # UVs remapped to atlas
references/uv-mapping.md - UV bounds, islands, per-island texturingreferences/character-texturing.md - Character regions, skin tonesreferences/atlas-packing.md - Shelf packing, UV remappingreferences/decal-projection.md - Decals, wear overlaysprocedural-meshes - Generating meshes with UVsprocedural-textures - Base texture generationThis skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.