Runtime Spawner 1.0.0
Generic Runtime spawn and instance pooling system for spawning random AI agents around a map. Works with ANY AI system easily.
|
A very simple trigger system for the Wave Spawner. More...
Public Member Functions | |
void | ResetTrigger () |
Manually reset this trigger? Will reactivate if ReactivateTrigger is true. | |
void | AddSpawnpoint () |
void | ShowHide (bool showHide) |
Editor only, draw the volume in the scene view. | |
Properties | |
BoxCollider | TriggerZone [get, set] |
Trigger zone for this trigger. | |
int | ActiveWave [get, set] |
The current active wave that we are spawning. | |
bool | IsActivated [get, set] |
Have we been activated? start spawning! | |
WaveSpawner | WaveSpawner [get, set] |
The WaveSpawner holds the wave config. | |
List< WaveSpawnPoint > | WaveSpawnPoints [get] |
When activated, units will spawn at random spawnpoints. | |
Events | |
static Action< WaveTrigger > | onWaveTriggerActivated |
Runtime Spawner listens to this to activate the spawning. | |
static Action< WaveTrigger > | onWaveTriggerReset |
Private Member Functions | |
void | OnEnable () |
void | Start () |
void | OnTriggerEnter (Collider other) |
This trigger was entered, check if we need to activate. | |
IEnumerator | TimeToReset () |
Internal coroutine timer to reset the trigger. | |
RuntimeSpawnerSettings | GetSettings () |
void | OnDrawGizmos () |
Draw our editor gizmos. | |
Private Attributes | |
List< WaveSpawnPoint > | waveSpawnPoints = new() |
When activated, units will spawn at random spawnpoints. | |
WaveSpawner | waveSpawner |
the wave spawner used by this trigger | |
bool | reactivateTrigger = false |
Does this trigger reactivate once complete? | |
float | reactivateTime = 10f |
How long before we reactivate? | |
bool | startAutomatically = false |
Does this spawner start automatically? | |
string | playerTag = "Player" |
Our trigger is activated by objects with this tag. | |
BoxCollider | triggerZone |
The trigger area for this trigger. | |
int | activeWave = 0 |
The active wave. | |
bool | isActivated = false |
Has this trigger been activated. | |
bool | showHideTrigger = false |
internal / editor only if the gizmos are visible | |
RuntimeSpawnerSettings | settings |
A very simple trigger system for the Wave Spawner.
void MegaCrush.Spawner.WaveTrigger.AddSpawnpoint | ( | ) |
|
private |
|
private |
Draw our editor gizmos.
|
private |
|
private |
This trigger was entered, check if we need to activate.
other |
void MegaCrush.Spawner.WaveTrigger.ResetTrigger | ( | ) |
Manually reset this trigger? Will reactivate if ReactivateTrigger is true.
void MegaCrush.Spawner.WaveTrigger.ShowHide | ( | bool | showHide | ) |
Editor only, draw the volume in the scene view.
showHide | True to show / false to hide |
|
private |
|
private |
Internal coroutine timer to reset the trigger.
|
private |
The active wave.
|
private |
Has this trigger been activated.
|
private |
Our trigger is activated by objects with this tag.
|
private |
How long before we reactivate?
|
private |
Does this trigger reactivate once complete?
|
private |
|
private |
internal / editor only if the gizmos are visible
|
private |
Does this spawner start automatically?
|
private |
The trigger area for this trigger.
|
private |
the wave spawner used by this trigger
|
private |
When activated, units will spawn at random spawnpoints.
|
getset |
The current active wave that we are spawning.
|
getset |
Have we been activated? start spawning!
|
getset |
Trigger zone for this trigger.
|
getset |
The WaveSpawner holds the wave config.
|
get |
When activated, units will spawn at random spawnpoints.
|
static |
Runtime Spawner listens to this to activate the spawning.
|
static |