· Spawn distinct predefined enemy waves with different kind of enemies.

· The waves can be defined for each spawners as (Example: wave 1: two smashers and one flying enemy; wave 2: Three flying enemies; wave 3: Three smashers)

· Can be activated an stopped by a trigger on the level. (Trigger box or activated by an event)

· Has a delay activation time. (The delay from activated on the trigger to the spawn the first wave)

· Has a time between enemy waves that can be configured for each wave (Example: Time between wave one and wave two “5 secs”; Time between wave two and wave three “7 secs”; Time between wave two and wave three “9 secs”)

· These waves will loop infinitely (wave 1 - wave 2 - wave 3 - wave 1 - wave 2…)

IMPLEMENTATION

The spawner implementation is located in the EnemySpawnComponent

The component must be added to an actor. Once added, in the Waves section of the details panel, a variable called enemyWaves can be found. There, it is possible to add enemyWaves to the spawner. Inside each wave, the variable Enemies can be found. Here is where the enemies that form each wave are selected. Underneath Enemies, there are the varibles startDelay and timeBetween enemies. The first sets how long does the wave take to start. The second sets how often the enemies spawn.

Above the Waves section, there is a section called Spawn Info. There are 4 float variables (Min X, Max X, Min Y, Max Y). These variable define the distance on the x and y axis around the spawner location where the enemies will spawn. The enemies will spawn in a random location inside the defined range.

Under these floats there is the bool is Infinite. If this bool is checked, the waves will loop infinitely. If not, the spawner will stop after the last enemy of the last wave is spawned.

In order to start spawning eneamies, the event Start Spawning must be called on the Event graph. This will activate the first wave defined on the component, and will loop through all the waves defined in order.

In order to stop spawning enemies, the event Stop Spawning must be called.

With this component, both the activated spawner and infinite spawners can be made.