+
+#### Coding Theory
+This game has only one victory and one failure condition.
+The spawns(enemies/utilities) are the main element of the game. Using an object constructor function allows storing of numerous keys and elements for each enemy.
+It also allows for future addition of enemy types and effects. Spawns are pushed into an empty array for storage.
+Example of object constructor:
+```
+function Spawn(life, damageOnPlayerWhenExpire, timeTillExpire, effectOnPlayerHealthWhenShot, effectOnPlayerAmmoWhenShot, effectOnGrenadeWhenShot, idLink){
+ this.life = life;
+ this.damageOnPlayerAtExpire = damageOnPlayerAtExpire;
+ this.timeTillExpire = timeTillExpire;
+ this.effectOnPlayerHealthWhenShot = effectOnPlayerHealthWhenShot;
+ this.effectOnPlayerAmmoWhenShot = effectOnPlayerAmmoWhenShot;
+ this.effectOnPlayerGrenadeWhenShot = effectOnPlayerGrenadeWhenShot;
+ this.idLink = idLink;
+}
+```
+On each spawn, a div will be created and appended. A counter is used to link the enemy div with the specific enemy array element. Each spawn is given a unique ID using the counter, and an idLink of the same value for the array element, afterwhich the counter increases for the next spawn.
+Enemies/allies/tools spawn via a setInterval function. Different enemies have different spawn rates.
+
+On shooting spawns, function will iterate object key and value to determine effect on player stats.
+Enemies deal damage to player on expiry.
+
+To add variety in the game, events are created that spawn i.e. 300 enemies at the same time, which forces players to use the grenade. Individual levels are created by matching spawn rate and events with the tempo of the background music of the specific level.
+
+#### Future Possible Updates
+* Scoring function
+* Combo function
+* Pause button
+* Text popups at game screen, 'Miss!' etc.
+* Enemies zoom to player (transition effect) when they expire, like a bullet path
+* Text notification on miss etc.
+
+
+
+#### Misc Issues
+* No max health
+* Using grenade on 5 allies and 1 healthpack will result in gameover.
Shoot: 1 hit on target
+
Grenade: 2 hits on allEasy enemy: 1 hit
+Normal enemy: 2 hits
+Hard enemy: 3 hits
+
+ Ally: 1 damage on hit
+Ammo: +10
+Grenade: +1
+
+