AgentSkillsCN

pixellab-animate-character

为现有的 PixelLab 角色添加动画效果。列出可用角色,按类别(动作、战斗、辅助)展示动画模板,并支持自定义动作描述。当用户希望为角色精灵赋予生动的动画表现时,可使用此技能。

SKILL.md
--- frontmatter
name: pixellab-animate-character
description: Add animations to existing PixelLab characters. Lists available characters, shows animation templates organized by category (movement, combat, utility), and supports custom action descriptions. Use this when the user wants to animate a character sprite.
domain: art
type: generator
version: 1.0.0
allowed-tools:
  - mcp__pixellab__animate_character
  - mcp__pixellab__list_characters
  - mcp__pixellab__get_character
  - AskUserQuestion

PixelLab Character Animator Skill

This skill adds animations to existing PixelLab characters through an interactive selection process, offering categorized animation templates and custom action support.

Workflow Context

FieldValue
Assigned Agentasset-artist
Sprint PhasePhase B (Implementation)
Directory Scopeassets/sprites/
Workflow ReferenceSee docs/agent-team-workflow.md

When to Use This Skill

Invoke this skill when the user:

  • Asks to "animate a character" or "add animations"
  • Says "I need walk/run/attack animations"
  • Wants to add movement or combat animations to sprites
  • Says "make the character move/fight/idle"
  • Needs to complete a character with animation sets

Available Animation Templates

Movement Animations

Template IDDescriptionBest For
breathing-idleSubtle breathing idleAll characters - essential
walkStandard walk cycleAll characters - essential
walking-4-framesSimple 4-frame walkSmaller sprites, NPCs
walking-6-framesMedium 6-frame walkStandard units
walking-8-framesSmooth 8-frame walkPlayer, companions
running-4-framesQuick 4-frame runChase sequences
running-6-framesMedium run cycleStandard combat
running-8-framesSmooth run cyclePlayer character
sad-walkDejected walkingDefeated/sad NPCs
scary-walkMenacing walkEnemies, undead
crouched-walkingStealthy crouch walkRogues, scouts

Combat - Basic Attacks

Template IDDescriptionBest For
fight-stance-idle-8-framesCombat ready stanceAll combat units
cross-punchPunching attackUnarmed, brawlers
lead-jabQuick jabFast attackers
surprise-uppercutUppercut attackHeavy hitters
high-kickHigh kick attackMartial artists
roundhouse-kickSpinning kickMartial artists
leg-sweepSweeping leg attackKnockdown moves
hurricane-kickSpinning multi-kickSpecial attacks

Combat - Advanced

Template IDDescriptionBest For
fireballCasting fireballMages, spellcasters
flying-kickLeaping kickAgile fighters
taking-punchGetting hit reactionAll combat units
falling-back-deathDeath fall backwardAll units - essential
getting-upRising from groundAfter knockdown

Movement - Special

Template IDDescriptionBest For
jumping-1Simple jumpBasic platforming
jumping-2Alternative jumpVariety
two-footed-jumpStanding jumpCombat jumps
running-jumpRunning leapAthletic moves
running-slideSliding dodgeRogues, agile units
backflipBackflip dodgeAcrobatic units
front-flipForward flipAcrobatic attacks
crouchingCrouch/duckTaking cover
falling-back-deathFalling backwardDeath animation

Utility Actions

Template IDDescriptionBest For
drinkingDrinking potionHealing animation
picking-upPicking up itemLooting, collecting
throw-objectThrowing motionGrenades, items
pushingPushing objectEnvironmental
pull-heavy-objectPulling heavy itemEnvironmental

Animation Sets by Character Role

Essential Set (All Characters)

code
1. breathing-idle - Rest state
2. walking-8-frames - Movement
3. falling-back-death - Death

Combat Unit Set (Soldiers, Enemies)

code
Essential Set +
4. fight-stance-idle-8-frames - Combat idle
5. running-6-frames - Chase/retreat
6. taking-punch - Hit reaction
7. [Attack animation based on weapon]

Player/Companion Set (Full)

code
Combat Unit Set +
8. drinking - Potion use
9. picking-up - Looting
10. getting-up - Recovery

Weapon-Specific Attack Recommendations

Weapon TypeRecommended Animations
Sword/Meleecross-punch, lead-jab (slash motions)
Two-handedsurprise-uppercut (overhead swing)
Unarmedcross-punch, high-kick, roundhouse-kick
Staff/Polearmleg-sweep (wide swing)
Magic/Castingfireball, throw-object
Bow/Rangedthrow-object (drawing motion)
Shieldpushing (shield bash)

Interactive Workflow

Phase 1: Select Character

Start by listing available characters:

code
I'll help you add animations to a character! First, let me show your available characters:

[Call mcp__pixellab__list_characters]

Which character would you like to animate?
- Select by name or ID
- Or describe which one (e.g., "the knight", "the mage I just created")

Wait for user response.


Phase 2: Check Current Animations

After character selection:

code
[Call mcp__pixellab__get_character with character_id]

**Character: [Name]**
- Size: [X]px
- Directions: [4/8]
- Current Animations: [List any existing]

What animations does this character need?

Phase 3: Select Animation Type

Present categorized options:

code
What type of animation would you like to add?

**Movement:**
- [ ] Idle (breathing-idle) - Essential resting animation
- [ ] Walk (walking-8-frames) - Standard movement
- [ ] Run (running-6-frames) - Fast movement
- [ ] Special movement (crouch, jump, slide)

**Combat:**
- [ ] Combat idle (fight-stance-idle-8-frames)
- [ ] Attack animation (various styles)
- [ ] Hit reaction (taking-punch)
- [ ] Death (falling-back-death)

**Utility:**
- [ ] Drinking (potion use)
- [ ] Picking up (looting)
- [ ] Throwing (grenades, items)

**Quick Sets:**
- [ ] Essential Set (idle, walk, death)
- [ ] Combat Set (essential + combat idle, attack, hit reaction)
- [ ] Full Set (all standard animations)

**Custom:**
- [ ] Custom action (describe your own)

Wait for user response.


Phase 4: Custom Action Description (If Selected)

If user wants custom action:

code
Describe the action you want the character to perform.

**Tips for good action descriptions:**
- Focus on the MOVEMENT, not the result
- Keep it simple and clear
- Describe the pose/motion

**Good examples:**
- "walking stealthily with weapon drawn"
- "casting spell with hands raised"
- "swinging sword in horizontal slash"
- "blocking with shield raised"
- "kneeling in prayer"

**Avoid:**
- Environmental details ("walking through forest")
- Complex sequences ("attack then dodge then attack")
- Emotions without movement ("feeling angry")

Your action description:

Phase 5: Confirm and Generate

Present summary before generating:

code
**Animation Summary:**
- Character: [Name] ([ID])
- Animation: [Template or Custom]
- Action Description: [If custom]
- Directions: [Will match character's directions]

**Estimated Time:** 2-4 minutes per animation

Ready to generate? [Yes / Modify / Add More]

Phase 6: Execute Generation

Call the PixelLab API:

gdscript
# Use mcp__pixellab__animate_character with:
{
  "character_id": "[character UUID]",
  "template_animation_id": "[template ID]",
  "animation_name": "[optional custom name]",
  "action_description": "[optional - for custom actions]"
}

After submission:

code
Animation queued!

**Job Details:**
- Character: [Name]
- Animation: [Type]
- Status: Processing
- Estimated Time: 2-4 minutes

The animation will automatically generate for all [4/8] directions.

**Next Steps:**
1. Queue more animations while this processes
2. Check status with get_character
3. Download when complete

Batch Animation Workflow

For adding multiple animations efficiently:

code
Would you like to add a standard animation set?

**Essential Set (3 animations):**
1. breathing-idle
2. walking-8-frames
3. falling-back-death

**Combat Set (6 animations):**
Essential Set +
4. fight-stance-idle-8-frames
5. cross-punch (or weapon-appropriate attack)
6. taking-punch

**Full Set (10 animations):**
Combat Set +
7. running-6-frames
8. drinking
9. picking-up
10. getting-up

Select a set and I'll queue all animations at once.

Queue multiple animations in sequence:

code
Queuing Essential Set for [Character Name]:

1/3 - breathing-idle... ✓ Queued
2/3 - walking-8-frames... ✓ Queued
3/3 - falling-back-death... ✓ Queued

All animations queued! Total processing time: ~6-12 minutes

I'll check on them periodically, or ask me "check animations for [character]"

Custom Action Guidelines

Writing Effective Action Descriptions

DO:

  • Focus on body movement and pose
  • Describe the motion arc
  • Keep under 50 words
  • Match the character's role

DON'T:

  • Include environmental context
  • Describe emotions without motion
  • Request multiple sequential actions
  • Use overly complex descriptions

Examples by Character Type

Fighter/Knight:

code
"swinging sword in wide horizontal arc"
"raising shield in defensive block"
"thrusting spear forward"
"heavy overhead axe chop"

Rogue/Assassin:

code
"quick dagger stab"
"throwing knife with side-arm motion"
"rolling dodge to the side"
"sneaking with low crouch"

Mage/Cleric:

code
"raising staff with magical energy gathering"
"hands together in prayer pose"
"throwing magical projectile"
"reading from spell book"

Archer/Ranger:

code
"drawing bow and releasing arrow"
"notching arrow while moving"
"kneeling to aim"
"rolling while drawing bow"

Animation Naming Conventions

Recommended naming for Godot import:

code
[character]_[action]_[direction]

Examples:
- ironmark_fighter_idle_s
- ironmark_fighter_walk_sw
- ironmark_fighter_attack_e
- ironmark_fighter_death_n

Animation names in PixelLab:

  • Use descriptive names: "Combat Idle", "Sword Slash", "Hit Reaction"
  • These help identify animations in the character list
  • Names can include the action type for clarity

Post-Animation Workflow

After animations complete:

  1. Check Status:

    code
    mcp__pixellab__get_character(character_id, include_preview=true)
    
  2. Review Animations:

    • Verify all directions animated correctly
    • Check timing feels right
    • Confirm style matches base character
  3. Download Assets:

    • Individual frame PNGs
    • Sprite sheets per animation
    • Combined character ZIP
  4. Import to Godot:

    code
    assets/sprites/characters/[faction]/[character]/
    ├── idle/
    │   ├── idle_s.png
    │   ├── idle_sw.png
    │   └── ...
    ├── walk/
    ├── attack/
    └── death/
    
  5. Setup AnimationPlayer:

    • Create animation tracks for each action
    • Set appropriate frame rates (8-12 FPS typical)
    • Configure looping (idle/walk loop, attack/death don't)

Quick Animation (Skip Interactive)

If user specifies animation directly:

code
User: "Add a walk animation to the Ironmark fighter"

Skip to Phase 6 with:
- character_id: [find by name match]
- template_animation_id: "walking-8-frames"
- animation_name: "Walk Cycle"
code
User: "Give the knight a sword slash attack"

Skip to Phase 6 with:
- character_id: [find by name match]
- template_animation_id: "cross-punch"
- action_description: "swinging sword in horizontal slash"
- animation_name: "Sword Slash"

Error Handling

If animation fails:

  1. Verify character exists and is complete
  2. Check template_animation_id is valid
  3. Simplify custom action description
  4. Ensure character has directional views generated

If style doesn't match:

  1. Animation inherits character's style settings
  2. If mismatch, may need to regenerate character
  3. Try different template that better fits character type

Example Invocations

User: "Add animations to my knight character" User: "I need walk and attack animations for the new enemy" User: "Animate the Ironmark fighter with combat moves" User: "Give all my characters idle animations" User: "Add a custom spell casting animation to the mage"


Reference: Animation Processing Times

Animation TypeApproximate Time
Simple (idle, death)2-3 minutes
Movement (walk, run)2-4 minutes
Combat (attacks)3-4 minutes
Complex (multi-frame)3-5 minutes
Full Set (10 anims)20-40 minutes

Times are per animation, processing is sequential per character.