Jungle Sequencer Documentation
website·Indexed 31 days ago
https://junglesequencer.comA powerful and flexible sequencer tool for Unity. Documentation covers the Jungle Editor, node creation (including Branch and IO nodes), playback management via JungleRuntime and JunglePlayback, and the JungleTree container. Includes guides for versions 1.0.x and 2.0.x (Unreleased), detailing custom node inspectors, validation systems, and the OverTimeHelper extension.
What's inside Jungle Sequencer
- Jungle Sequencer (Version 1.0.x) is a flexible tool designed for creating complex sequences with ease.
Overview of JungleValidator for Unity
TheJungleValidatorclass is a Unity Editor-only system used to automatically manage Jungle validation operations. It handles opening/closing the validator window, focusing on specific issues related to Jungle trees or nodes, and refreshing validation reports. It is designed to respond to editor state changes (like play mode transitions) and is not included in final builds.Overview of OverTimeHelper
TheOverTimeHelperclass provides a simple way to step float, Vector2, Vector3, Quaternion, and Color values over time. It includes an intuitive inspector for editing options and is designed to be used within nodes to transition properties smoothly.Overview of OverTimeHelper
TheOverTimeHelperclass (part of theJungle.Extensionsnamespace) calculates value transitions over time. It supports float, Vector2, Vector3, Quaternion, and Color types and can be used in any script. It allows developers to determine transition progress, enable/disable calculations, and choose between different motion interpolation methods.Overview of JungleGUILayout
The
JungleGUILayoutclass provides IMGUI auto-layout elements for use in the Jungle Node Control GUI and inspector.CRITICAL: This class ONLY RENDERS IN EDITOR. All methods within
JungleGUILayoutwill not compile into the final build. While method declarations remain available to prevent compilation errors, they lack all functionality in a build environment.Overview of JungleUtils utility class
TheJungleUtilsclass provides a collection of static utility functions for managing Jungle trees, including operations for cleaning up trees, regenerating unique identifiers (UIDs), updating author information, generating unique node names, and formatting strings for display.Understand the JungleNode base class
TheJungleNodeclass is the base class for all node variants in the Jungle Sequencer. It manages unique identifiers, properties, node connections, and playback instances. Currently, Jungle Sequencer only supports four native node variants: Branch nodes, IO nodes (input/output), Identity nodes, and Event nodes. Custom node variant types are not natively supported.Manage JungleTree playback with JungleRuntime
TheJungleRuntimeclass manages the playback lifecycle ofJungleTreeinstances. It allows developers to start and stop trees and monitor their status via events. Note that playback methods (PlayandStop) can only be called while the application is in play mode.using Jungle; using UnityEngine; public class JungleRuntimeExample : MonoBehaviour { [SerializeField] private JungleTree tree; private string _playbackUid; private void Start() { // Start playing the tree and store the unique playback ID _playbackUid = JungleRuntime.Play(tree); // Stop the tree after five seconds Invoke(nameof(StopTreeAfterFiveSeconds), 5); } private void StopTreeAfterFiveSeconds() { // Stop the tree using the playback UID JungleRuntime.Stop(_playbackUid); } }Manage Jungle editor preferences via JunglePreferences
TheJunglePreferencesclass provides static properties to configure the Jungle editor's behavior and appearance. It manages settings for cache size, validation, gizmos, signatures, and editor visuals.Extend node functionality with Custom Inspectors
The node inspector supports custom inspectors to provide tailored interfaces for specific nodes. The process for creating custom node inspectors is similar to creating them forMonoBehaviourandScriptableObjectin Unity.Manage node connections using the Port class
ThePortclass acts as a container for a node's port, managing connections between nodes and storing metadata such as port types and connected node information. It provides access to the connected nodes and the unique identifier (Uid) of the parent node.// Example of Port properties public JungleNode[] Connections { get; } // List of connected nodes public string[] ConnectionsByUid { get; } // List of connected node Uids public string NodeUid { get; } // Uid of the node this port belongs toUnderstand the JunglePlayback runtime lifecycle
In Jungle Sequencer,JunglePlaybackis the runtime object responsible for handling the playback of aJungleTree. When a tree is played, the runtime automatically creates aJunglePlaybackinstance, initializes it, registers it with the runtime, and begins execution.