Core GameKit  3.2.9.0
The ultimate pooling / combat / spawning / variable plugin!
DarkTonic.CoreGameKit.TriggeredSpawnerV2 Class Reference

This class is used for Triggered Spawner setup. More...

Inheritance diagram for DarkTonic.CoreGameKit.TriggeredSpawnerV2:

Public Member Functions

void ActivateCodeTriggeredEvent1 ()
 Call this method to active Code-Triggered Event 1. More...
 
void ActivateCodeTriggeredEvent2 ()
 Call this method to active Code-Triggered Event 2. More...
 
bool HasActiveWaveOfType (TriggeredSpawner.EventType eType, string customEventName)
 Returns whether a wave of the current event is currently active or not. More...
 
void EndWave (TriggeredSpawner.EventType eType, string customEventName)
 This method stops the currently spawning wave of an Event Type you pass in, if there is a match. More...
 

Static Public Member Functions

static List< TriggeredSpawnerV2GetChildSpawners (Transform trans)
 This method returns a list of the child Spawners, if any. More...
 

Protected Member Functions

virtual Transform SpawnWaveItem (Transform prefabToSpawn, Vector3 spawnPosition, Quaternion rotation, TriggeredWaveMetaData wave)
 Override this method to call a Network Instantiate method or other. More...
 
virtual void DespawnSpawner ()
 Override this method to call a Network Destroy method or other. More...
 
virtual void SpawnedOrAwake ()
 This method gets called whenever the object is spawned or starts in a Scene (from Awake event) More...
 
virtual Transform GetSpawnable (TriggeredWaveMetaData wave)
 This returns the item to spawn. Override this to apply custom logic if needed. More...
 
virtual bool CanSpawnOne (TriggeredWaveMetaData wave)
 Subclass this to override it if needed. More...
 
virtual Vector3 GetSpawnPosition (Vector3 pos, int itemSpawnedIndex, TriggeredWaveMetaData wave)
 Returns the position to spawn an item in. Override for your custom logic. More...
 
virtual Quaternion GetSpawnRotation (Transform prefabToSpawn, int itemSpawnedIndex, TriggeredWaveMetaData wave)
 Returns the rotation to spawn the item in. Override if you need custom logic for this. More...
 
virtual void AffectScale (Transform spawnedTrans, TriggeredWaveMetaData wave)
 Fires after the item spawns and affects the scale of the spawned object. Override if you need custom logic here. More...
 
virtual void AfterSpawn (Transform spawnedTrans, TriggeredWaveMetaData wave, TriggeredSpawner.EventType eType)
 Fires immediately after the item spawns. Used by post-spawn nudge. Override if you need custom logic here. More...
 

Properties

List< TrigSpawnerWaiterSpecifics > ActiveEliminationWaves [get]
 This returns a list of all the active elimination waves. More...
 
Dictionary< TriggeredSpawner.EventType, List< TriggeredWaveSpecifics > > AllWaves [get]
 This returns a list of all the waves. Used by bulk "modify all waves" things such as visualization code. More...
 
bool SpawnerIsPaused [get]
 This property will return true if the Wave Pause Behavior setting makes this spawner paused. More...
 
bool GameIsOverForSpawner [get]
 This property will return true if the Game Over Behavior setting makes this spawner disabled. More...
 
bool SpawnerIsActive [get]
 Returns whether the spawner is active or not, based on its Active Mode controls. This can restrict its active state based on World Variable values. More...
 

Detailed Description

This class is used for Triggered Spawner setup.

Member Function Documentation

void DarkTonic.CoreGameKit.TriggeredSpawnerV2.ActivateCodeTriggeredEvent1 ( )

Call this method to active Code-Triggered Event 1.

void DarkTonic.CoreGameKit.TriggeredSpawnerV2.ActivateCodeTriggeredEvent2 ( )

Call this method to active Code-Triggered Event 2.

virtual void DarkTonic.CoreGameKit.TriggeredSpawnerV2.AffectScale ( Transform  spawnedTrans,
TriggeredWaveMetaData  wave 
)
protectedvirtual

Fires after the item spawns and affects the scale of the spawned object. Override if you need custom logic here.

Parameters
spawnedTransThe spawned Transform.
waveMetadata of the Wave
virtual void DarkTonic.CoreGameKit.TriggeredSpawnerV2.AfterSpawn ( Transform  spawnedTrans,
TriggeredWaveMetaData  wave,
TriggeredSpawner.EventType  eType 
)
protectedvirtual

Fires immediately after the item spawns. Used by post-spawn nudge. Override if you need custom logic here.

Parameters
spawnedTransThe spawned Transform.
waveThe wave the item came from.
eTypeThe event type.
virtual bool DarkTonic.CoreGameKit.TriggeredSpawnerV2.CanSpawnOne ( TriggeredWaveMetaData  wave)
protectedvirtual

Subclass this to override it if needed.

Returns
boolean value.
virtual void DarkTonic.CoreGameKit.TriggeredSpawnerV2.DespawnSpawner ( )
protectedvirtual

Override this method to call a Network Destroy method or other.

void DarkTonic.CoreGameKit.TriggeredSpawnerV2.EndWave ( TriggeredSpawner.EventType  eType,
string  customEventName 
)

This method stops the currently spawning wave of an Event Type you pass in, if there is a match.

Parameters
eTypeThe Event Type of the wave to end.
customEventNameThe name of the custom event (if you're stopping a custom wave only.
static List<TriggeredSpawnerV2> DarkTonic.CoreGameKit.TriggeredSpawnerV2.GetChildSpawners ( Transform  trans)
static

This method returns a list of the child Spawners, if any.

Parameters
transThe Transform of the Spawner to get child Spawners of.
Returns
A list of Triggered Spawner scripts for all child Spawners.
virtual Transform DarkTonic.CoreGameKit.TriggeredSpawnerV2.GetSpawnable ( TriggeredWaveMetaData  wave)
protectedvirtual

This returns the item to spawn. Override this to apply custom logic if needed.

Returns
The Transform to spawn.
virtual Vector3 DarkTonic.CoreGameKit.TriggeredSpawnerV2.GetSpawnPosition ( Vector3  pos,
int  itemSpawnedIndex,
TriggeredWaveMetaData  wave 
)
protectedvirtual

Returns the position to spawn an item in. Override for your custom logic.

Parameters
posSpawner position.
itemSpawnedIndexIndex (counter) of item to spawn. Incremental Settings use this.
waveThe wave that is being spawned.
Returns
The modified position to spawn in.
virtual Quaternion DarkTonic.CoreGameKit.TriggeredSpawnerV2.GetSpawnRotation ( Transform  prefabToSpawn,
int  itemSpawnedIndex,
TriggeredWaveMetaData  wave 
)
protectedvirtual

Returns the rotation to spawn the item in. Override if you need custom logic for this.

Parameters
prefabToSpawnThe prefab to spawn.
itemSpawnedIndexIndex (counter) of item to spawn. Incremental Settings use this.
waveThe wave that is being spawned.
Returns
The modified rotation to spawn in.
bool DarkTonic.CoreGameKit.TriggeredSpawnerV2.HasActiveWaveOfType ( TriggeredSpawner.EventType  eType,
string  customEventName 
)

Returns whether a wave of the current event is currently active or not.

Parameters
eTypeEvent Type
customEventNameThe name of the custom event (if you're stopping a custom wave only.
Returns
True or false
virtual void DarkTonic.CoreGameKit.TriggeredSpawnerV2.SpawnedOrAwake ( )
protectedvirtual

This method gets called whenever the object is spawned or starts in a Scene (from Awake event)

virtual Transform DarkTonic.CoreGameKit.TriggeredSpawnerV2.SpawnWaveItem ( Transform  prefabToSpawn,
Vector3  spawnPosition,
Quaternion  rotation,
TriggeredWaveMetaData  wave 
)
protectedvirtual

Override this method to call a Network Instantiate method or other.

Parameters
prefabToSpawnThe prefab to spawn.
spawnPositionThe position to spawn in.
rotationThe rotation to spawn with.
waveMetadata of the Wave
Returns
Spawned item Transform

Property Documentation

List<TrigSpawnerWaiterSpecifics> DarkTonic.CoreGameKit.TriggeredSpawnerV2.ActiveEliminationWaves
get

This returns a list of all the active elimination waves.

Dictionary<TriggeredSpawner.EventType, List<TriggeredWaveSpecifics> > DarkTonic.CoreGameKit.TriggeredSpawnerV2.AllWaves
get

This returns a list of all the waves. Used by bulk "modify all waves" things such as visualization code.

bool DarkTonic.CoreGameKit.TriggeredSpawnerV2.GameIsOverForSpawner
get

This property will return true if the Game Over Behavior setting makes this spawner disabled.

bool DarkTonic.CoreGameKit.TriggeredSpawnerV2.SpawnerIsActive
get

Returns whether the spawner is active or not, based on its Active Mode controls. This can restrict its active state based on World Variable values.

bool DarkTonic.CoreGameKit.TriggeredSpawnerV2.SpawnerIsPaused
get

This property will return true if the Wave Pause Behavior setting makes this spawner paused.


The documentation for this class was generated from the following file: