Unity Cinemachine
Developmentunity-cinemachineUnity Cinemachine is an Agent Skill for development published in the a5c-ai/babysitter repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.
Unity Cinemachine skill for virtual cameras, procedural camera control, and cinematic sequences.
QUICK START
How to use this skill
Bring this guide into your coding agent with a prompt tailored to the tool you use.
- Open your project in Codex.
- Copy and paste the prompt below.
- Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/a5c-ai/babysitter/blob/HEAD/library/specializations/game-development/skills/unity-cinemachine/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/unity-cinemachine, but wait for my approval before writing files or running scripts.
Copying this prompt does not install or run the skill. Review third-party files before use.
Unity Cinemachine Skill
Procedural camera system using Unity Cinemachine.
Overview
This skill provides capabilities for implementing dynamic camera systems using Cinemachine, including virtual cameras, camera blending, and cinematic sequences.
Capabilities
Virtual Cameras
- Create virtual cameras for different views
- Configure follow and look-at targets
- Set up framing transposers
- Implement orbital cameras
Camera Behaviors
- Configure noise profiles for shake
- Implement dead zones and soft zones
- Set up camera collision
- Handle screen composition
Blending and Transitions
- Configure blend curves
- Set up camera priorities
- Implement cutscenes with Timeline
- Handle state-driven cameras
Advanced Features
- Create dolly tracks
- Implement target groups
- Set up clear shots
- Configure confiner extensions
Prerequisites
- Unity 2021.3+
- Cinemachine package installed
Usage Patterns
Player Follow Camera
// Configure in editor or via script
var vcam = GetComponent<CinemachineVirtualCamera>();
vcam.Follow = playerTransform;
vcam.LookAt = playerTransform;
// Framing Transposer settings
var transposer = vcam.GetCinemachineComponent<CinemachineFramingTransposer>();
transposer.m_ScreenX = 0.5f;
transposer.m_ScreenY = 0.4f;
Camera Shake
public void TriggerShake(float intensity, float duration)
{
var noise = vcam.GetCinemachineComponent<CinemachineBasicMultiChannelPerlin>();
noise.m_AmplitudeGain = intensity;
StartCoroutine(ResetShake(duration));
}
Best Practices
- Use virtual cameras for game states
- Configure proper priorities
- Test camera transitions
- Use Timeline for cutscenes
- Profile camera updates