One-click install
npx skills add https://github.com/nlelouche/Unity-SkillForge --skill replay-system
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: replay-system
Source: https://github.com/nlelouche/Unity-SkillForge/tree/main/.agent/skills/02-gameplay/replay-system
Command: npx skills add https://github.com/nlelouche/Unity-SkillForge --skill replay-system

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires com.unity.inputsystem, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill enables the creation of deterministic replay systems, allowing for perfect playback of gameplay, automated QA, and debugging by recording and re-injecting player inputs.

Core Features & Use Cases

  • Deterministic Recording: Captures player inputs frame-by-frame.
  • Input-Based Playback: Re-feeds recorded inputs to recreate identical game states.
  • Use Cases: Ideal for death cameras, automated regression testing, and creating ghost data for speedruns.

Quick Start

Use the replay-system skill to start recording player inputs.

Frequently Asked Questions about replay-system

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I record and replay player inputs for deterministic gameplay in Unity?

To record and replay player inputs deterministically, you capture inputs frame-by-frame into an InputTimeline and re-feed them to recreate identical game states. This enables perfect playback for debugging and automated QA.

What is input-based replay and when do I need it for my game?

Input-based replay is a technique that records player inputs per frame and re-injects them to reproduce exact gameplay. You need it for creating death cameras, automated regression testing, and generating ghost data for speedruns.

Do I need a deterministic simulation environment to use input replay?

Yes, you need a deterministic simulation environment for input replay to work. Perfect playback requires your game simulation to be deterministic, and you must adhere to zero GC allocation in hot paths for optimal performance.

Can I use the Unity Input System for recording player inputs?

Yes, the Unity Input System is required for recording player inputs. The replay system depends on com.unity.inputsystem to capture frame-by-frame inputs and re-feed them into the InputTimeline for playback.

What's the best way to implement a death cam or spectating feature in Unity?

The best way to implement a death cam or spectating feature is using an input-based replay system. It records player inputs into an InputTimeline and re-feeds them to perfectly recreate the exact game state for playback.

Why does my replay playback not match the original gameplay?

Replay playback fails to match original gameplay when the simulation environment is not deterministic. You must ensure perfect determinism in your simulation and eliminate GC allocation in hot paths to guarantee identical playback.