|
Aerodynamic Objects Core 2.0.0
|
A base class used to spawn objects at a given rate over time. More...
Public Member Functions | |
| virtual void | FixedUpdate () |
| When overriding this fixed update make sure to call base.FixedUpdate() so that the spawn timer still works. More... | |
| abstract void | Spawn () |
| Define the logic for creating/spawning the object. More... | |
Public Attributes | |
| float | spawnRate |
| The frequency at which objects are spawned (number of objects per second). More... | |
A base class used to spawn objects at a given rate over time.
To create an object spawner, inherit this class and override the Spawn function with your desired spawn logic, e.g. Instantiate(prefab) The spawner will call the spawn function at the given spawn rate automatically.
|
virtual |
When overriding this fixed update make sure to call base.FixedUpdate() so that the spawn timer still works.
|
pure virtual |
Define the logic for creating/spawning the object.
Implemented in AerodynamicObjects.Demos.ContiguousLineVortexSpawner, AerodynamicObjects.Demos.ExampleSpawner, AerodynamicObjects.Demos.FrisbeeLauncher, AerodynamicObjects.Demos.PaperPlaneSpawner, AerodynamicObjects.Demos.RingVortexSpawner, and AerodynamicObjects.Demos.SourceSpawner.
| float AerodynamicObjects.Utility.ObjectSpawner.spawnRate |
The frequency at which objects are spawned (number of objects per second).