Skip to main content

PerChunkForestSpawner

A class in Root.Township, Alta.Forests.

Spawns one prefab at the position of each forest chunk as it generates.

Constructors​

MemberWhat it is
PerChunkForestSpawner()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

1 private and internal field
MemberWhat it is
private NetworkPrefab prefabPrefab spawned per chunk.

Methods​

2 private and internal methods
MemberWhat it is
private void Awake()Hooks the parent forest generator's GeneratedDynamic.
private void Create(LocationChunk chunk)Spawns the prefab at the chunk's position.