Spawner
class in OpalScript
Spawns a prefab on an interval at this object's position. Great for enemy waves, obstacles, and pickups.
Properties
| Member | Description |
|---|---|
| Spawner.Running | True while the spawner is actively spawning. |
| Spawner.SpawnCount | How many prefabs have been spawned this play. |
Methods
| Member | Description |
|---|---|
| Spawner.SpawnNow | Spawn one prefab immediately, ignoring the interval. |
| Spawner.StartSpawning | Start the authored spawn schedule during Play. |
| Spawner.StopSpawning | Stop scheduled spawning. |
| Spawner.ResetCount | Clear the spawn count so the limit applies fresh. |
| Spawner.IsRunning | Whether scheduled spawning is active. |