Skip to main content

Overview & Philosophy

Welcome to the Game Event System, a professional, enterprise-grade event architecture designed to decouple logic, visualize complex flows, and bring order to event-driven chaos in Unity.

Hero Diagram

๐ŸŽฏ The Design Philosophyโ€‹

In traditional Unity development, event management often devolves into "Spaghetti Code"โ€”tightly coupled scripts, invisible delegate chains, and logic scattered across dozens of components.

TinyGiants.GameEventSystem solves this through a rigorous Hybrid Workflow philosophy:

  1. Code for Logic: Programmers define when events fire (Raise) and what responds (Listeners).
  2. Inspector for Binding: Designers wire events to scene objects using visual, drag-and-drop interfacesโ€”no coding required.
  3. Graph for Orchestration: Complex sequences (Triggers & Chains) are orchestrated in a visual node graph, not buried in coroutines.

๐Ÿ’Ž Why Choose This System?โ€‹

ScriptableObject-Driven Architectureโ€‹

Events are Assets, not fragile string keys or hardcoded references.

  • Complete Decoupling: Senders never know about receiversโ€”fire once, notify many.
  • Cross-Scene Persistence: Events exist independently of scenes and survive scene transitions.
  • GUID Identity System: Every event has a unique, immutable GUID. Rename files, move foldersโ€”references never break.
  • Multi-Database Support: Split events into modular databases for team collaboration and dynamic runtime loading.

Visual Flow Orchestrationโ€‹

Stop hunting through code to understand "what triggers what". The Visual Flow Editor transforms invisible logic into clear, maintainable graphs:

  • Triggers (Fan-Out): One event spawns multiple parallel actionsโ€”perfect for "OnDeath" firing "PlaySound", "SpawnEffect", and "UpdateUI" simultaneously.
  • Chains (Sequential): Step-by-step execution with built-in delays and completion waitingโ€”ideal for cutscenes and tutorials.
  • Hybrid Flows: Mix parallel and sequential logic in the same graph for maximum flexibility.
  • Group Organization: Color-coded groups keep large flows organized and comprehensible.

Type-Safe, Zero-Reflection Performanceโ€‹

Unity struggles with generic serialization. We solved it.

  • Automated Code Generation: Generates concrete classes (IntGameEvent, PlayerGameEvent) for your custom types automatically.
  • Expression Tree Compiler: Conditions compile into high-performance Lambda delegates at initializationโ€”no runtime parsing or reflection cost.
  • Native Inspector Support: Full UnityEvent<T> compatibility with type safety guaranteed at compile time.

๐Ÿงฉ Core Capabilitiesโ€‹

This system scales from rapid prototyping to data-heavy, live-service productions.

๐Ÿ’Ž Core Architectureโ€‹

FeatureDescription
ScriptableObject-DrivenAsset-based events enable complete sender/receiver decoupling and cross-scene references.
GUID Identity SystemUnique identifiers ensure references survive file renames and folder reorganization.
Comprehensive Generic SupportNative support for parameterless Void, single-parameter GameEvent<T>, and source-aware GameEvent<TSender, TArgs>.
Multi-Database ManagementMultiple event databases allow modular organization and dynamic loading in large projects.
Category SystemCustom string-based categorization for efficient filtering within vast event libraries.
Auto Static Reset[RuntimeInitializeOnLoadMethod] automatically clears static caches, preventing Editor Play Mode pollution.

๐Ÿ’ก Learn Moreโ€‹

๐Ÿ•ธ๏ธ Visual Node Graph & Orchestrationโ€‹

FeatureDescription
Visual Flow EditorZoomable, pannable node graph canvas for orchestrating complex event dependencies.
Node-Based ConfigurationVisually configure Delays, Loop Counts, Priorities, and Persistence directly on nodes.
Smart Connection ValidationReal-time visual feedback (Green=Match, Yellow=Compatible, Red=Error) prevents runtime mistakes.
Hybrid Execution ModesSeamlessly mix parallel "Fire-and-Forget" triggers with blocking serial chains.
Full Undo/Redo SupportCustom snapshot-based history (Ctrl+Z/Ctrl+Y) enables worry-free editing.
Group OrganizationCreate visual groups with custom titles and colors to tame large logic flows.

๐Ÿ’ก Learn Moreโ€‹

๐Ÿง  Advanced Logic & Conditionsโ€‹

FeatureDescription
Expression Tree CompilerConditions compile into System.Linq.Expressions for zero reflection overhead at runtime.
Visual Logic BuilderConstruct complex nested AND/OR logic without touching code.
Dynamic Value SourcesCompare arguments against Constants, Scene Properties (Reflection), or Random Ranges.
Argument TransformersDynamically extract and pass object properties between nodes.
Granular Flow ControlPer-node configuration: Wait for Completion, Wait for Frames, Conditional Gates.

๐Ÿ’ก Learn Moreโ€‹

๐ŸŽง Listening & Bindingโ€‹

FeatureDescription
Visual Inspector BindingZero-code, drag-and-drop callback wiring using UnityEvent wrappers.
Priority ListenersInteger-based priority sorting ensures critical logic executes first.
Conditional ListenersBuilt-in predicate supportโ€”callbacks fire only when conditions are met.
Persistent ListenersDontDestroyOnLoad support for listeners that survive scene transitions.
Dynamic Runtime APIFull AddListener / RemoveListener support for code-driven relationships.
Smart Type SafetyAutomatic parameter mismatch detection during binding prevents runtime errors.

๐Ÿ’ก Learn Moreโ€‹

โšก Flow Control & Automationโ€‹

FeatureDescription
Event Triggers (Fan-Out)One-to-many logic: single event triggers multiple downstream events (visualized).
Serialized Event ChainsSequential execution with configurable inter-node delays (visualized).
Async Wait MechanismChains wait for previous nodes to complete (Coroutine/Async) before proceeding.
Delayed & Repeating ExecutionBuilt-in RaiseDelayed and RaiseRepeating with cancellable DelayHandle control.
Task Handle ControlFine-grained cancellation of pending delayed or repeating events.

๐Ÿ’ก Learn Moreโ€‹

๐Ÿ“œ Code Generation & Automationโ€‹

FeatureDescription
Automated Concrete Class GenerationSolves Unity's generic serialization limitations automatically.
Tri-Mode Generation StrategyIndependent generation for Basic types, Custom types, and Sender types.
Compilation Pipeline IntegrationMonitors Unity compilation to automate Select โ†’ Generate โ†’ Compile โ†’ Create workflow.
Smart Naming ResolutionHandles type conflicts and generates C#-compliant class and file names.
Safe Cleanup ToolsIdentifies and batch-deletes generated code without breaking dependencies.

๐Ÿ’ก Learn Moreโ€‹

๐ŸŽจ Editor Toolchainโ€‹

FeatureDescription
Modern Dashboard EditorDashboard-style UI with statistics, search, pagination, and batch operations.
Batch Creation WizardBuilt-in fuzzy search for rapid creation of specific event types.
Smart Inspector DropdownCustom [GameEventDropdown] attribute replaces object fields with searchable, categorized selectors.
Scene Reference FinderScans the current scene to pinpoint which GameObjects reference specific events.
Smart Path AdaptationAuto-detects plugin directory to support folder relocation.
Folder ProtectionIntercepts asset moves to prevent accidental migration to 'Plugins' folder.
Database Health CheckAuto-detects and cleans orphaned sub-assets for project hygiene.

๐Ÿ’ก Learn Moreโ€‹

๐Ÿ“Š Debugging & Profilingโ€‹

FeatureDescription
Real-Time Monitor WindowDedicated runtime panel visualizing system status.
Automation Tree VisualizerInspect active Trigger and Chain hierarchies in real-time.
Performance ProfilingReal-time stats: execution time (Avg/Min/Max), listener counts, GC allocation.
Deep LoggingRecords timestamps, frame counts, parameter values, stack traces, and caller info.
Intelligent Warning SystemDetects and alerts on high frequency, empty fires, or slow execution.
Visual Status MarkersIntuitive icons showing which events use Inspector vs Runtime bindings.

๐Ÿ’ก Learn Moreโ€‹


๐Ÿ›  Directory Structure Previewโ€‹

Understanding the separation of concerns is crucial:

  • TinyGiants/GameEventSystem: Core plugin logic (Editor & Runtime).
  • TinyGiantsData/GameEventSystem: Your data sanctuaryโ€”Databases, Flow Graphs, and Generated Code live here.

This separation ensures clean upgrades and prevents accidental plugin modification.


๐Ÿš€ Next Stepsโ€‹

Choose your path to get started:

๐ŸŽฎ I want to see it in actionโ€‹

Open the included Demo Scenes to see the system running immediately.

๐Ÿ› ๏ธ I want to create my first eventโ€‹

Follow the step-by-step workflow to integrate the system into your own project.

  1. Installation & Setup: Initialize the plugin managers.
  2. Hub System Dashboard: Open the control center.
  3. Creating Events Wizard: Use the Wizard to create your first event asset in under 60 seconds.

Professional Support

This system is battle-tested in production environments. Need custom features or integration support? Contact me via the AssetStore.