Table of Contents

Method OnSpawnedFromBiomeTemplate

Namespace
Pinwheel.Vista
Assembly
Pinwheel.Vista.Runtime.dll

OnSpawnedFromBiomeTemplate(BiomeTemplate, BiomeTemplateSpawnContext)

React to this component's owning object being spawned from a template. Clone any owned references in memory, reassign them to this component, and register each clone in context for the caller to persist. template is the source template being instantiated. Run any other per spawn behavior here. Must not touch the AssetDatabase.

void OnSpawnedFromBiomeTemplate(BiomeTemplate template, BiomeTemplateSpawnContext context)

Parameters

template BiomeTemplate
context BiomeTemplateSpawnContext

Remarks

Both parameters are required, never null: the spawner guarantees a validated template and a live context, and any other caller must supply the same. The context is what coordinates clone sharing across receivers in one spawn, so a receiver that clones owned references should treat a null argument as a broken precondition and throw, not degrade to cloning in isolation, and not tolerate a null template just because it happens not to read it today.