Interface

The IScriptableFactory interface hierarchy defines the contract for all factories in the Scriptable Factory system. Three levels of interface progressively add capabilities: base lifecycle, object pooling, and data-driven variant spawning.

Architecture

spinner

Interface Tiers

Tier
Interface
Adds

Base

Lifecycle (Initialize, Start, OnQuit) and Unity references (gameObject, transform)

Pooling

IScriptableFactory<TObject>

Object creation, pooling (Spawn, Despawn, Destroy), and pool capacity

Data

IScriptableFactory<TObject, TData>

Data variants, data-driven spawning, and variant enumeration

Interfaces

Interface
Description

Base factory contract — lifecycle and Unity references

IScriptableFactory<TObject>

Adds pooled object creation and lifecycle management

IScriptableFactory<TObject, TData>

Adds data-driven variant spawning and data retrieval

See Also

Last updated