UQdeco2800 / deco2800-2017-rocketpotatoes

7 stars 4 forks source link

Enemy waves and spawning (team 11) #40

Closed charvei closed 7 years ago

charvei commented 7 years ago

Description

Creating and managing waves of enemies spawning and the wait periods in between. The flow of tower defense games are determined by the characteristics of enemy waves. Currently the plan is to have a set preparation period before each wave where the player can set up their base briefly, followed the start of a wave where enemies will spawn for a period of time. Also need to specify where enemies spawn from.

Structure

EnemyWave

A class that defines the composition of a wave (in form of ratios) and the length of time the wave will be. Special events within a wave e.g. a particular enemy spawning or some kind of world effect (if implemented) could likely be held here too.

WaveManager

A manager class to manage enemy waves - when to start, end, pause and progress waves.

WaveGUI

A small GUI for displaying:

Milestones

charvei commented 7 years ago

Currently we have an EnemyWaves class implemented. Here you can define relative rates you want of each enemy in the resulting enemy wave, e.g. 5, 1, 1, 2 will have 5squirrels : 1speedy : 1tank : 2meese. It will spawn an enemy according to these ratios at a defined rate, for a specified length of time.

A WaveManager has also been made that you can add EnemyWaves to and it will manage which one is active and the progression of one to the next and the wait period in between waves.

charvei commented 7 years ago

Update: -The basic functionality of waves has been implemented as per this tickets checked milestones along with simple GUI. -Still needing to implement a way to pause - this would probably extend beyond just the wave pausing but pausing the who game as that has yet to be implemented. -Wave difficulties have not been implemented outside of simply setting a wave to last a longer period of time. Enemies don't have increased difficulty levels. So wave difficulties may be waiting for enemy difficulties to be introduced.

charvei commented 7 years ago

Waves class diagram.

wavesclassdiagram

lambo-blair commented 7 years ago

Our branch has been pushed to master, changes include:

lambo-blair commented 7 years ago

This ticket is mostly finished. The minor items remaining would be waves should not end until all enemies are dead and the wave count on endless mode is odd.

The next ticket after this could be seen as an extension to gameplay, see ticket #70

charvei commented 7 years ago

Enemy spawning and waves has moved to ticket #70