How knela96/dynamic-parkour-system works
Main Components
• Unity Engine & Dependencies – Note that the package requires Unity’s own environment, along with external packages like Cinemachine and the Input System.
• Editor Interface – Under Assets/Dynamic Parkour System/Editor, these scripts (e.g., EditorHandler.cs) are responsible for providing custom editor tooling.
• Core Modules and Subsystems:
• Character Controller & Player Input: This is represented by scripts in Helpers/Player (PlayerControls.cs and the associated input action asset) and System Controllers (e.g., InputCharacterController.cs, ThirdPersonController.cs, MovementCharacterController.cs).
• Animation & Model: The Model folder houses numerous .fbx animation files, the Animator Controller, and textures. The AnimationCharacterController in System Controllers coordinates with these assets.
• Vaulting and Climbing Actions: The Vaulting Actions folder (and the vault-related system controllers) defines the discrete parkour actions (Vault, Slide, Jump, etc.), while Helper scripts (in Action Base Scripts and Climbing directories) provide foundational logic.
• Camera Handling: Scripts under Helpers/Camera (e.g., SwitchCameras.cs) and CameraController.cs work together with Cinemachine to manage camera transitions between parkour actions.
• Environment Interactions: The Prefabs directory (Environment subfolders for Climb, Jump, Vault, etc.) contains interactive objects (jump points, ledges, obstacles) that the system uses to trigger parkour behaviors.
• Resources/Configurations: Under the Resources, you have ActionsConfig for parkour parameters and Materials for visual consistency.
Relationships and Data Flow
• User Input (from Keyboard/Mouse or Gamepad) → Input System (via the PlayerControls.inputactions) → InputCharacterController.cs.
• The InputCharacterController then activates various System Controllers (Movement, Animation, Vaulting, Climb) based on user commands.
• The controllers query configured actions (from Resources/ActionsConfig) and interact with the Animator Controller (backed by the animations in the Model folder) to run parkour moves.
• The CameraController adjusts the view using components like Cinemachine.
• Prefabs, defined in the Environment folders, are placed into the scene to serve as interactable objects triggering specific behaviors (e.g., a Ledge prefab triggers ClimbController.cs).
Architectural Patterns and Design Principles
• Modular Separation: There is a clear division between core functionalities (character input, motion logic, animation handling, and parkour actions), adaptive to Unity’s component-based system.
• Extensibility: The usage of scriptable resource configurations (in Resources/ActionsConfig) and reusable prefabs makes it easy to extend or tweak parkour actions.
• Editor vs. Runtime: Custom editor scripts help configure game objects during design time while keeping out runtime overhead.
Relevant Technologies
• Unity Engine (with its Asset, Scene, and Prefab system).
• External packages: Unity's Cinemachine and Input System.
• C# scripting for game logic and custom editor extensions.
• Asset management via the Unity Package Manager.