<aside> 🗒️ Spawn objects at specific transforms, or within box colliders, spheres, or circles.
Spawners are the way you generate new objects. Spawners can track objects, spawn in a specific order or randomized, and spawn on itself or at any locations the positioner is set to.
Positioners give you control of where you want to spawn an object.
</aside>
<aside> 🗒️ This component serves as a base class for spawners. It includes functions and variables for spawning objects, managing positions and rotations, and invoking Unity events.
</aside>
PositionerBase postioner
A reference to a positioner for determining the spawn position.GameObject[] objectsToSpawn
An array of objects that can be spawned.GameObject lastObjectSpawned
A serialized reference to the last spawned object.public UnityEvent objectSpawned
Event triggered after an object is spawned._SpawnObject()
Spawns an object using a randomly picked object from the objectsToSpawn
array. based upon a positioner or itself if no positioner is assigned._SpawnObjectIndex(int index)
Spawns an object using the object at the specified index in the objectsToSpawn
array._SpawnObjectAmount(int index)
Spawns multiple objects based on the input index
._SpawnObject(Transform where)
Spawns an object at the specified transforms' position and rotation overriding the positioner.<aside> 🗒️ This script extends the functionality of the BaseSpawner class and allows for spawning multiple objects at once. It provides options for spawning objects in a specific order or all at once.
</aside>
int index
The current index used for spawning objects in order.